/** * 用户列表权限操作 * * @access public */ public function acl($data) { $this->setCurrentAction('acl', 'user', 'foundation')->setData($data)->checkPermission(Acl::GROUP_LEVEL_TYPE_USER); $url = R('common', $this->module . '.' . $this->class . '.' . $this->function, ['id' => url_param_encode($data['id'])]); $html = $this->hasPermission ? '<a href="' . $url . '"><i class="fa fa-user"></i></a>' : '<i class="fa fa-user" style="color:#ccc"></i>'; return $html; }
/** * 权限列表删除操作 * * @access public */ public function delete($data) { $this->setCurrentAction('acl', 'delete', 'foundation')->checkPermission(); $url = R('common', $this->module . '.' . $this->class . '.' . $this->function, ['id' => url_param_encode($data['id'])]); $html = $this->hasPermission ? '<a href="javascript:org.Common.ajaxDelete(\'' . $url . '\', \'sys-list\', \'确定吗?\');"><i class="fa fa-trash-o"></i></a>' : '<i class="fa fa-trash-o" style="color:#ccc"></i>'; return $html; }
/** * 用户组列表删除操作 * * @access public */ public function acl($data) { $this->setCurrentAction('acl', 'group', 'foundation')->setData($data)->checkPermission(Acl::GROUP_LEVEL_TYPE_GROUP); $url = route($this->module . '.' . $this->class . '.' . $this->function, ['id' => url_param_encode($data['id'])]); $html = $this->hasPermission ? '<a title="权限管理" href="' . $url . '"><i class="icon-user"></i></a>' : ''; $html = ['show' => $this->hasPermission, 'html' => $html]; return $html; }
/** * 权限列表删除操作 * * @access public */ public function delete($data) { $this->setCurrentAction('acl', 'delete', 'foundation')->checkPermission(); $url = route($this->module . '.' . $this->class . '.' . $this->function, ['id' => url_param_encode($data['id'])]); $html = $this->hasPermission ? '<a title="删除" href="javascript:rc.ajaxDelete(\'' . $url . '\', \'sys-list\', \'确定吗?\');"><i class="icon-trash"></i></a>' : ''; $html = ['show' => $this->hasPermission, 'html' => $html]; return $html; }