function __construct() { $this->conf = array('model' => 'Shift_model', 'path' => 'admin/shifts', 'entity' => 'shift', 'after_save' => 'shift'); parent::__construct(User_model::LEVEL_MANAGER); /* check how many locations do we have */ $lm = new Location_Model(); $location_count = $lm->count(); $this->data['location_count'] = $location_count; }
function __construct() { $this->conf = array('model' => 'Shift_model', 'path' => 'staff/shifts', 'entity' => 'shift'); parent::__construct(USER_MODEL::LEVEL_STAFF); $this->{$this->model} = $this->auth->user()->shift; $this->{$this->model}->user = $this->auth->user(); // $this->data['fields'] = $this->process_fields(); // parent::__construct( USER_MODEL::LEVEL_STAFF, 'staff/shifts' ); /* check how many locations do we have */ $lm = new Location_Model(); $location_count = $lm->count(); $this->data['location_count'] = $location_count; }
function __construct() { $this->conf = array('model' => 'Logaudit_model', 'path' => 'logaudit/admin', 'entity' => 'logaudit'); parent::__construct(USER_MODEL::LEVEL_MANAGER); }
function __construct() { $this->conf = array('model' => 'Location_model', 'path' => 'admin/locations', 'entity' => 'location'); parent::__construct(); }
function password($id) { $fields = array_values(array_filter($this->{$this->model}->get_form_fields(), create_function('$a', 'return (isset($a["type"]) && ("password" == $a["type"])) ? TRUE : FALSE;'))); $this->data['fields'] = $fields; if (!$this->hc_form->is_set_default('password')) { $this->hc_form->set_default('password', ''); } return parent::edit($id, 'password'); }
function edit($id, $view = 'edit') { $this->data['fixed'] = array('user'); return parent::edit($id, $view); }
function __construct() { $this->conf = array('model' => 'Shift_template_model', 'path' => 'admin/shift_templates', 'entity' => 'shift_template'); parent::__construct(User_model::LEVEL_ADMIN); }