Example #1
0
 public function screen_list_project()
 {
     if (isset($_GET['flag'])) {
         if ($_GET['flag'] == "regist") {
             $this->message = "新規で1件、登録が完了しました";
         }
         if ($_GET['flag'] == "modify") {
             $this->message = "案件を1件、更新しました";
         }
         if ($_GET['flag'] == "delete") {
             $this->message = "案件を1件、削除しました";
         }
     }
     //システム側から来た場合、セッション値の定義
     if ($this->is_system && isset($_POST['id'])) {
         $_SESSION[_CUSTOMER_AUTHINFO]['id'] = $_POST['id'];
         $CustomerModel = new CustomerModel();
         $_SESSION[_CUSTOMER_AUTHINFO]['company_name'] = $CustomerModel->get_company_name_company_id($_POST['id']);
     }
     if ($this->is_system) {
         $this->title = "<font color='blue'>" . $_SESSION[_CUSTOMER_AUTHINFO]['company_name'] . "</font>様の案件一覧";
     } else {
         $this->title = "案件一覧";
     }
     $perPage = "5";
     $this->next_type = "list_project";
     $CustomerModel = new CustomerModel();
     $CustomerModel->valid_off_yesterday_project();
     list($data, $count) = $CustomerModel->get_project_list($_SESSION[_CUSTOMER_AUTHINFO]['id']);
     list($data, $links) = $this->make_page_link($perPage, $data);
     $this->view->assign('data', $data);
     $this->view->assign('count', $count);
     $this->view->assign('links', $links['all']);
     $this->file = "customer_list_project.tpl";
     $this->view_display();
 }
Example #2
0
 public function screen_tomorrow_project()
 {
     unset($_SESSION['memberdata']);
     unset($_SESSION['search_key']);
     unset($_SESSION['pageID']);
     unset($_SESSION['apply']);
     $perPage = 4;
     $disp_search_key = "";
     $sql_search_key = "";
     $project_type = "";
     $area_type = "";
     $this->make_select_form_project_type();
     $this->make_form_project_area();
     $search_terms = $this->form->getSubmitValues();
     if (isset($search_terms['project_type']) && $search_terms['project_type'] != "0") {
         $project_type = $search_terms['project_type'];
     }
     if (isset($search_terms['area_type1']) && $search_terms['area_type1'] != "1") {
         $area_type = $search_terms['area_type1'];
     }
     //・・・・・・・・・・・・・・・・・・・・・
     // サーチキーによるサーチワードの設定
     //・・・・・・・・・・・・・・・・・・・・・
     //何らかの値が代入されている場合
     if (isset($_POST['search_key']) && $_POST['search_key'] != "") {
         $_SESSION['search_key'] = $_POST['search_key'];
         $disp_search_key = htmlspecialchars($_POST['search_key'], ENT_QUOTES);
         $sql_search_key = $_POST['search_key'];
         //セットされていない。何も代入されていない場合
     } else {
         //何も値が代入されずに、ボタンだけ押された場合
         if (isset($_POST['submit']) && $_POST['submit'] == "絞り込み") {
             //セッションの削除
             unset($_SESSION['search_key']);
             //新規検索実行 以外の動作の場合(ページが更新もしくは他のボタンが押された)
         } else {
             //もしsessionにサーチキーが格納されている場合
             if (isset($_SESSION['search_key'])) {
                 $disp_search_key = htmlspecialchars($_SESSION['search_key'], ENT_QUOTES);
                 $sql_search_key = $_SESSION['search_key'];
             }
         }
     }
     $id = "";
     if (isset($_SESSION[_MEMBER_AUTHINFO]['id'])) {
         $id = $_SESSION[_MEMBER_AUTHINFO]['id'];
     }
     $CustomerModel = new CustomerModel();
     $CustomerModel->valid_off_yesterday_project();
     list($data, $count) = $CustomerModel->get_valid_tomorrow_project_list($project_type, $area_type, $sql_search_key, $id);
     list($data, $links) = $this->make_page_link($perPage, $data);
     $this->view->assign('count', $count);
     $this->view->assign('data', $data);
     $this->view->assign('search_key', $disp_search_key);
     $this->view->assign('links', $links['all']);
     $this->next_action = "";
     $this->next_type = "tomorrow_project";
     $this->title = "明日のお仕事";
     $this->message = "急募!!明日スタートのお仕事です!!";
     $this->file = 'index_tomorrow.tpl';
     $this->view_display();
 }