mirror of
https://github.com/Bigherollc/wticreatorstudio.git
synced 2026-10-17 21:03:00 -04:00
Updated frontend module
This commit is contained in:
@@ -9,16 +9,16 @@ use Modules\Frontend\Services\Videos;
|
||||
|
||||
class VideoController extends Controller
|
||||
{
|
||||
protected $videos;
|
||||
protected $service;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->videos = new Videos();
|
||||
$this->service = new Videos();
|
||||
}
|
||||
|
||||
public function index()
|
||||
{
|
||||
$videos = $this->videos->all();
|
||||
$videos = $this->service->all();
|
||||
|
||||
return response()->json([
|
||||
'message' => 'Success',
|
||||
@@ -30,7 +30,8 @@ class VideoController extends Controller
|
||||
{
|
||||
$rows = $request->rows;
|
||||
$page = $request->page;
|
||||
$result = $this->videos->getByPage($page, $rows);
|
||||
$filter = $request->filter;
|
||||
$result = $this->service->getByPage($page, $rows, $filter);
|
||||
|
||||
return response()->json($result);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user