mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-08-29 09:18:54 +00:00
Update ShowsController add show-remove option
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Http\Controllers\Admin;
|
||||
|
||||
use App\Models\Release;
|
||||
use App\Models\Video;
|
||||
use Illuminate\Http\Request;
|
||||
use Blacklight\processing\tv\TV;
|
||||
@@ -77,4 +78,33 @@ class ShowsController extends BasePageController
|
||||
);
|
||||
$this->adminrender();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $id
|
||||
*
|
||||
* @throws \Exception
|
||||
*/
|
||||
public function destroy($id)
|
||||
{
|
||||
$this->setAdminPrefs();
|
||||
|
||||
$success = false;
|
||||
|
||||
if ($id) {
|
||||
$success = Release::removeVideoIdFromReleases($id);
|
||||
$this->smarty->assign('videoid', $id);
|
||||
}
|
||||
|
||||
$this->smarty->assign('success', $success);
|
||||
|
||||
$title = 'Remove Video and Episode IDs from Releases';
|
||||
$content = $this->smarty->fetch('show-remove.tpl');
|
||||
$this->smarty->assign(
|
||||
[
|
||||
'title' => $title,
|
||||
'content' => $content,
|
||||
]
|
||||
);
|
||||
$this->adminrender();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user