Beispiel #1
0
     $message = "アクセス権限がありません。";
 }
 // ログインユーザ:責任者権限のみの場合、本人以外のページにアクセス不可
 // falseが返ってくるとアクセス権限なし
 if (!in_array(ACCOUNT_DEPARTMENT, $authority) && in_array(ACCOUNT_ADMIN, $authority) && (isset($admin_id) && $admin_id !== $id)) {
     $auth = false;
     $message = "アクセス権限がありません。";
 }
 if (!$auth) {
     $param['errors'][] = $message;
     renderTemplate('error.tpl', $param);
     exit;
 }
 // 責任者ID以外のページにアクセス不可
 // falseが返ってくるとアクセス権限なし
 $admin_exist = $hearing->checkAdmin($admin_id);
 if (!$admin_exist) {
     $param['errors'][] = "指定されたヒアリングシートは存在しません。";
     renderTemplate('error.tpl', $param);
     exit;
 }
 //日付取得
 if (isset($request['target_date']) && !empty($request['target_date'])) {
     //サブメニューから遷移
     $date = date('Ymd', strtotime($request['target_date']));
     $year = getYear($request['target_date']);
     $month = getMonth($request['target_date']);
     $enable_date = isEnableDate($date);
 } else {
     //初期表示
     $date = date('Ymd');