diabled admin and csr check for all route entries
This commit is contained in:
@@ -38,7 +38,10 @@ class Aria2Controller extends Controller
|
||||
$this->aria2->init();
|
||||
$this->dbconn = new DBConn();
|
||||
}
|
||||
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function Action($path)
|
||||
{
|
||||
$path = strtolower(trim($path));
|
||||
@@ -97,6 +100,10 @@ class Aria2Controller extends Controller
|
||||
$data = $this->aria2->start();
|
||||
return $data;
|
||||
}
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function Update()
|
||||
{
|
||||
$resp = folderScan::create()->scan();
|
||||
@@ -110,6 +117,10 @@ class Aria2Controller extends Controller
|
||||
'path' => $this->urlGenerator->linkToRoute('ncdownloader.Aria2.Action', ['path' => $path]),
|
||||
);
|
||||
}
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function getStatus($path)
|
||||
{
|
||||
//$path = $this->request->getRequestUri();
|
||||
|
||||
@@ -54,7 +54,10 @@ class MainController extends Controller
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function Download()
|
||||
{
|
||||
$url = trim($this->request->getParam('form_input_text'));
|
||||
|
||||
@@ -21,7 +21,10 @@ class SearchController extends Controller
|
||||
$this->urlGenerator = \OC::$server->getURLGenerator();
|
||||
$this->search = new torrentSearch();
|
||||
}
|
||||
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function execute()
|
||||
{
|
||||
$keyword = trim($this->request->getParam('form_input_text'));
|
||||
|
||||
@@ -40,6 +40,10 @@ class SettingsController extends Controller
|
||||
$this->save($key, $value);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function aria2Get()
|
||||
{
|
||||
$data = json_decode($this->settings->get("custom_aria2_settings"));
|
||||
@@ -58,12 +62,20 @@ class SettingsController extends Controller
|
||||
}
|
||||
|
||||
}
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function aria2Save()
|
||||
{
|
||||
$params = $this->request->getParams();
|
||||
$data = Helper::filterData($params, Helper::aria2Options());
|
||||
$this->settings->save("custom_aria2_settings", json_encode($data));
|
||||
}
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function aria2Delete()
|
||||
{
|
||||
$saved = json_decode($this->settings->get("custom_aria2_settings"),1);
|
||||
|
||||
@@ -69,6 +69,10 @@ class YoutubeController extends Controller
|
||||
$resp['counter'] = ['youtube-dl' => count($data)];
|
||||
return new JSONResponse($resp);
|
||||
}
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function Download()
|
||||
{
|
||||
$params = array();
|
||||
@@ -96,7 +100,10 @@ class YoutubeController extends Controller
|
||||
return ['error' => $this->l10n->t("failed to get any url!")];
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*/
|
||||
public function Delete()
|
||||
{
|
||||
$gid = $this->request->getParam('gid');
|
||||
|
||||
@@ -4,7 +4,7 @@ extract($_);
|
||||
?>
|
||||
<div class="ncdownloader-admin-settings">
|
||||
<form id="ncdownloader" class="section">
|
||||
<h2>ncDownloader admin Settings</h2>
|
||||
<h2>NCDownloader admin Settings</h2>
|
||||
<div>
|
||||
<span id="ncdownloader-message-banner"></span>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user