コード例 #1
0
ファイル: log.php プロジェクト: stuartjing/cherryphp-manager
 public function index($params)
 {
     $this->assign("rules", explode(",", $_COOKIE['rogmgr_rules']));
     $rules_kv = \module\mauthorization::get_rules_kv();
     $this->assign("rules_kv", $rules_kv);
     if (in_array($rules_kv['操作日志-查看'], explode(",", $_COOKIE['rogmgr_rules']))) {
         $this->render("mcp/log");
     }
 }
コード例 #2
0
 public function showServer()
 {
     $this->assign("rules", explode(",", $_COOKIE['rogmgr_rules']));
     $rules_kv = \module\mauthorization::get_rules_kv();
     $this->assign("rules_kv", $rules_kv);
     if (in_array($rules_kv['Server-查看'], explode(",", $_COOKIE['rogmgr_rules']))) {
         $this->render("mcp/defaultserver");
     }
 }
コード例 #3
0
 public function index()
 {
     $this->assign("rules", explode(",", $_COOKIE['rogmgr_rules']));
     $rules_kv = \module\mauthorization::get_rules_kv();
     $this->assign("rules_kv", $rules_kv);
     if (in_array($rules_kv['邮件服务器-查看'], explode(",", $_COOKIE['rogmgr_rules']))) {
         $this->render("mcp/emailserver");
     }
 }
コード例 #4
0
ファイル: main.php プロジェクト: stuartjing/cherryphp-manager
 public function index($params)
 {
     if ($_COOKIE['rogmgr_user']) {
         $this->assign("agent", $_COOKIE['rogmgr_user']);
         $this->assign("rules", explode(",", $_COOKIE['rogmgr_rules']));
         $rules_kv = \module\mauthorization::get_rules_kv();
         $this->assign("rules_kv", $rules_kv);
         $this->render("mcp/main");
     } else {
         header('location: ../login');
     }
 }
コード例 #5
0
 public function get_kv()
 {
     \module\mauthorization::get_rules_kv();
 }
コード例 #6
0
 public static function rules_update($params)
 {
     $ids = array("id" => $params['pid']);
     \module\mauthorization::rules_delete($ids);
     $stats = \module\mauthorization::rules_add($params);
     return $stats;
 }
コード例 #7
0
 public function rules_update($params)
 {
     $res_add_rules = \module\mauthorization::rules_update($params);
     echo json_encode($res_add_rules);
 }