Improved pagination
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
class PreorderController extends mfBaseController {
|
||||
|
||||
protected function init() {
|
||||
$this->needlogin=true;
|
||||
$me = new User();
|
||||
$me->loadMe();
|
||||
$this->me = $me;
|
||||
$this->layout()->set("me",$me);
|
||||
|
||||
if(!$me->is(["Admin"])) {
|
||||
$this->redirect("Dashboard");
|
||||
}
|
||||
}
|
||||
|
||||
protected function indexAction() {
|
||||
$this->layout()->setTemplate("Preorder/Index");
|
||||
|
||||
$campaigns = PreorderModel::getAll();
|
||||
$this->layout()->set("campaigns", $campaigns);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user