feature: auth
This commit is contained in:
parent
28f3154a9e
commit
cc4180b27d
|
|
@ -22,6 +22,9 @@ class CustomSchedule extends Backend
|
|||
*/
|
||||
protected $model = null;
|
||||
|
||||
protected $noNeedRight = ['editable'];
|
||||
|
||||
|
||||
public function _initialize()
|
||||
{
|
||||
parent::_initialize();
|
||||
|
|
@ -97,7 +100,7 @@ class CustomSchedule extends Backend
|
|||
->where('date', '>=', $startDate)
|
||||
->where('date', '<=', $endDate);
|
||||
|
||||
if (!$this->auth->isSuperAdmin()) {
|
||||
if (!$this->auth->check('oa/custom_schedule/edit')) {
|
||||
$builder = $builder->where('exec_admin_id', $this->auth->id);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user