-changes to list view. Framework so that we may change selected day
-changes to add-user. Started implementing Vladimirs design.
This commit is contained in:
parent
e9691f9a4c
commit
bc5b9efb4b
19 changed files with 351 additions and 69 deletions
|
@ -6,27 +6,38 @@ class NowplayingController extends Zend_Controller_Action
|
|||
public function init()
|
||||
{
|
||||
$ajaxContext = $this->_helper->getHelper('AjaxContext');
|
||||
$ajaxContext->addActionContext('get-data-grid-data', 'json')
|
||||
->initContext();
|
||||
$ajaxContext->addActionContext('get-data-grid-data', 'json')
|
||||
->initContext();
|
||||
}
|
||||
|
||||
public function indexAction()
|
||||
{
|
||||
$this->view->headScript()->appendFile('/js/datatables/js/jquery.dataTables.min.js','text/javascript');
|
||||
$this->view->headScript()->appendFile('/js/playlist/nowplayingdatagrid.js','text/javascript');
|
||||
$this->view->headScript()->appendFile('/js/playlist/nowview.js','text/javascript');
|
||||
}
|
||||
|
||||
public function getDataGridDataAction()
|
||||
{
|
||||
$viewType = $this->_request->getParam('view');
|
||||
$this->view->entries = Application_Model_Nowplaying::GetDataGridData($viewType);
|
||||
$dateString = $this->_request->getParam('date');
|
||||
$this->view->entries = Application_Model_Nowplaying::GetDataGridData($viewType, $dateString);
|
||||
}
|
||||
|
||||
public function livestreamAction()
|
||||
{
|
||||
//use bare bones layout (no header bar or menu)
|
||||
$this->_helper->layout->setLayout('bare');
|
||||
$this->_helper->layout->setLayout('bare');
|
||||
}
|
||||
|
||||
public function dayViewAction()
|
||||
{
|
||||
$this->view->headScript()->appendFile('/js/datatables/js/jquery.dataTables.min.js','text/javascript');
|
||||
$this->view->headScript()->appendFile('/js/playlist/nowplayingdatagrid.js','text/javascript');
|
||||
$this->view->headScript()->appendFile('/js/playlist/dayview.js','text/javascript');
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
@ -35,3 +46,5 @@ class NowplayingController extends Zend_Controller_Action
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -5,43 +5,54 @@ class UserController extends Zend_Controller_Action
|
|||
|
||||
public function init()
|
||||
{
|
||||
$ajaxContext = $this->_helper->getHelper('AjaxContext');
|
||||
$ajaxContext->addActionContext('get-hosts', 'json')
|
||||
->initContext();
|
||||
$ajaxContext = $this->_helper->getHelper('AjaxContext');
|
||||
$ajaxContext->addActionContext('get-hosts', 'json')
|
||||
->addActionContext('get-user-data-table-info', 'json')
|
||||
->initContext();
|
||||
}
|
||||
|
||||
public function indexAction()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function addUserAction()
|
||||
{
|
||||
{
|
||||
$this->view->headScript()->appendFile('/js/datatables/js/jquery.dataTables.js','text/javascript');
|
||||
$this->view->headScript()->appendFile('/js/airtime/user/user.js','text/javascript');
|
||||
$request = $this->getRequest();
|
||||
$form = new Application_Form_AddUser();
|
||||
|
||||
if ($request->isPost()) {
|
||||
if ($form->isValid($request->getPost())) {
|
||||
|
||||
$formdata = $form->getValues();
|
||||
User::addUser($formdata);
|
||||
$form->reset();
|
||||
}
|
||||
}
|
||||
|
||||
$this->view->form = $form;
|
||||
$form = new Application_Form_AddUser();
|
||||
|
||||
if ($request->isPost()) {
|
||||
if ($form->isValid($request->getPost())) {
|
||||
|
||||
$formdata = $form->getValues();
|
||||
User::addUser($formdata);
|
||||
$form->reset();
|
||||
}
|
||||
}
|
||||
|
||||
$this->view->form = $form;
|
||||
}
|
||||
|
||||
public function getHostsAction()
|
||||
{
|
||||
$search = $this->_getParam('term');
|
||||
|
||||
$this->view->hosts = User::getHosts($search);
|
||||
$search = $this->_getParam('term');
|
||||
|
||||
$this->view->hosts = User::getHosts($search);
|
||||
}
|
||||
|
||||
public function getUserDataTableInfoAction()
|
||||
{
|
||||
$post = $this->getRequest()->getPost();
|
||||
$users = User::getUsersDataTablesInfo($post);
|
||||
|
||||
die(json_encode($users));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue