Beispiel #1
0
 public function create_apikey()
 {
     $this->muser->require_access("full");
     $userid = $this->muser->get_userid();
     $comment = $this->input->post("comment");
     $comment = $comment === false ? "" : $comment;
     $access_level = $this->input->post("access_level");
     $key = \service\user::create_apikey($userid, $comment, $access_level);
     return array("new_key" => $key);
 }
Beispiel #2
0
 function apikeys()
 {
     $this->muser->require_access();
     $userid = $this->muser->get_userid();
     $apikeys = \service\user::apikeys($userid);
     $this->data["query"] = $apikeys["apikeys"];
     $this->load->view('header', $this->data);
     $this->load->view($this->var->view_dir . 'apikeys', $this->data);
     $this->load->view('footer', $this->data);
 }
Beispiel #3
0
 private function createApikey($userid, $access_level = "apikey")
 {
     return \service\user::create_apikey($userid, "", $access_level);
 }