/**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     if (!isset($_GET['mode'])) {
         $_GET['mode'] = "";
     }
     if (!isset($_GET['id'])) {
         $_GET['id'] = "";
     }
     if ($_GET['mode'] == "delete" && SC_Utils_Ex::sfCheckNumLength($_GET['id']) === true) {
         // メール担当の画像があれば削除しておく
         $sql = "SELECT charge_image FROM dtb_mailmaga_template WHERE template_id = ?";
         $result = $conn->getOne($sql, array($_GET["id"]));
         if (strlen($result) > 0) {
             @unlink(IMAGE_SAVE_DIR . $result);
         }
         // 登録削除
         $sql = "UPDATE dtb_mailmaga_template SET del_flg = 1 WHERE template_id = ?";
         $conn->query($sql, array($_GET['id']));
         $this->reload(null, true);
     }
     $sql = "SELECT *, create_date as disp_date FROM dtb_mailmaga_template WHERE del_flg = 0 ORDER BY create_date DESC";
     $this->list_data = $conn->getAll($sql);
     $this->list_data['disp_date'] = substr($this->list_data['disp_date'], 0, 19);
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     // 認証可否の判定
     $objSess = new SC_Session();
     SC_Utils_Ex::sfIsSuccess($objSess);
     $css_path = USER_PATH . "css/common.css";
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     // データ更新処理
     if ($_POST['mode'] == 'confirm') {
         // プレビュー用テンプレートに書き込み
         $fp = fopen($css_path, "w");
         // TODO
         fwrite($fp, $_POST['css']);
         fclose($fp);
         $this->tpl_onload = "alert('登録が完了しました。');";
     }
     // CSSファイルの読み込み
     if (file_exists($css_path)) {
         $css_data = file_get_contents($css_path);
     }
     // テキストエリアに表示
     $this->css_data = $css_data;
     // 画面の表示
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     // ログインチェック
     SC_Utils::sfIsSuccess(new SC_Session());
     // トランザクショントークンの取得
     $this->transactionid = $this->getToken();
     switch ($this->getMode()) {
         case 'new':
             $this->execNewMode();
             break;
         case 'edit':
             $this->execEditMode();
             break;
         case 'parent_reload':
             $this->execParentReloadMode();
             // defaultアクションも実行させるためbreakしない
         // defaultアクションも実行させるためbreakしない
         default:
             $this->execDefaultMode();
             break;
     }
     $objView = new SC_AdminView();
     $objView->assignobj($this);
     $objView->display('system/input.tpl');
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     // ログインチェック
     SC_Utils::sfIsSuccess(new SC_Session());
     $mode = isset($_GET['mode']) ? $_GET['mode'] : '';
     switch ($mode) {
         case 'detail':
             $objForm = $this->initParam();
             if ($objForm->checkError()) {
                 SC_Utils::sfDispError('');
             }
             $this->arrLogDetail = $this->getLogDetail($objForm->getValue('log_id'));
             if (count($this->arrLogDetail) == 0) {
                 SC_Utils::sfDispError('');
             }
             $this->tpl_mainpage = 'ownersstore/log_detail.tpl';
             break;
         default:
             break;
     }
     $this->arrInstallLogs = $this->getLogs();
     // ページ出力
     $objView = new SC_AdminView();
     $objView->assignObj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     // ログインチェック
     SC_Utils::sfIsSuccess(new SC_Session());
     $objView = new SC_AdminView();
     $objView->assignObj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objDb = new SC_Helper_DB_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         case 'delete':
             // ランク付きレコードの削除
             $objDb->sfDeleteRankRecord("dtb_payment", "payment_id", $_POST['payment_id']);
             // 再表示
             $this->reload();
             break;
         case 'up':
             $objDb->sfRankUp("dtb_payment", "payment_id", $_POST['payment_id']);
             // 再表示
             $this->reload();
             break;
         case 'down':
             $objDb->sfRankDown("dtb_payment", "payment_id", $_POST['payment_id']);
             // 再表示
             $this->reload();
             break;
     }
     $this->arrDelivList = $objDb->sfGetIDValueList("dtb_deliv", "deliv_id", "service_name");
     $this->arrPaymentListFree = $this->lfGetPaymentList(2);
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     $masterData = new SC_DB_MasterData_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess(new SC_Session());
     // キーの配列を生成
     $this->arrKeys = $this->getParamKeys($masterData);
     if (isset($_POST["mode"]) && $_POST["mode"] == "update") {
         // データの引き継ぎ
         $this->arrForm = $_POST;
         // エラーチェック
         $this->arrErr = $this->errorCheck();
         // エラーの無い場合は update
         if (empty($this->arrErr)) {
             $this->update();
             $this->tpl_onload = "window.alert('パラメータの設定が完了しました。');";
         } else {
             $this->arrValues = SC_Utils_Ex::getHash2Array($this->arrForm, $this->arrKeys);
             $this->tpl_onload = "window.alert('エラーが発生しました。入力内容をご確認下さい。');";
         }
     }
     if (empty($this->arrErr)) {
         $this->arrValues = SC_Utils_Ex::getHash2Array($masterData->getDBMasterData("mtb_constants"));
     }
     // コメント, 値の配列を生成
     $this->arrComments = SC_Utils_Ex::getHash2Array($masterData->getDBMasterData("mtb_constants", array("id", "remarks", "rank")));
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     if (SC_Utils_Ex::sfIsInt($_GET['send_id'])) {
         $objQuery = new SC_Query();
         $col = "subject, mail_body";
         $where = "send_id = ?";
         $arrRet = $objQuery->select($col, "dtb_mail_history", $where, array($_GET['send_id']));
         $this->tpl_subject = $arrRet[0]['subject'];
         $this->tpl_body = $arrRet[0]['mail_body'];
     }
     $objView->assignobj($this);
     $objView->display($this->tpl_mainpage);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     SC_Utils_Ex::sfIsSuccess(new SC_Session());
     $objView = new SC_AdminView();
     $this->initForm();
     switch ($this->objForm->getValue('mode')) {
         // PHP INFOを表示
         case 'info':
             phpinfo();
             exit;
             break;
         default:
             break;
     }
     $this->arrSystemInfo = $this->getSystemInfo();
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
Пример #10
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objQuery = new SC_Query();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     $cnt = $objQuery->count("dtb_baseinfo");
     if ($cnt > 0) {
         $this->tpl_mode = "update";
     } else {
         $this->tpl_mode = "insert";
     }
     if (isset($_POST['mode']) && !empty($_POST["mode"])) {
         // POSTデータの引き継ぎ
         $this->arrForm = $_POST;
         // 入力データの変換
         $this->arrForm = $this->lfConvertParam($this->arrForm);
         $this->arrForm['regular_holiday_ids'] = $_POST['regular_holiday_ids'];
         // 定休日情報を付加
         // 入力データのエラーチェック
         $this->arrErr = $this->lfErrorCheck($this->arrForm);
         if (count($this->arrErr) == 0) {
             switch ($_POST['mode']) {
                 case 'update':
                     $this->lfUpdateData($this->arrForm);
                     // 既存編集
                     break;
                 case 'insert':
                     $this->lfInsertData($this->arrForm);
                     // 新規作成
                     break;
                 default:
                     break;
             }
             $this->tpl_onload = "fnCheckLimit('downloadable_days', 'downloadable_days_unlimited', '" . DISABLED_RGB . "'); fnCheckLimit('max_download_cnt', 'download_cnt_unlimited', '" . DISABLED_RGB . "'); window.alert('SHOPマスタの登録が完了しました。');";
         }
         if (empty($this->arrForm['regular_holiday_ids'])) {
             $this->arrSel = array();
         } else {
             $this->arrSel = $this->arrForm['regular_holiday_ids'];
         }
     } else {
         $arrCol = $this->lfGetCol();
         $col = SC_Utils_Ex::sfGetCommaList($arrCol);
         $arrRet = $objQuery->select($col, "dtb_baseinfo");
         $this->arrForm = $arrRet[0];
         $regular_holiday_ids = explode('|', $this->arrForm['regular_holiday_ids']);
         $this->arrForm['regular_holiday_ids'] = $regular_holiday_ids;
         $this->tpl_onload = "fnCheckLimit('downloadable_days', 'downloadable_days_unlimited', '" . DISABLED_RGB . "'); fnCheckLimit('max_download_cnt', 'download_cnt_unlimited', '" . DISABLED_RGB . "');";
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // パラメータ管理クラス
     $this->objFormParam = new SC_FormParam();
     // パラメータ情報の初期化
     $this->lfInitParam();
     // POST値の取得
     $this->objFormParam->setParam($_POST);
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         case 'edit':
             // 入力値の変換
             $this->objFormParam->convParam();
             // エラーチェック
             $this->arrErr = $this->lfCheckError();
             if (count($this->arrErr) == 0) {
                 $this->lfSiteControlData($_POST['control_id']);
                 // javascript実行
                 $this->tpl_onload = "alert('更新が完了しました。');";
             }
             break;
         default:
             break;
     }
     // サイト管理情報の取得
     $arrSiteControlList = $this->lfGetControlList();
     $masterData = new SC_DB_MasterData_Ex();
     // プルダウンの作成
     for ($i = 0; $i < count($arrSiteControlList); $i++) {
         switch ($arrSiteControlList[$i]["control_id"]) {
             // トラックバック
             case SITE_CONTROL_TRACKBACK:
                 $arrSiteControlList[$i]["control_area"] = $masterData->getMasterData("mtb_site_control_track_back");
                 break;
                 // アフィリエイト
             // アフィリエイト
             case SITE_CONTROL_AFFILIATE:
                 $arrSiteControlList[$i]["control_area"] = $masterData->getMasterData("mtb_site_control_affiliate");
                 break;
             default:
                 break;
         }
     }
     $this->arrControlList = $arrSiteControlList;
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objQuery = new SC_Query();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // パラメータ管理クラス
     $this->objFormParam = new SC_FormParam();
     // パラメータ情報の初期化
     $this->lfInitParam();
     // POST値の取得
     $this->objFormParam->setParam($_POST);
     $cnt = $objQuery->count("dtb_baseinfo");
     if ($cnt > 0) {
         $this->tpl_mode = "update";
     } else {
         $this->tpl_mode = "insert";
     }
     if (isset($_POST['mode']) && !empty($_POST['mode'])) {
         // 入力値の変換
         $this->objFormParam->convParam();
         $this->arrErr = $this->lfCheckError();
         if (count($this->arrErr) == 0) {
             switch ($_POST['mode']) {
                 case 'update':
                     $this->lfUpdateData();
                     // 既存編集
                     break;
                 case 'insert':
                     $this->lfInsertData();
                     // 新規作成
                     break;
                 default:
                     break;
             }
             // 再表示
             //sfReload();
             $this->tpl_onload = "window.alert('特定商取引法の登録が完了しました。');";
         }
     } else {
         $arrCol = $this->objFormParam->getKeyList();
         // キー名一覧を取得
         $col = SC_Utils_Ex::sfGetCommaList($arrCol);
         $arrRet = $objQuery->select($col, "dtb_baseinfo");
         // DB値の取得
         $this->objFormParam->setParam($arrRet[0]);
     }
     $this->arrForm = $this->objFormParam->getFormParamList();
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
Пример #13
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // ADMIN_ID以外の管理者件数を取得
     $linemax = $this->getMemberCount("del_flg <> 1 AND member_id <> " . ADMIN_ID);
     // ADMIN_ID以外で稼動中の管理者件数を取得
     $this->workmax = $this->getMemberCount("work = 1 AND del_flg <> 1 AND member_id <> " . ADMIN_ID);
     // ページ送りの処理
     $pageno = isset($_GET['pageno']) ? $_GET['pageno'] : 1;
     $objNavi = new SC_PageNavi($pageno, $linemax, MEMBER_PMAX, "fnMemberPage", NAVI_PMAX);
     $this->tpl_strnavi = $objNavi->strnavi;
     $this->tpl_disppage = $objNavi->now_page;
     $this->tpl_pagemax = $objNavi->max_page;
     // 取得範囲を指定(開始行番号、行数のセット)して管理者データを取得
     $this->list_data = $this->getMemberData($objNavi->start_row);
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     // ログインチェック
     SC_Utils::sfIsSuccess(new SC_Session());
     // トランザクションIDの取得
     $this->transactionid = $this->getToken();
     // $_POST['mode']によってアクション振り分け
     switch ($this->getMode()) {
         // 入力内容をDBへ登録する
         case 'register':
             $this->execRegisterMode();
             break;
             // 初回表示
         // 初回表示
         default:
             $this->execDefaultMode();
     }
     // ページ出力
     $objView = new SC_AdminView();
     $objView->assignObj($this);
     $objView->display(MAIN_FRAME);
 }
Пример #15
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objQuery = new SC_Query();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // データの取得
     $objLayout = new SC_Helper_PageLayout_Ex();
     $this->arrPageData = $objLayout->lfgetPageData(" edit_flg = 2 ");
     if (isset($_POST['page_id'])) {
         $page_id = $_POST['page_id'];
     } else {
         $page_id = "";
     }
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     if ($_POST['mode'] == "confirm") {
         // エラーチェック
         $this->arrErr[$page_id] = $this->lfErrorCheck($_POST['meta'][$page_id]);
         // エラーがなければデータを更新
         if (count($this->arrErr[$page_id]) == 0) {
             // 更新データの変換
             $arrMETA = $this->lfConvertParam($_POST['meta'][$page_id]);
             // 更新データ配列生成
             $arrUpdData = array($arrMETA['author'], $arrMETA['description'], $arrMETA['keyword'], $page_id);
             // データ更新
             $this->lfUpdPageData($arrUpdData);
         } else {
             // POSTのデータを再表示
             $arrPageData = $this->lfSetData($arrPageData, $_POST['meta']);
             $this->arrPageData = $arrPageData;
         }
     }
     $arrDisp_flg = array();
     // エラーがなければデータの取得
     if (count($this->arrErr[$page_id]) == 0) {
         // データの取得
         $arrPageData = $objLayout->lfgetPageData(" edit_flg = 2 ");
         $this->arrPageData = $arrPageData;
     }
     // 表示・非表示切り替え
     foreach ($arrPageData as $key => $val) {
         $arrDisp_flg[$val['page_id']] = $_POST['disp_flg' . $val['page_id']];
     }
     $this->disp_flg = $arrDisp_flg;
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     //---- ページ初期設定
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objDate = new SC_Date();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     if (!isset($_GET['send_id'])) {
         $_GET['send_id'] = "";
     }
     if (!isset($_GET['mode'])) {
         $_GET['mode'] = "";
     }
     if (!isset($_POST['search_pageno'])) {
         $_POST['search_pageno'] = "";
     }
     // 削除時
     if (SC_Utils_Ex::sfCheckNumLength($_GET['send_id']) && $_GET['mode'] == 'delete') {
         $sql = "UPDATE dtb_send_history SET del_flg = 1 WHERE send_id = ?";
         $conn->query($sql, array($_GET['send_id']));
         $_SERVER['QUERY_STRING'] = "";
         $this->reload();
     }
     $col = "*";
     $from = "dtb_send_history";
     $where = " del_flg = ?";
     $arrval[] = "0";
     $objQuery = new SC_Query();
     // 行数の取得
     $linemax = $objQuery->count($from, $where, $arrval);
     $this->tpl_linemax = $linemax;
     // 何件が該当しました。表示用
     // ページ送りの取得
     $objNavi = new SC_PageNavi($_POST['search_pageno'], $linemax, SEARCH_PMAX, "fnNaviSearchPage", NAVI_PMAX);
     $this->tpl_strnavi = $objNavi->strnavi;
     // 表示文字列
     $startno = $objNavi->start_row;
     // 取得範囲の指定(開始行番号、行数のセット)
     $objQuery->setlimitoffset(SEARCH_PMAX, $startno);
     // 表示順序
     $order = "start_date DESC, send_id DESC";
     $objQuery->setorder($order);
     // 検索結果の取得
     $this->arrDataList = $objQuery->select($col, $from, $where, $arrval);
     //---- ページ表示
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
Пример #17
0
 /**
  * Page のプロセス。
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     switch ($this->type) {
         case LOGIN_ERROR:
             $this->tpl_error = "IDまたはパスワードが正しくありません。<br />もう一度ご確認のうえ、再度入力してください。";
             break;
         case ACCESS_ERROR:
             $this->tpl_error = "ログイン認証の有効期限切れの可能性があります。<br />もう一度ご確認のうえ、再度ログインしてください。";
             break;
         case AUTH_ERROR:
             $this->tpl_error = "このファイルにはアクセス権限がありません。<br />もう一度ご確認のうえ、再度ログインしてください。";
             break;
         case INVALID_MOVE_ERRORR:
             $this->tpl_error = "不正なページ移動です。<br />もう一度ご確認のうえ、再度入力してください。";
             break;
         default:
             $this->tpl_error = "エラーが発生しました。<br />もう一度ご確認のうえ、再度ログインしてください。";
             break;
     }
     $objView->assignobj($this);
     $objView->display(LOGIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objDb = new SC_Helper_DB_Ex();
     $objQuery = new SC_Query();
     // 認証可否の判定
     $objSess = new SC_Session();
     SC_Utils_Ex::sfIsSuccess($objSess);
     $this->arrForm = $_POST;
     //支払方法の取得
     $this->arrPayment = $objDb->sfGetIDValueList("dtb_payment", "payment_id", "payment_method");
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     if (!isset($_POST['search_pageno'])) {
         $_POST['search_pageno'] = 1;
     }
     switch ($_POST['mode']) {
         case 'update':
             if (!isset($_POST['change_status'])) {
                 $_POST['change_status'] = "";
             }
             if ($_POST['change_status'] == 'delete') {
                 $this->lfStatusMove("delete", $_POST['move']);
             } elseif (!empty($_POST['change_status'])) {
                 $this->lfStatusMove($_POST['change_status'], $_POST['move']);
             }
             //ステータス情報
             $status = isset($_POST['status']) ? $_POST['status'] : "";
             break;
         case 'search':
             //ステータス情報
             $status = isset($_POST['status']) ? $_POST['status'] : "";
             break;
         default:
             //ステータス情報
             //デフォルトで新規受付一覧表示
             $status = ORDER_NEW;
             break;
     }
     //ステータス情報
     $this->SelectedStatus = $status;
     //検索結果の表示
     $this->lfStatusDisp($status, $_POST['search_pageno']);
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objQuery = new SC_Query();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     //検索ワードの引継ぎ
     foreach ($_POST as $key => $val) {
         if (ereg("^search_", $key)) {
             $this->arrSearchHidden[$key] = $val;
         }
     }
     // 状態の設定
     $masterData = new SC_DB_MasterData_Ex();
     $this->arrTrackBackStatus = $masterData->getMasterData("mtb_track_back_status");
     //取得文字列の変換用カラム
     $arrRegistColumn = array(array("column" => "update_date"), array("column" => "status"), array("column" => "title", "convert" => "KVa"), array("column" => "excerpt", "convert" => "KVa"), array("column" => "blog_name", "convert" => "KVa"), array("column" => "url", "convert" => "KVa"), array("column" => "del_flg", "convert" => "n"));
     // トラックバックIDを渡す
     $this->tpl_trackback_id = $_POST['trackback_id'];
     // トラックバック情報のカラムの取得
     $this->arrTrackback = $this->lfGetTrackbackData($_POST['trackback_id'], $objQuery);
     // 商品ごとのトラックバック表示数取得
     $count = $objQuery->count("dtb_trackback", "del_flg = 0 AND product_id = ?", array($this->arrTrackback['product_id']));
     // 両方選択可能
     $this->tpl_status_change = true;
     switch ($_POST['mode']) {
         // 登録
         case 'complete':
             //フォーム値の変換
             $arrTrackback = $this->lfConvertParam($_POST, $arrRegistColumn);
             $this->arrErr = $this->lfCheckError($arrTrackback);
             //エラー無し
             if (!$this->arrErr) {
                 //レビュー情報の編集登録
                 $this->lfRegistTrackbackData($arrTrackback, $arrRegistColumn, $objQuery);
                 $this->arrTrackback = $arrTrackback;
                 $this->tpl_onload = "confirm('登録が完了しました。');";
             }
             break;
         default:
             break;
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     $this->mode = "regist";
     // idが指定されているときは「編集」表示
     if (!isset($_REQUEST['template_id'])) {
         $_REQUEST['template_id'] = "";
     }
     if ($_REQUEST['template_id']) {
         $this->title = "編集";
     } else {
         $this->title = "新規登録";
     }
     if (!isset($_GET['mode'])) {
         $_GET['mode'] = "";
     }
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     // モードによる処理分岐
     if ($_GET['mode'] == 'edit' && SC_Utils_Ex::sfCheckNumLength($_GET['template_id']) === true) {
         // 編集
         $sql = "SELECT * FROM dtb_mailmaga_template WHERE template_id = ? AND del_flg = 0";
         $result = $conn->getAll($sql, array($_GET['template_id']));
         $this->arrForm = $result[0];
     } elseif ($_POST['mode'] == 'regist') {
         // 新規登録
         $this->arrForm = $this->lfConvData($_POST);
         $this->arrErr = $this->lfErrorCheck($this->arrForm);
         if (!$this->arrErr) {
             // エラーが無いときは登録・編集
             $this->lfRegistData($this->arrForm, $_POST['template_id']);
             // 自分を再読込して、完了画面へ遷移
             $this->reload(array("mode" => "complete"));
         }
     } elseif ($_GET['mode'] == 'complete') {
         // 完了画面表示
         $this->tpl_mainpage = 'mail/template_complete.tpl';
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $this->objQuery = new SC_Query();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // 検索ワードの引継ぎ
     foreach ($_POST as $key => $val) {
         if (ereg("^search_", $key)) {
             $this->arrSearchHidden[$key] = $val;
         }
     }
     // 両方選択可能
     $this->tpl_status_change = true;
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         // 登録
         case 'complete':
             // 取得文字列の変換用カラム
             $arrRegistColumn = array(array("column" => "status"), array("column" => "recommend_level"), array("column" => "title", "convert" => "KVa"), array("column" => "comment", "convert" => "KVa"), array("column" => "reviewer_name", "convert" => "KVa"), array("column" => "reviewer_url", "convert" => "KVa"), array("column" => "sex", "convert" => "n"));
             // フォーム値の変換
             $arrReview = $this->lfConvertParam($_POST, $arrRegistColumn);
             $this->arrErr = $this->lfCheckError($arrReview);
             // エラー有り
             if ($this->arrErr) {
                 // 入力内容を引き継ぐ
                 $this->arrReview = $arrReview;
             } else {
                 // レビュー情報の更新
                 $this->lfRegistReviewData($arrReview, $arrRegistColumn);
                 // レビュー情報のDB取得
                 $this->arrReview = $this->lfGetReviewData($arrReview['review_id']);
                 $this->tpl_onload = "alert('登録が完了しました。');";
             }
             break;
         default:
             // レビュー情報のDB取得
             $this->arrReview = $this->lfGetReviewData($_POST['review_id']);
             break;
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     SC_Utils_Ex::sfIsSuccess(new SC_Session());
     $objView = new SC_AdminView();
     $this->arrMasterDataName = $this->getMasterDataNames(array("mtb_pref", "mtb_zip", "mtb_constants"));
     $masterData = new SC_DB_MasterData_Ex();
     if (!isset($_POST["mode"])) {
         $_POST["mode"] = "";
     }
     switch ($_POST["mode"]) {
         case "edit":
             // POST 文字列の妥当性チェック
             $this->checkMasterDataName();
             $this->errorMessage = $this->checkUniqueID();
             if (empty($this->errorMessage)) {
                 // 取得したデータからマスタデータを生成
                 $arrData = array();
                 foreach ($_POST['id'] as $key => $val) {
                     // ID が空のデータは生成しない
                     if ($val != "") {
                         $arrData[$val] = $_POST['name'][$key];
                     }
                 }
                 // マスタデータを更新
                 $masterData->objQuery = new SC_Query();
                 $masterData->objQuery->begin();
                 $masterData->deleteMasterData($this->masterDataName, false);
                 // TODO カラム名はメタデータから取得した方が良い
                 $masterData->registMasterData($this->masterDataName, array("id", "name", "rank"), $arrData, false);
                 $masterData->objQuery->commit();
                 $this->tpl_onload = "window.alert('マスタデータの設定が完了しました。');";
             }
         case "show":
             // POST 文字列の妥当性チェック
             $this->checkMasterDataName();
             // DB からマスタデータを取得
             $this->arrMasterData = $masterData->getDbMasterData($this->masterDataName);
             break;
         default:
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objDb = new SC_Helper_DB_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     $this->tpl_pageno = isset($_POST['pageno']) ? $_POST['pageno'] : "";
     // 通常時は親カテゴリを0に設定する。
     $this->arrForm['parent_category_id'] = isset($_POST['parent_category_id']) ? $_POST['parent_category_id'] : 0;
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         case 'up':
             $where = "category_id = " . SC_Utils_Ex::sfQuoteSmart($_POST['parent_category_id']);
             $objDb->sfRankUp("dtb_product_categories", "product_id", $_POST['product_id'], $where);
             break;
         case 'down':
             $where = "category_id = " . SC_Utils_Ex::sfQuoteSmart($_POST['parent_category_id']);
             $objDb->sfRankDown("dtb_product_categories", "product_id", $_POST['product_id'], $where);
             break;
         case 'move':
             $key = "pos-" . $_POST['product_id'];
             $input_pos = mb_convert_kana($_POST[$key], "n");
             if (SC_Utils_Ex::sfIsInt($input_pos)) {
                 $where = "category_id = " . SC_Utils_Ex::sfQuoteSmart($_POST['parent_category_id']);
                 $objDb->sfMoveRank("dtb_product_categories", "product_id", $_POST['product_id'], $input_pos, $where);
             }
             break;
         case 'tree':
             // カテゴリの切替は、ページ番号をクリアする。
             $this->tpl_pageno = "";
             break;
         default:
             break;
     }
     $this->arrTree = $objDb->sfGetCatTree($this->arrForm['parent_category_id']);
     $this->arrProductsList = $this->lfGetProduct($this->arrForm['parent_category_id']);
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
Пример #24
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $masterData = new SC_DB_MasterData_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     $this->arrMailTEMPLATE = $masterData->getMasterData("mtb_mail_template");
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     if ($_POST['mode'] == 'id_set') {
         // テンプレートプルダウン変更時
         if (SC_Utils_Ex::sfCheckNumLength($_POST['template_id'])) {
             $sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = ?";
             $result = $conn->getAll($sql, array($_POST['template_id']));
             if ($result) {
                 $this->arrForm = $result[0];
             } else {
                 $this->arrForm['template_id'] = $_POST['template_id'];
             }
         }
     } elseif ($_POST['mode'] == 'regist' && SC_Utils_Ex::sfCheckNumLength($_POST['template_id'])) {
         // POSTデータの引き継ぎ
         $this->arrForm = $this->lfConvertParam($_POST);
         $this->arrErr = $this->fnErrorCheck($this->arrForm);
         if ($this->arrErr) {
             // エラーメッセージ
             $this->tpl_msg = "エラーが発生しました";
         } else {
             // 正常
             $this->lfRegist($conn, $this->arrForm);
             // 完了メッセージ
             $this->tpl_onload = "window.alert('メール設定が完了しました。テンプレートを選択して内容をご確認ください。');";
             unset($this->arrForm);
         }
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
Пример #25
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // DBバージョンの取得
     $objDb = new SC_Helper_DB_Ex();
     $this->db_version = $objDb->sfGetDBVersion();
     // PHPバージョンの取得
     $this->php_version = "PHP " . phpversion();
     // 現在の会員数
     $this->customer_cnt = $this->lfGetCustomerCnt($conn);
     // 昨日の売上高
     $this->order_yesterday_amount = $this->lfGetOrderYesterday($conn, "SUM");
     // 昨日の売上件数
     $this->order_yesterday_cnt = $this->lfGetOrderYesterday($conn, "COUNT");
     // 今月の売上高
     $this->order_month_amount = $this->lfGetOrderMonth($conn, "SUM");
     // 今月の売上件数
     $this->order_month_cnt = $this->lfGetOrderMonth($conn, "COUNT");
     // 顧客の累計ポイント
     $this->customer_point = $this->lfGetTotalCustomerPoint();
     //昨日のレビュー書き込み数
     $this->review_yesterday_cnt = $this->lfGetReviewYesterday($conn);
     //レビュー書き込み非表示数
     $this->review_nondisp_cnt = $this->lfGetReviewNonDisp($conn);
     // 品切れ商品
     $this->arrSoldout = $this->lfGetSoldOut();
     // 新規受付一覧
     $arrNewOrder = $this->lfGetNewOrder();
     foreach ($arrNewOrder as $key => $val) {
         $arrNewOrder[$key]['create_date'] = str_replace("-", "/", substr($val['create_date'], 0, 19));
     }
     $this->arrNewOrder = $arrNewOrder;
     // お知らせ一覧の取得
     $this->arrInfo = $this->lfGetInfo();
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objQuery = new SC_Query();
     $objDb = new SC_Helper_DB_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         case 'delete':
             // ランク付きレコードの削除
             $objDb->sfDeleteRankRecord("dtb_deliv", "deliv_id", $_POST['deliv_id']);
             // 再表示
             SC_Utils_Ex::sfReload();
             break;
         case 'up':
             $objDb->sfRankUp("dtb_deliv", "deliv_id", $_POST['deliv_id']);
             // 再表示
             SC_Utils_Ex::sfReload();
             break;
         case 'down':
             $objDb->sfRankDown("dtb_deliv", "deliv_id", $_POST['deliv_id']);
             // 再表示
             SC_Utils_Ex::sfReload();
             break;
         default:
             break;
     }
     // 配送業者一覧の取得
     $col = "deliv_id, name, service_name";
     $where = "del_flg = 0";
     $table = "dtb_deliv";
     $objQuery->setorder("rank DESC");
     $this->arrDelivList = $objQuery->select($col, $table, $where);
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objQuery = new SC_Query();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // パラメータ管理クラス
     $this->objFormParam = new SC_FormParam();
     // パラメータ情報の初期化
     $this->lfInitParam();
     // POST値の取得
     $this->objFormParam->setParam($_POST);
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         case 'edit':
             // 入力値の変換
             $this->objFormParam->convParam();
             $this->arrErr = $this->lfCheckError();
             if (count($this->arrErr) == 0) {
                 $this->tpl_deliv_id = $this->lfRegistData();
                 $this->tpl_onload = "window.alert('配送業者設定が完了しました。');";
             }
             break;
         case 'pre_edit':
             if ($_POST['deliv_id'] != "") {
                 $this->lfGetDelivData($_POST['deliv_id']);
                 $this->tpl_deliv_id = $_POST['deliv_id'];
             }
             break;
         default:
             break;
     }
     $this->arrForm = $this->objFormParam->getFormParamList();
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objDb = new SC_Helper_DB_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     // ファイル管理クラス
     $this->objUpFile = new SC_UploadFile(IMAGE_TEMP_DIR, IMAGE_SAVE_DIR);
     // ファイル情報の初期化
     $this->objUpFile = $this->lfInitFile();
     // Hiddenからのデータを引き継ぐ
     $this->objUpFile->setHiddenFileList($_POST);
     // パラメータ管理クラス
     $this->objFormParam = new SC_FormParam();
     // パラメータ情報の初期化
     $this->lfInitParam();
     // POST値の取得
     $this->objFormParam->setParam($_POST);
     switch ($_POST['mode']) {
         case 'edit':
             // 入力値の変換
             $this->objFormParam->convParam();
             // エラーチェック
             $this->arrErr = $this->lfCheckError();
             $this->charge_flg = $_POST["charge_flg"];
             if (count($this->arrErr) == 0) {
                 $this->lfRegistData($_POST['payment_id']);
                 // 一時ファイルを本番ディレクトリに移動する
                 $this->objUpFile->moveTempFile();
                 // 親ウィンドウを更新するようにセットする。
                 $this->tpl_onload = "fnUpdateParent('" . URL_PAYMENT_TOP . "'); window.close();";
             }
             break;
             // 画像のアップロード
         // 画像のアップロード
         case 'upload_image':
             // ファイル存在チェック
             $this->arrErr = $this->objUpFile->checkEXISTS($_POST['image_key']);
             // 画像保存処理
             $this->arrErr[$_POST['image_key']] = $this->objUpFile->makeTempFile($_POST['image_key']);
             break;
             // 画像の削除
         // 画像の削除
         case 'delete_image':
             $this->objUpFile->deleteFile($_POST['image_key']);
             break;
         default:
             break;
     }
     if ($_POST['mode'] == "") {
         switch ($_GET['mode']) {
             case 'pre_edit':
                 if (SC_Utils_Ex::sfIsInt($_GET['payment_id'])) {
                     $arrRet = $this->lfGetData($_GET['payment_id']);
                     $this->objFormParam->setParam($arrRet);
                     $this->charge_flg = $arrRet["charge_flg"];
                     // DBデータから画像ファイル名の読込
                     $this->objUpFile->setDBFileList($arrRet);
                     $this->tpl_payment_id = $_GET['payment_id'];
                 }
                 break;
             default:
                 break;
         }
     } else {
         $this->tpl_payment_id = $_POST['payment_id'];
     }
     $this->arrDelivList = $objDb->sfGetIDValueList("dtb_deliv", "deliv_id", "service_name");
     $this->arrForm = $this->objFormParam->getFormParamList();
     // FORM表示用配列を渡す。
     $this->arrFile = $this->objUpFile->getFormFileList(IMAGE_TEMP_URL, IMAGE_SAVE_URL);
     // HIDDEN用に配列を渡す。
     $this->arrHidden = array_merge((array) $this->arrHidden, (array) $this->objUpFile->getHiddenFileList());
     $objView->assignobj($this);
     $objView->display($this->tpl_mainpage);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $objView = new SC_AdminView();
     // 認証可否の判定
     $objSess = new SC_Session();
     SC_Utils_Ex::sfIsSuccess($objSess);
     // 検索パラメータの引き継ぎ
     foreach ($_POST as $key => $val) {
         if (ereg("^search_", $key)) {
             $this->arrSearchHidden[$key] = $val;
         }
     }
     $this->tpl_product_id = isset($_POST['product_id']) ? $_POST['product_id'] : "";
     $this->tpl_pageno = isset($_POST['pageno']) ? $_POST['pageno'] : "";
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     switch ($_POST['mode']) {
         // 規格削除要求
         case 'delete':
             $objQuery = new SC_Query();
             $objQuery->setLimitOffset(1);
             $where = "product_id = ? AND NOT (classcategory_id1 = 0 AND classcategory_id2 = 0)";
             $objQuery->setOrder("rank1 DESC, rank2 DESC");
             $arrRet = $objQuery->select("*", "vw_cross_products_class AS crs_prd", $where, array($_POST['product_id']));
             if (count($arrRet) > 0) {
                 $sqlval['product_id'] = $arrRet[0]['product_id'];
                 $sqlval['classcategory_id1'] = '0';
                 $sqlval['classcategory_id2'] = '0';
                 $sqlval['product_code'] = $arrRet[0]['product_code'];
                 $sqlval['stock'] = $arrRet[0]['stock'];
                 $sqlval['price01'] = $arrRet[0]['price01'];
                 $sqlval['price02'] = $arrRet[0]['price02'];
                 $sqlval['creator_id'] = $_SESSION['member_id'];
                 $sqlval['create_date'] = "now()";
                 $sqlval['update_date'] = "now()";
                 $objQuery->begin();
                 $where = "product_id = ?";
                 $objQuery->delete("dtb_products_class", $where, array($_POST['product_id']));
                 $objQuery->insert("dtb_products_class", $sqlval);
                 $objQuery->commit();
             }
             $this->lfProductClassPage();
             // 規格登録ページ
             break;
             // 編集要求
         // 編集要求
         case 'pre_edit':
             $objQuery = new SC_Query();
             $where = "product_id = ? AND NOT(classcategory_id1 = 0 AND classcategory_id2 = 0) ";
             $ret = $objQuery->count("dtb_products_class", $where, array($_POST['product_id']));
             if ($ret > 0) {
                 // 規格組み合わせ一覧の取得(DBの値を優先する。)
                 $this->arrClassCat = $this->lfGetClassCatListEdit($_POST['product_id']);
             }
             $this->lfProductClassPage();
             // 規格登録ページ
             break;
             // 規格組み合わせ表示
         // 規格組み合わせ表示
         case 'disp':
             $this->arrForm['select_class_id1'] = $_POST['select_class_id1'];
             $this->arrForm['select_class_id2'] = $_POST['select_class_id2'];
             $this->arrErr = $this->lfClassError();
             if (count($this->arrErr) == 0) {
                 // 規格組み合わせ一覧の取得
                 $this->arrClassCat = $this->lfGetClassCatListDisp($_POST['select_class_id1'], $_POST['select_class_id2']);
             }
             $this->lfProductClassPage();
             // 規格登録ページ
             break;
             // 規格登録要求
         // 規格登録要求
         case 'edit':
             // 入力値の変換
             $this->arrForm = $this->lfConvertParam($_POST);
             // エラーチェック
             $this->arrErr = $this->lfProductClassError($this->arrForm);
             if (count($this->arrErr) == 0) {
                 // 確認ページ設定
                 $this->tpl_mainpage = 'products/product_class_confirm.tpl';
                 $this->lfProductConfirmPage();
                 // 確認ページ表示
             } else {
                 // 規格組み合わせ一覧の取得
                 $this->arrClassCat = $this->lfGetClassCatListDisp($_POST['class_id1'], $_POST['class_id2'], false);
                 $this->lfProductClassPage();
                 // 規格登録ページ
             }
             break;
             // 確認ページからの戻り
         // 確認ページからの戻り
         case 'confirm_return':
             // フォームパラメータの引き継ぎ
             $this->arrForm = $_POST;
             // 規格の選択情報は引き継がない。
             $this->arrForm['select_class_id1'] = "";
             $this->arrForm['select_class_id2'] = "";
             // 規格組み合わせ一覧の取得(デフォルト値は出力しない)
             $this->arrClassCat = $this->lfGetClassCatListDisp($_POST['class_id1'], $_POST['class_id2'], false);
             $this->lfProductClassPage();
             // 規格登録ページ
             break;
         case 'complete':
             // 完了ページ設定
             $this->tpl_mainpage = 'products/product_class_complete.tpl';
             // 商品規格の登録
             $this->lfInsertProductClass($_POST, $_POST['product_id']);
             break;
         default:
             $this->lfProductClassPage();
             // 規格登録ページ
             break;
     }
     $objView->assignobj($this);
     $objView->display(MAIN_FRAME);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 function process()
 {
     $conn = new SC_DBConn();
     $objView = new SC_AdminView();
     $objSess = new SC_Session();
     $objDb = new SC_Helper_DB_Ex();
     // 認証可否の判定
     SC_Utils_Ex::sfIsSuccess($objSess);
     if (!isset($_POST['mode'])) {
         $_POST['mode'] = "";
     }
     if ($_POST['mode'] == "search") {
         // POST値の引き継ぎ
         $this->arrForm = $_POST;
         // 入力文字の強制変換
         $this->lfConvertParam();
         $where = "del_flg = 0 AND status = 1";
         /* 入力エラーなし */
         foreach ($this->arrForm as $key => $val) {
             if ($val == "") {
                 continue;
             }
             switch ($key) {
                 case 'search_name':
                     $where .= " AND name ILIKE ?";
                     $arrval[] = "%{$val}%";
                     break;
                 case 'search_category_id':
                     list($tmp_where, $tmp_arrval) = $objDb->sfGetCatWhere($val);
                     if ($tmp_where != "") {
                         $where .= " AND product_id IN (SELECT product_id FROM dtb_product_categories WHERE " . $tmp_where . ")";
                         $arrval = array_merge((array) $arrval, (array) $tmp_arrval);
                     }
                     break;
                 case 'search_product_code':
                     $where .= " AND product_id IN (SELECT product_id FROM dtb_products_class WHERE product_code LIKE ? GROUP BY product_id)";
                     $arrval[] = "{$val}%";
                     break;
                 default:
                     break;
             }
         }
         $order = "update_date DESC, product_id DESC";
         // 読み込む列とテーブルの指定
         $col = "product_id, name, category_id, main_list_image, status, product_code, price01, stock, stock_unlimited";
         $from = "vw_products_nonclass AS noncls ";
         $objQuery = new SC_Query();
         // 行数の取得
         if (empty($arrval)) {
             $arrval = array();
         }
         $linemax = $objQuery->count("dtb_products", $where, $arrval);
         $this->tpl_linemax = $linemax;
         // 何件が該当しました。表示用
         // ページ送りの処理
         if (isset($_POST['search_page_max']) && is_numeric($_POST['search_page_max'])) {
             $page_max = $_POST['search_page_max'];
         } else {
             $page_max = SEARCH_PMAX;
         }
         // ページ送りの取得
         $objNavi = new SC_PageNavi($_POST['search_pageno'], $linemax, $page_max, "fnNaviSearchOnlyPage", NAVI_PMAX);
         $this->tpl_strnavi = $objNavi->strnavi;
         // 表示文字列
         $startno = $objNavi->start_row;
         // 取得範囲の指定(開始行番号、行数のセット)
         $objQuery->setlimitoffset($page_max, $startno);
         // 表示順序
         $objQuery->setorder($order);
         // 検索結果の取得
         $this->arrProducts = $objQuery->select($col, $from, $where, $arrval);
     }
     // カテゴリ取得
     $this->arrCatList = $objDb->sfGetCategoryList();
     //---- ページ表示
     $objView->assignobj($this);
     $objView->display($this->tpl_mainpage);
 }