當前位置: 首頁>>代碼示例>>PHP>>正文


PHP sapp_Global::_check_menu_access方法代碼示例

本文整理匯總了PHP中sapp_Global::_check_menu_access方法的典型用法代碼示例。如果您正苦於以下問題:PHP sapp_Global::_check_menu_access方法的具體用法?PHP sapp_Global::_check_menu_access怎麽用?PHP sapp_Global::_check_menu_access使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在sapp_Global的用法示例。


在下文中一共展示了sapp_Global::_check_menu_access方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: saveagencycomment

 /**
  * This function acts as a service to save comments given by agency for particular screening detail(isactive is active) of each employee / candidate 
  * @param array $params_arr  = array of parameters
  * userid, groupid, roleid, detailid, comment are the input parameters
  * @return array of comments.
  */
 public function saveagencycomment($params_arr)
 {
     $result = array();
     $status = 0;
     $message = "Message cannot be saved.";
     $edit_flag = 'No';
     if (isset($params_arr['role_id']) && $params_arr['role_id'] != '' && isset($params_arr['group_id']) && $params_arr['group_id'] != '' && $params_arr['group_id'] == $this->usergroup && isset($params_arr['detailid'])) {
         $role_id = $params_arr['role_id'];
         $group_id = $params_arr['group_id'];
         $loginid = $params_arr['userid'];
         $detailid = $params_arr['detailid'];
         $comment = $params_arr['comment'];
         $empscreening_model = new Services_Model_Empscreening();
         $privilege_flag = sapp_Global::_check_menu_access(EMPSCREENING, $group_id, $role_id);
         $edit_flag = sapp_Global::_checkprivileges(EMPSCREENING, $group_id, $role_id, "edit");
         $checkarr = $empscreening_model->checkagencyfordetail($detailid, $loginid);
         if ($privilege_flag == 'Yes' && $edit_flag == 'Yes' && $checkarr != 'norows') {
             $commentflag = $empscreening_model->savecomment($detailid, $loginid, $comment);
             if ($commentflag) {
                 $message = "Success.";
             } else {
                 $message = "Message cannot be saved.";
             }
         } else {
             $message = "you are not authorized to access this page";
         }
     }
     return array('status' => $status, 'message' => $message, 'result' => $result, 'edit_flag' => $edit_flag);
 }
開發者ID:sura2k,項目名稱:sentrifugo,代碼行數:35,代碼來源:IndexController.php


注:本文中的sapp_Global::_check_menu_access方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。