예제 #1
0
 /**
  * Page のAction.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     SC_Response_Ex::sendRedirect(DIR_INDEX_PATH);
 }
예제 #2
0
 /**
  * Page のAction.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objCustomer = new SC_Customer_Ex();
     $customer_id = $objCustomer->getValue('customer_id');
     //ページ送り用
     $this->objNavi = new SC_PageNavi_Ex($_REQUEST['pageno'], $this->lfGetOrderHistory($customer_id), SEARCH_PMAX, 'eccube.movePage', NAVI_PMAX, 'pageno=#page#', SC_Display_Ex::detectDevice() !== DEVICE_TYPE_MOBILE);
     $this->arrOrder = $this->lfGetOrderHistory($customer_id, $this->objNavi->start_row);
     switch ($this->getMode()) {
         case 'getList':
             echo SC_Utils_Ex::jsonEncode($this->arrOrder);
             SC_Response_Ex::actionExit();
             break;
         default:
             break;
     }
     // 支払い方法の取得
     $this->arrPayment = SC_Helper_Payment_Ex::getIDValueList();
     // 1ページあたりの件数
     $this->dispNumber = SEARCH_PMAX;
     $this->json_payment = SC_Utils::jsonEncode($this->arrPayment);
     $this->json_customer_order_status = SC_Utils::jsonEncode($this->arrCustomerOrderStatus);
 }
예제 #3
0
 /**
  * Page のアクション.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $this->tpl_title = '';
     $objCustomer = new SC_Customer_Ex();
     $this->isLogin = $objCustomer->isLoginSuccess(true);
 }
 /**
  * Page のアクション.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $arrKiyaku = $this->lfGetKiyakuData();
     $this->max = count($arrKiyaku);
     // mobile時はGETでページ指定
     if (SC_Display_Ex::detectDevice() == DEVICE_TYPE_MOBILE) {
         $this->offset = $this->lfSetOffset($_GET['offset']);
     }
     $this->tpl_kiyaku_text = $this->lfMakeKiyakuText($arrKiyaku, $this->max, $this->offset);
 }
 /**
  * Page のAction.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     //受注詳細データの取得
     $arrOrderDetail = $this->lfGetOrderDetail($_POST['order_id']);
     //ログインしていない、またはDBに情報が無い場合
     if (empty($arrOrderDetail)) {
         SC_Utils_Ex::sfDispSiteError(CUSTOMER_ERROR);
     }
     $this->lfAddCartProducts($arrOrderDetail);
     SC_Response_Ex::sendRedirect(CART_URL);
 }
예제 #6
0
 /**
  * Page のAction.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objProduct = new SC_Product_Ex();
     // パラメーター管理クラス
     $objFormParam = new SC_FormParam_Ex();
     // パラメーター情報の初期化
     $this->lfInitParam($objFormParam);
     // 値の設定
     $objFormParam->setParam($_REQUEST);
     // 入力値の変換
     $objFormParam->convParam();
     // 値の取得
     $this->arrForm = $objFormParam->getHashArray();
     //modeの取得
     $this->mode = $this->getMode();
     //表示条件の取得
     $this->arrSearchData = array('category_id' => $this->lfGetCategoryId(intval($this->arrForm['category_id'])), 'maker_id' => intval($this->arrForm['maker_id']), 'name' => $this->arrForm['name']);
     $this->orderby = $this->arrForm['orderby'];
     //ページング設定
     $this->tpl_pageno = $this->arrForm['pageno'];
     $this->disp_number = $this->lfGetDisplayNum($this->arrForm['disp_number']);
     // 画面に表示するサブタイトルの設定
     $this->tpl_subtitle = $this->lfGetPageTitle($this->mode, $this->arrSearchData['category_id']);
     // 画面に表示する検索条件を設定
     $this->arrSearch = $this->lfGetSearchConditionDisp($this->arrSearchData);
     // 商品一覧データの取得
     $arrSearchCondition = $this->lfGetSearchCondition($this->arrSearchData);
     $this->tpl_linemax = $this->lfGetProductAllNum($arrSearchCondition);
     $urlParam = "category_id={$this->arrSearchData['category_id']}&pageno=#page#";
     // モバイルの場合に検索条件をURLの引数に追加
     if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_MOBILE) {
         $searchNameUrl = urlencode(mb_convert_encoding($this->arrSearchData['name'], 'SJIS-win', 'UTF-8'));
         $urlParam .= "&mode={$this->mode}&name={$searchNameUrl}&orderby={$this->orderby}";
     }
     $this->objNavi = new SC_PageNavi_Ex($this->tpl_pageno, $this->tpl_linemax, $this->disp_number, 'eccube.movePage', NAVI_PMAX, $urlParam, SC_Display_Ex::detectDevice() !== DEVICE_TYPE_MOBILE);
     $this->arrProducts = $this->lfGetProductsList($arrSearchCondition, $this->disp_number, $this->objNavi->start_row, $objProduct);
     switch ($this->getMode()) {
         case 'json':
             $this->doJson($objProduct);
             break;
         default:
             $this->doDefault($objProduct, $objFormParam);
             break;
     }
     $this->tpl_rnd = SC_Utils_Ex::sfGetRandomString(3);
 }
 /**
  * Page のプロセス.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objSiteSess = new SC_SiteSession_Ex();
     $objCartSess = new SC_CartSession_Ex();
     $objCustomer = new SC_Customer_Ex();
     $objFormParam = new SC_FormParam_Ex();
     $objAddress = new SC_Helper_Address_Ex();
     // 複数配送先指定が無効な場合はエラー
     if (USE_MULTIPLE_SHIPPING === false) {
         SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, '', true);
         SC_Response_Ex::actionExit();
     }
     $this->tpl_uniqid = $objSiteSess->getUniqId();
     $this->addrs = $this->getDelivAddrs($objCustomer, $objPurchase, $objAddress);
     $this->tpl_addrmax = count($this->addrs) - 2;
     // 「選択してください」と会員の住所をカウントしない
     $this->lfInitParam($objFormParam);
     $objPurchase->verifyChangeCart($this->tpl_uniqid, $objCartSess);
     switch ($this->getMode()) {
         case 'confirm':
             $objFormParam->setParam($_POST);
             $this->arrErr = $this->lfCheckError($objFormParam);
             if (SC_Utils_Ex::isBlank($this->arrErr)) {
                 // フォームの情報を一時保存しておく
                 $_SESSION['multiple_temp'] = $objFormParam->getHashArray();
                 $this->saveMultipleShippings($this->tpl_uniqid, $objFormParam, $objCustomer, $objPurchase, $objAddress);
                 $objSiteSess->setRegistFlag();
                 SC_Response_Ex::sendRedirect('payment.php');
                 SC_Response_Ex::actionExit();
             }
             break;
         default:
             $this->setParamToSplitItems($objFormParam, $objCartSess);
     }
     // 前のページから戻ってきた場合
     if ($_GET['from'] == 'multiple') {
         $objFormParam->setParam($_SESSION['multiple_temp']);
     }
     $this->arrForm = $objFormParam->getFormParamList();
 }
예제 #8
0
 /**
  * Page のAction.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objCustomer = new SC_Customer_Ex();
     $objProduct = new SC_Product();
     if (!SC_Utils_Ex::sfIsInt($_GET['order_id'])) {
         SC_Utils_Ex::sfDispSiteError(CUSTOMER_ERROR);
     }
     $order_id = $_GET['order_id'];
     $this->is_price_change = false;
     //受注データの取得
     $this->tpl_arrOrderData = $objPurchase->getOrder($order_id, $objCustomer->getValue('customer_id'));
     if (empty($this->tpl_arrOrderData)) {
         SC_Utils_Ex::sfDispSiteError(CUSTOMER_ERROR);
     }
     $this->arrShipping = $this->lfGetShippingDate($objPurchase, $order_id, $this->arrWDAY);
     $this->isMultiple = count($this->arrShipping) > 1;
     // 支払い方法の取得
     $this->arrPayment = SC_Helper_Payment_Ex::getIDValueList();
     // 受注商品明細の取得
     $this->tpl_arrOrderDetail = $objPurchase->getOrderDetail($order_id);
     foreach ($this->tpl_arrOrderDetail as $product_index => $arrOrderProductDetail) {
         //必要なのは商品の販売金額のみなので、遅い場合は、別途SQL作成した方が良い
         $arrTempProductDetail = $objProduct->getProductsClass($arrOrderProductDetail['product_class_id']);
         // 税計算
         $this->tpl_arrOrderDetail[$product_index]['price_inctax'] = $this->tpl_arrOrderDetail[$product_index]['price'] + SC_Helper_TaxRule_Ex::calcTax($this->tpl_arrOrderDetail[$product_index]['price'], $this->tpl_arrOrderDetail[$product_index]['tax_rate'], $this->tpl_arrOrderDetail[$product_index]['tax_rule']);
         $arrTempProductDetail['price02_inctax'] = SC_Helper_TaxRule_Ex::sfCalcIncTax($arrTempProductDetail['price02'], $arrTempProductDetail['product_id'], $arrTempProductDetail['product_class_id']);
         if ($this->tpl_arrOrderDetail[$product_index]['price_inctax'] != $arrTempProductDetail['price02_inctax']) {
             $this->is_price_change = true;
         }
         $this->tpl_arrOrderDetail[$product_index]['product_price_inctax'] = $arrTempProductDetail['price02_inctax'] ? $arrTempProductDetail['price02_inctax'] : 0;
     }
     $this->tpl_arrOrderDetail = $this->setMainListImage($this->tpl_arrOrderDetail);
     $objPurchase->setDownloadableFlgTo($this->tpl_arrOrderDetail);
     // モバイルダウンロード対応処理
     $this->lfSetAU($this->tpl_arrOrderDetail);
     // 受注メール送信履歴の取得
     $this->tpl_arrMailHistory = $this->lfGetMailHistory($order_id);
 }
 /**
  * Page のアクション.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objCartSess = new SC_CartSession_Ex();
     $objSiteSess = new SC_SiteSession_Ex();
     $objCustomer = new SC_Customer_Ex();
     $this->is_multiple = $objPurchase->isMultiple();
     // 前のページで正しく登録手続きが行われた記録があるか判定
     if (!$objSiteSess->isPrePage()) {
         // エラー時は、正当なページ遷移とは認めない
         $objSiteSess->setNowPage('');
         SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, $objSiteSess);
     }
     // ユーザユニークIDの取得と購入状態の正当性をチェック
     $this->tpl_uniqid = $objSiteSess->getUniqId();
     $objPurchase->verifyChangeCart($this->tpl_uniqid, $objCartSess);
     $this->cartKey = $objCartSess->getKey();
     // カート内商品のチェック
     $this->tpl_message = $objCartSess->checkProducts($this->cartKey);
     if (!SC_Utils_Ex::isBlank($this->tpl_message)) {
         SC_Response_Ex::sendRedirect(CART_URL);
         SC_Response_Ex::actionExit();
     }
     // カートの商品を取得
     $this->arrShipping = $objPurchase->getShippingTemp($this->is_multiple);
     $this->arrCartItems = $objCartSess->getCartList($this->cartKey);
     // 合計金額
     $this->tpl_total_inctax[$this->cartKey] = $objCartSess->getAllProductsTotal($this->cartKey);
     // 税額
     $this->tpl_total_tax[$this->cartKey] = $objCartSess->getAllProductsTax($this->cartKey);
     // ポイント合計
     $this->tpl_total_point[$this->cartKey] = $objCartSess->getAllProductsPoint($this->cartKey);
     // 一時受注テーブルの読込
     $arrOrderTemp = $objPurchase->getOrderTemp($this->tpl_uniqid);
     // カート集計を元に最終計算
     $arrCalcResults = $objCartSess->calculate($this->cartKey, $objCustomer, $arrOrderTemp['use_point'], $objPurchase->getShippingPref($this->is_multiple), $arrOrderTemp['charge'], $arrOrderTemp['discount'], $arrOrderTemp['deliv_id'], $arrOrderTemp['order_pref'], $arrOrderTemp['order_country_id']);
     $this->arrForm = array_merge($arrOrderTemp, $arrCalcResults);
     // 会員ログインチェック
     if ($objCustomer->isLoginSuccess(true)) {
         $this->tpl_login = '******';
         $this->tpl_user_point = $objCustomer->getValue('point');
     }
     // 決済モジュールを使用するかどうか
     $this->use_module = SC_Helper_Payment_Ex::useModule($this->arrForm['payment_id']);
     switch ($this->getMode()) {
         // 前のページに戻る
         case 'return':
             // 正常な推移であることを記録しておく
             $objSiteSess->setRegistFlag();
             SC_Response_Ex::sendRedirect(SHOPPING_PAYMENT_URLPATH);
             SC_Response_Ex::actionExit();
             break;
         case 'confirm':
             /*
              * 決済モジュールで必要なため, 受注番号を取得
              */
             $this->arrForm['order_id'] = $objPurchase->getNextOrderID();
             $_SESSION['order_id'] = $this->arrForm['order_id'];
             // 集計結果を受注一時テーブルに反映
             $objPurchase->saveOrderTemp($this->tpl_uniqid, $this->arrForm, $objCustomer);
             // 正常に登録されたことを記録しておく
             $objSiteSess->setRegistFlag();
             // 決済モジュールを使用する場合
             if ($this->use_module) {
                 $objPurchase->completeOrder(ORDER_PENDING);
                 SC_Response_Ex::sendRedirect(SHOPPING_MODULE_URLPATH);
                 // 購入完了ページ
             } else {
                 $objPurchase->completeOrder(ORDER_NEW);
                 SC_Helper_Purchase_Ex::sendOrderMail($this->arrForm['order_id'], $this);
                 SC_Response_Ex::sendRedirect(SHOPPING_COMPLETE_URLPATH);
             }
             SC_Response_Ex::actionExit();
             break;
         default:
             break;
     }
 }
 /**
  * Page のアクション.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objCartSess = new SC_CartSession_Ex();
     $objSiteSess = new SC_SiteSession_Ex();
     $objCustomer = new SC_Customer_Ex();
     $objFormParam = $this->lfInitParam($_POST);
     $this->mode = $this->getMode();
     // モバイル対応
     if (SC_Display_Ex::detectDevice() == DEVICE_TYPE_MOBILE) {
         if (isset($_GET['cart_no'])) {
             $objFormParam->setValue('cart_no', $_GET['cart_no']);
         }
         if (isset($_GET['cartKey'])) {
             $objFormParam->setValue('cartKey', $_GET['cartKey']);
         }
     }
     $this->cartKeys = $objCartSess->getKeys();
     foreach ($this->cartKeys as $key) {
         // 商品購入中にカート内容が変更された。
         if ($objCartSess->getCancelPurchase($key)) {
             $this->tpl_message .= "商品購入中にカート内容が変更されましたので、お手数ですが購入手続きをやり直して下さい。\n";
         }
     }
     $cart_no = $objFormParam->getValue('cart_no');
     $cartKey = $objFormParam->getValue('cartKey');
     // エラーチェック
     $arrError = $objFormParam->checkError();
     if (isset($arrError) && !empty($arrError)) {
         SC_Utils_Ex::sfDispSiteError(CART_NOT_FOUND);
         SC_Response_Ex::actionExit();
     }
     $objFormParam4OpenCategoryTree = $this->lfInitParam4OpenCategoryTree($_REQUEST);
     if ($objFormParam4OpenCategoryTree->getValue('product_id')) {
         $arrQueryString = array('product_id' => $objFormParam4OpenCategoryTree->getValue('product_id'));
     } else {
         $arrQueryString = array('category_id' => $objFormParam4OpenCategoryTree->getValue('category_id'));
     }
     switch ($this->mode) {
         case 'confirm':
             // カート内情報の取得
             $cartList = $objCartSess->getCartList($cartKey);
             // カート商品が1件以上存在する場合
             if (count($cartList) > 0) {
                 // カートを購入モードに設定
                 $this->lfSetCurrentCart($objSiteSess, $objCartSess, $cartKey);
                 // 購入ページへ
                 SC_Response_Ex::sendRedirect(SHOPPING_URL);
                 SC_Response_Ex::actionExit();
             }
             break;
         case 'up':
             //1個追加
             $objCartSess->upQuantity($cart_no, $cartKey);
             SC_Response_Ex::reload($arrQueryString, true);
             SC_Response_Ex::actionExit();
             break;
         case 'down':
             //1個減らす
             $objCartSess->downQuantity($cart_no, $cartKey);
             SC_Response_Ex::reload($arrQueryString, true);
             SC_Response_Ex::actionExit();
             break;
         case 'setQuantity':
             //数量変更
             $objCartSess->setQuantity($objFormParam->getValue('quantity'), $cart_no, $cartKey);
             SC_Response_Ex::reload($arrQueryString, true);
             SC_Response_Ex::actionExit();
             break;
         case 'delete':
             //カートから削除
             $objCartSess->delProduct($cart_no, $cartKey);
             SC_Response_Ex::reload($arrQueryString, true);
             SC_Response_Ex::actionExit();
             break;
         default:
             break;
     }
     $this->arrInfo = SC_Helper_DB_Ex::sfGetBasisData();
     $totalIncTax = 0;
     foreach ($this->cartKeys as $key) {
         // カート集計処理
         $this->tpl_message .= $objCartSess->checkProducts($key);
         $this->tpl_total_inctax[$key] = $objCartSess->getAllProductsTotal($key);
         $totalIncTax += $this->tpl_total_inctax[$key];
         $this->tpl_total_tax[$key] = $objCartSess->getAllProductsTax($key);
         // ポイント合計
         $this->tpl_total_point[$key] = $objCartSess->getAllProductsPoint($key);
         $this->arrData[$key] = $objCartSess->calculate($key, $objCustomer);
         // 送料無料チェック
         $this->arrData[$key]['is_deliv_free'] = $objCartSess->isDelivFree($key);
         // 送料無料までの金額を計算
         $this->tpl_deliv_free[$key] = $this->arrInfo['free_rule'] - $this->tpl_total_inctax[$key];
     }
     //商品の合計金額をセット
     $this->tpl_all_total_inctax = $totalIncTax;
     $this->tpl_category_id = $objFormParam4OpenCategoryTree->getValue('category_id');
     $this->tpl_product_id = $objFormParam4OpenCategoryTree->getValue('product_id');
     // ログイン判定
     if ($objCustomer->isLoginSuccess(true)) {
         $this->tpl_login = true;
         $this->tpl_user_point = $objCustomer->getValue('point');
         $this->tpl_name = $objCustomer->getValue('name01');
     }
     // 前頁のURLを取得
     // TODO: SC_CartSession::setPrevURL()利用不可。
     $this->lfGetCartPrevUrl($_SESSION, $_SERVER['HTTP_REFERER']);
     $this->tpl_prev_url = isset($_SESSION['cart_prev_url']) ? $_SESSION['cart_prev_url'] : '';
     // 全てのカートの内容を取得する
     $this->cartItems = $objCartSess->getAllCartList();
 }
 /**
  * Page のAction.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     // 会員クラス
     $objCustomer = new SC_Customer_Ex();
     // パラメーター管理クラス
     $this->objFormParam = new SC_FormParam_Ex();
     // パラメーター情報の初期化
     $this->arrForm = $this->lfInitParam($this->objFormParam);
     // ファイル管理クラス
     $this->objUpFile = new SC_UploadFile_Ex(IMAGE_TEMP_REALDIR, IMAGE_SAVE_REALDIR);
     // ファイル情報の初期化
     $this->objUpFile = $this->lfInitFile($this->objUpFile);
     // プロダクトIDの正当性チェック
     $product_id = $this->lfCheckProductId($this->objFormParam->getValue('admin'), $this->objFormParam->getValue('product_id'));
     $this->mode = $this->getMode();
     $objProduct = new SC_Product_Ex();
     $objProduct->setProductsClassByProductIds(array($product_id));
     // 規格1クラス名
     $this->tpl_class_name1 = $objProduct->className1[$product_id];
     // 規格2クラス名
     $this->tpl_class_name2 = $objProduct->className2[$product_id];
     // 規格1
     $this->arrClassCat1 = $objProduct->classCats1[$product_id];
     // 規格1が設定されている
     $this->tpl_classcat_find1 = $objProduct->classCat1_find[$product_id];
     // 規格2が設定されている
     $this->tpl_classcat_find2 = $objProduct->classCat2_find[$product_id];
     $this->tpl_stock_find = $objProduct->stock_find[$product_id];
     $this->tpl_product_class_id = $objProduct->classCategories[$product_id]['__unselected']['__unselected']['product_class_id'];
     $this->tpl_product_type = $objProduct->classCategories[$product_id]['__unselected']['__unselected']['product_type'];
     // 在庫が無い場合は、OnLoadしない。(javascriptエラー防止)
     if ($this->tpl_stock_find) {
         // 規格選択セレクトボックスの作成
         $this->js_lnOnload .= $this->lfMakeSelect();
     }
     $this->tpl_javascript .= 'eccube.classCategories = ' . SC_Utils_Ex::jsonEncode($objProduct->classCategories[$product_id]) . ';';
     $this->tpl_javascript .= 'function lnOnLoad()
     {' . $this->js_lnOnload . '}';
     $this->tpl_onload .= 'lnOnLoad();';
     // モバイル用 規格選択セレクトボックスの作成
     if (SC_Display_Ex::detectDevice() == DEVICE_TYPE_MOBILE) {
         $this->lfMakeSelectMobile($this, $product_id, $this->objFormParam->getValue('classcategory_id1'));
     }
     // 商品IDをFORM内に保持する
     $this->tpl_product_id = $product_id;
     switch ($this->mode) {
         case 'cart':
             $this->doCart();
             break;
         case 'add_favorite':
             $this->doAddFavorite($objCustomer);
             break;
         case 'add_favorite_sphone':
             $this->doAddFavoriteSphone($objCustomer);
             break;
         case 'select':
         case 'select2':
         case 'selectItem':
             /**
              * モバイルの数量指定・規格選択の際に、
              * $_SESSION['cart_referer_url'] を上書きさせないために、
              * 何もせずbreakする。
              */
             break;
         default:
             $this->doDefault();
             break;
     }
     // モバイル用 ポストバック処理
     if (SC_Display_Ex::detectDevice() == DEVICE_TYPE_MOBILE) {
         switch ($this->mode) {
             case 'select':
                 $this->doMobileSelect();
                 break;
             case 'select2':
                 $this->doMobileSelect2();
                 break;
             case 'selectItem':
                 $this->doMobileSelectItem();
                 break;
             case 'cart':
                 $this->doMobileCart();
                 break;
             default:
                 $this->doMobileDefault();
                 break;
         }
     }
     // 商品詳細を取得
     $this->arrProduct = $objProduct->getDetail($product_id);
     // サブタイトルを取得
     $this->tpl_subtitle = $this->arrProduct['name'];
     // 関連カテゴリを取得
     $this->arrRelativeCat = SC_Helper_DB_Ex::sfGetMultiCatTree($product_id);
     // 商品ステータスを取得
     $this->productStatus = $objProduct->getProductStatus($product_id);
     // 画像ファイル指定がない場合の置換処理
     $this->arrProduct['main_image'] = SC_Utils_Ex::sfNoImageMain($this->arrProduct['main_image']);
     $this->subImageFlag = $this->lfSetFile($this->objUpFile, $this->arrProduct, $this->arrFile);
     //レビュー情報の取得
     $this->arrReview = $this->lfGetReviewData($product_id);
     //関連商品情報表示
     $this->arrRecommend = $this->lfPreGetRecommendProducts($product_id);
     // ログイン判定
     if ($objCustomer->isLoginSuccess() === true) {
         //お気に入りボタン表示
         $this->tpl_login = true;
         $this->is_favorite = SC_Helper_DB_Ex::sfDataExists('dtb_customer_favorite_products', 'customer_id = ? AND product_id = ?', array($objCustomer->getValue('customer_id'), $product_id));
     }
 }
예제 #12
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objSiteSess = new SC_SiteSession_Ex();
     $objCartSess = new SC_CartSession_Ex();
     $objCustomer = new SC_Customer_Ex();
     $objFormParam = new SC_FormParam_Ex();
     $objAddress = new SC_Helper_Address_Ex();
     $this->tpl_uniqid = $objSiteSess->getUniqId();
     $objPurchase->verifyChangeCart($this->tpl_uniqid, $objCartSess);
     $this->cartKey = $objCartSess->getKey();
     // ログインチェック
     if (!$objCustomer->isLoginSuccess(true)) {
         SC_Utils_Ex::sfDispSiteError(CUSTOMER_ERROR);
     }
     // ダウンロード商品の場合は、支払方法画面に転送
     if ($this->cartKey == PRODUCT_TYPE_DOWNLOAD) {
         $objPurchase->copyFromCustomer($sqlval, $objCustomer, 'shipping');
         $objPurchase->saveShippingTemp($sqlval);
         $objPurchase->saveOrderTemp($this->tpl_uniqid, $sqlval, $objCustomer);
         $objSiteSess->setRegistFlag();
         SC_Response_Ex::sendRedirect('payment.php');
         SC_Response_Ex::actionExit();
     }
     $this->lfInitParam($objFormParam);
     $objFormParam->setParam($_POST);
     $objFormParam->convParam();
     $arrErr = $objFormParam->checkError();
     if (!SC_Utils_Ex::isBlank($arrErr)) {
         SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, '', true);
         SC_Response_Ex::actionExit();
     }
     $arrForm = $objFormParam->getHashArray();
     switch ($this->getMode()) {
         // 削除
         case 'delete':
             if (!$objAddress->deleteAddress($arrForm['other_deliv_id'], $objCustomer->getValue('customer_id'))) {
                 SC_Utils_Ex::sfDispSiteError(FREE_ERROR_MSG, '', false, '別のお届け先を削除できませんでした。');
                 SC_Response_Ex::actionExit();
             }
             break;
             // 会員登録住所に送る
         // 会員登録住所に送る
         case 'customer_addr':
             $objPurchase->unsetShippingTemp();
             $shipping_id = $arrForm['deliv_check'] == -1 ? 0 : $arrForm['deliv_check'];
             $success = $this->registerDeliv($shipping_id, $this->tpl_uniqid, $objPurchase, $objCustomer, $objAddress);
             if (!$success) {
                 SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, '', true);
             }
             $objPurchase->setShipmentItemTempForSole($objCartSess, $shipping_id);
             $objSiteSess->setRegistFlag();
             SC_Response_Ex::sendRedirect(SHOPPING_PAYMENT_URLPATH);
             SC_Response_Ex::actionExit();
             break;
             // 前のページに戻る
         // 前のページに戻る
         case 'return':
             // 確認ページへ移動
             SC_Response_Ex::sendRedirect(CART_URL);
             SC_Response_Ex::actionExit();
             break;
             // お届け先複数指定
         // お届け先複数指定
         case 'multiple':
             // 複数配送先指定が無効な場合はエラー
             if (USE_MULTIPLE_SHIPPING === false) {
                 SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, '', true);
                 SC_Response_Ex::actionExit();
             }
             SC_Response_Ex::sendRedirect('multiple.php');
             SC_Response_Ex::actionExit();
             break;
         default:
             // 配送IDの取得
             $shippingData = $objPurchase->getShippingTemp();
             if (!SC_Utils_Ex::isBlank($shippingData)) {
                 $arrShippingId = array_keys($shippingData);
             }
             if (isset($arrShippingId[0])) {
                 $this->arrForm['deliv_check']['value'] = $arrShippingId[0] == 0 ? -1 : $arrShippingId[0];
             }
             break;
     }
     // 登録済み住所を取得
     $addr = array(array('other_deliv_id' => NULL, 'customer_id' => $objCustomer->getValue('customer_id'), 'name01' => $objCustomer->getValue('name01'), 'name02' => $objCustomer->getValue('name02'), 'kana01' => $objCustomer->getValue('kana01'), 'kana02' => $objCustomer->getValue('kana02'), 'company_name' => $objCustomer->getValue('company_name'), 'country_id' => $objCustomer->getValue('country_id'), 'zipcode' => $objCustomer->getValue('zipcode'), 'zip01' => $objCustomer->getValue('zip01'), 'zip02' => $objCustomer->getValue('zip02'), 'pref' => $objCustomer->getValue('pref'), 'addr01' => $objCustomer->getValue('addr01'), 'addr02' => $objCustomer->getValue('addr02'), 'tel01' => $objCustomer->getValue('tel01'), 'tel02' => $objCustomer->getValue('tel02'), 'tel03' => $objCustomer->getValue('tel03')));
     $this->arrAddr = array_merge($addr, $objAddress->getList($objCustomer->getValue('customer_id')));
     $this->tpl_addrmax = count($this->arrAddr) - 1;
     // 会員の住所をカウントしない
 }
 /**
  * Page のプロセス
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objFormParam = new SC_FormParam_Ex();
     // PC時は規約ページからの遷移でなければエラー画面へ遷移する
     if ($this->lfCheckReferer() === false) {
         SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, '', true);
     }
     SC_Helper_Customer_Ex::sfCustomerEntryParam($objFormParam);
     $objFormParam->setParam($_POST);
     // mobile用(戻るボタンでの遷移かどうかを判定)
     if (!empty($_POST['return'])) {
         $_REQUEST['mode'] = 'return';
     }
     switch ($this->getMode()) {
         case 'confirm':
             if (isset($_POST['submit_address'])) {
                 // 入力エラーチェック
                 $this->arrErr = $this->lfCheckError($_POST);
                 // 入力エラーの場合は終了
                 if (count($this->arrErr) == 0) {
                     // 郵便番号検索文作成
                     $zipcode = $_POST['zip01'] . $_POST['zip02'];
                     // 郵便番号検索
                     $arrAdsList = SC_Utils_Ex::sfGetAddress($zipcode);
                     // 郵便番号が発見された場合
                     if (!empty($arrAdsList)) {
                         $data['pref'] = $arrAdsList[0]['state'];
                         $data['addr01'] = $arrAdsList[0]['city'] . $arrAdsList[0]['town'];
                         $objFormParam->setParam($data);
                         // 該当無し
                     } else {
                         $this->arrErr['zip01'] = '※該当する住所が見つかりませんでした。<br>';
                     }
                 }
                 break;
             }
             //-- 確認
             $this->arrErr = SC_Helper_Customer_Ex::sfCustomerEntryErrorCheck($objFormParam);
             // 入力エラーなし
             if (empty($this->arrErr)) {
                 //パスワード表示
                 $this->passlen = SC_Utils_Ex::sfPassLen(strlen($objFormParam->getValue('password')));
                 $this->tpl_mainpage = 'entry/confirm.tpl';
                 $this->tpl_title = '会員登録(確認ページ)';
             }
             break;
         case 'complete':
             //-- 会員登録と完了画面
             $this->arrErr = SC_Helper_Customer_Ex::sfCustomerEntryErrorCheck($objFormParam);
             if (empty($this->arrErr)) {
                 $uniqid = $this->lfRegistCustomerData($this->lfMakeSqlVal($objFormParam));
                 $this->lfSendMail($uniqid, $objFormParam->getHashArray());
                 // 仮会員が無効の場合
                 if (CUSTOMER_CONFIRM_MAIL == false) {
                     // ログイン状態にする
                     $objCustomer = new SC_Customer_Ex();
                     $objCustomer->setLogin($objFormParam->getValue('email'));
                 }
                 // 完了ページに移動させる。
                 SC_Response_Ex::sendRedirect('complete.php', array('ci' => SC_Helper_Customer_Ex::sfGetCustomerId($uniqid)));
             }
             break;
         case 'return':
             // quiet.
             break;
         default:
             break;
     }
     $this->arrForm = $objFormParam->getFormParamList();
 }
예제 #14
0
 /**
  * Page のアクション.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objSiteSess = new SC_SiteSession_Ex();
     $objCartSess = new SC_CartSession_Ex();
     $objCustomer = new SC_Customer_Ex();
     $objFormParam = new SC_FormParam_Ex();
     $objDelivery = new SC_Helper_Delivery_Ex();
     $this->is_multiple = $objPurchase->isMultiple();
     // カートの情報を取得
     $this->arrShipping = $objPurchase->getShippingTemp($this->is_multiple);
     $this->tpl_uniqid = $objSiteSess->getUniqId();
     $cart_key = $objCartSess->getKey();
     $this->cartKey = $cart_key;
     $objPurchase->verifyChangeCart($this->tpl_uniqid, $objCartSess);
     // 配送業者を取得
     $this->arrDeliv = $objDelivery->getList($cart_key);
     $this->is_single_deliv = $this->isSingleDeliv($this->arrDeliv);
     $this->is_download = $this->cartKey == PRODUCT_TYPE_DOWNLOAD;
     // 会員情報の取得
     if ($objCustomer->isLoginSuccess(true)) {
         $this->tpl_login = '******';
         $this->tpl_user_point = $objCustomer->getValue('point');
         $this->name01 = $objCustomer->getValue('name01');
         $this->name02 = $objCustomer->getValue('name02');
     }
     // 戻り URL の設定
     // @deprecated 2.12.0 テンプレート直書きに戻した
     $this->tpl_back_url = '?mode=return';
     $arrOrderTemp = $objPurchase->getOrderTemp($this->tpl_uniqid);
     // 正常に受注情報が格納されていない場合はカート画面へ戻す
     if (SC_Utils_Ex::isBlank($arrOrderTemp)) {
         SC_Response_Ex::sendRedirect(CART_URL);
         SC_Response_Ex::actionExit();
     }
     // カート内商品の妥当性チェック
     $this->tpl_message = $objCartSess->checkProducts($cart_key);
     if (strlen($this->tpl_message) >= 1) {
         SC_Response_Ex::sendRedirect(CART_URL);
         SC_Response_Ex::actionExit();
     }
     /*
      * 購入金額の取得
      * ここでは送料を加算しない
      */
     $this->arrPrices = $objCartSess->calculate($cart_key, $objCustomer);
     // お届け日一覧の取得
     $this->arrDelivDate = $objPurchase->getDelivDate($objCartSess, $cart_key);
     switch ($this->getMode()) {
         /*
          * 配送業者選択時のアクション
          * モバイル端末以外の場合は, JSON 形式のデータを出力し, ajax で取得する.
          */
         case 'select_deliv':
             $this->setFormParams($objFormParam, $arrOrderTemp, true, $this->arrShipping);
             $objFormParam->setParam($_POST);
             $this->arrErr = $objFormParam->checkError();
             if (SC_Utils_Ex::isBlank($this->arrErr)) {
                 $deliv_id = $objFormParam->getValue('deliv_id');
                 $arrSelectedDeliv = $this->getSelectedDeliv($objCartSess, $deliv_id);
                 $arrSelectedDeliv['error'] = false;
             } else {
                 $arrSelectedDeliv = array('error' => true);
                 $this->tpl_mainpage = 'shopping/select_deliv.tpl';
                 // モバイル用
             }
             if (SC_Display_Ex::detectDevice() != DEVICE_TYPE_MOBILE) {
                 echo SC_Utils_Ex::jsonEncode($arrSelectedDeliv);
                 SC_Response_Ex::actionExit();
             } else {
                 $this->arrPayment = $arrSelectedDeliv['arrPayment'];
                 $this->arrDelivTime = $arrSelectedDeliv['arrDelivTime'];
             }
             break;
             // 登録処理
         // 登録処理
         case 'confirm':
             // パラメーター情報の初期化
             $this->setFormParams($objFormParam, $_POST, $this->is_download, $this->arrShipping);
             $this->arrErr = $this->lfCheckError($objFormParam, $this->arrPrices['subtotal'], $this->tpl_user_point);
             $deliv_id = $objFormParam->getValue('deliv_id');
             if (strval($deliv_id) !== strval(intval($deliv_id))) {
                 $deliv_id = $this->arrDeliv[0]['deliv_id'];
                 $objFormParam->setValue('deliv_id', $deliv_id);
             }
             $arrSelectedDeliv = $this->getSelectedDeliv($objCartSess, $deliv_id);
             $this->arrPayment = $arrSelectedDeliv['arrPayment'];
             $this->arrDelivTime = $arrSelectedDeliv['arrDelivTime'];
             $this->img_show = $arrSelectedDeliv['img_show'];
             if (empty($this->arrErr)) {
                 $this->saveShippings($objFormParam, $this->arrDelivTime);
                 $this->lfRegistData($this->tpl_uniqid, $objFormParam->getDbArray(), $objPurchase, $this->arrPayment);
                 // 正常に登録されたことを記録しておく
                 $objSiteSess->setRegistFlag();
                 // 確認ページへ移動
                 SC_Response_Ex::sendRedirect(SHOPPING_CONFIRM_URLPATH);
                 SC_Response_Ex::actionExit();
             }
             break;
             // 前のページに戻る
         // 前のページに戻る
         case 'return':
             // 正常な推移であることを記録しておく
             $objSiteSess->setRegistFlag();
             $url = null;
             if ($this->is_multiple) {
                 $url = MULTIPLE_URLPATH . '?from=multiple';
             } elseif ($objCustomer->isLoginSuccess(true)) {
                 if ($this->cartKey == PRODUCT_TYPE_DOWNLOAD) {
                     $url = CART_URL;
                 } else {
                     $url = DELIV_URLPATH;
                 }
             } else {
                 $url = SHOPPING_URL . '?from=nonmember';
             }
             SC_Response_Ex::sendRedirect($url);
             SC_Response_Ex::actionExit();
             break;
         default:
             // FIXME 前のページから戻ってきた場合は別パラメーター(mode)で処理分岐する必要があるのかもしれない
             $this->setFormParams($objFormParam, $arrOrderTemp, $this->is_download, $this->arrShipping);
             if (!$this->is_single_deliv) {
                 $deliv_id = $objFormParam->getValue('deliv_id');
             } else {
                 $deliv_id = $this->arrDeliv[0]['deliv_id'];
             }
             if (!SC_Utils_Ex::isBlank($deliv_id)) {
                 $objFormParam->setValue('deliv_id', $deliv_id);
                 $arrSelectedDeliv = $this->getSelectedDeliv($objCartSess, $deliv_id);
                 $this->arrPayment = $arrSelectedDeliv['arrPayment'];
                 $this->arrDelivTime = $arrSelectedDeliv['arrDelivTime'];
                 $this->img_show = $arrSelectedDeliv['img_show'];
             }
             break;
     }
     // モバイル用 ポストバック処理
     if (SC_Display_Ex::detectDevice() == DEVICE_TYPE_MOBILE && SC_Utils_Ex::isBlank($this->arrErr)) {
         $this->tpl_mainpage = $this->getMobileMainpage($this->is_single_deliv, $this->getMode());
     }
     $this->arrForm = $objFormParam->getFormParamList();
 }
 /**
  * Page のアクション.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     // 会員管理クラス
     $objCustomer = new SC_Customer_Ex();
     // クッキー管理クラス
     $objCookie = new SC_Cookie_Ex();
     // パラメーター管理クラス
     $objFormParam = new SC_FormParam_Ex();
     // パラメーター情報の初期化
     $this->lfInitParam($objFormParam);
     // リクエスト値をフォームにセット
     $objFormParam->setParam($_POST);
     $url = htmlspecialchars($_POST['url'], ENT_QUOTES);
     // モードによって分岐
     switch ($this->getMode()) {
         case 'login':
             // 入力値のエラーチェック
             $objFormParam->trimParam();
             $objFormParam->toLower('login_email');
             $arrErr = $objFormParam->checkError();
             // エラーの場合はエラー画面に遷移
             if (count($arrErr) > 0) {
                 if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                     echo $this->lfGetErrorMessage(TEMP_LOGIN_ERROR);
                     SC_Response_Ex::actionExit();
                 } else {
                     SC_Utils_Ex::sfDispSiteError(TEMP_LOGIN_ERROR);
                     SC_Response_Ex::actionExit();
                 }
             }
             // 入力チェック後の値を取得
             $arrForm = $objFormParam->getHashArray();
             // クッキー保存判定
             if ($arrForm['login_memory'] == '1' && $arrForm['login_email'] != '') {
                 $objCookie->setCookie('login_email', $arrForm['login_email']);
             } else {
                 $objCookie->setCookie('login_email', '');
             }
             // 遷移先の制御
             if (count($arrErr) == 0) {
                 // ログイン処理
                 if ($objCustomer->doLogin($arrForm['login_email'], $arrForm['login_pass'])) {
                     if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_MOBILE) {
                         // ログインが成功した場合は携帯端末IDを保存する。
                         $objCustomer->updateMobilePhoneId();
                         /*
                          * email がモバイルドメインでは無く,
                          * 携帯メールアドレスが登録されていない場合
                          */
                         $objMobile = new SC_Helper_Mobile_Ex();
                         if (!$objMobile->gfIsMobileMailAddress($objCustomer->getValue('email'))) {
                             if (!$objCustomer->hasValue('email_mobile')) {
                                 SC_Response_Ex::sendRedirectFromUrlPath('entry/email_mobile.php');
                                 SC_Response_Ex::actionExit();
                             }
                         }
                     }
                     // --- ログインに成功した場合
                     if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                         echo SC_Utils_Ex::jsonEncode(array('success' => $url));
                     } else {
                         SC_Response_Ex::sendRedirect($url);
                     }
                     SC_Response_Ex::actionExit();
                 } else {
                     // --- ログインに失敗した場合
                     // ブルートフォースアタック対策
                     // ログイン失敗時に遅延させる
                     sleep(LOGIN_RETRY_INTERVAL);
                     $arrForm['login_email'] = strtolower($arrForm['login_email']);
                     $objQuery = SC_Query_Ex::getSingletonInstance();
                     $where = '(email = ? OR email_mobile = ?) AND status = 1 AND del_flg = 0';
                     $exists = $objQuery->exists('dtb_customer', $where, array($arrForm['login_email'], $arrForm['login_email']));
                     // ログインエラー表示 TODO リファクタリング
                     if ($exists) {
                         if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                             echo $this->lfGetErrorMessage(TEMP_LOGIN_ERROR);
                             SC_Response_Ex::actionExit();
                         } else {
                             SC_Utils_Ex::sfDispSiteError(TEMP_LOGIN_ERROR);
                             SC_Response_Ex::actionExit();
                         }
                     } else {
                         if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                             echo $this->lfGetErrorMessage(SITE_LOGIN_ERROR);
                             SC_Response_Ex::actionExit();
                         } else {
                             SC_Utils_Ex::sfDispSiteError(SITE_LOGIN_ERROR);
                             SC_Response_Ex::actionExit();
                         }
                     }
                 }
             } else {
                 // XXX 到達しない?
                 // 入力エラーの場合、元のアドレスに戻す。
                 SC_Response_Ex::sendRedirect($url);
                 SC_Response_Ex::actionExit();
             }
             break;
         case 'logout':
             // --- ログアウト
             // ログイン情報の解放
             $objCustomer->EndSession();
             // 画面遷移の制御
             $mypage_url_search = strpos('.' . $url, 'mypage');
             if ($mypage_url_search == 2) {
                 // マイページログイン中はログイン画面へ移行
                 SC_Response_Ex::sendRedirectFromUrlPath('mypage/login.php');
             } else {
                 // 上記以外の場合、トップへ遷移
                 SC_Response_Ex::sendRedirect(TOP_URL);
             }
             SC_Response_Ex::actionExit();
             break;
         default:
             break;
     }
 }
예제 #16
0
 /**
  * Page のプロセス.
  *
  * @return void
  */
 public function action()
 {
     //決済処理中ステータスのロールバック
     $objPurchase = new SC_Helper_Purchase_Ex();
     $objPurchase->cancelPendingOrder(PENDING_ORDER_CANCEL_FLAG);
     $objSiteSess = new SC_SiteSession_Ex();
     $objCartSess = new SC_CartSession_Ex();
     $objCustomer = new SC_Customer_Ex();
     $objCookie = new SC_Cookie_Ex();
     $objFormParam = new SC_FormParam_Ex();
     $nonmember_mainpage = 'shopping/nonmember_input.tpl';
     $nonmember_title = 'お客様情報入力';
     $this->tpl_uniqid = $objSiteSess->getUniqId();
     $objPurchase->verifyChangeCart($this->tpl_uniqid, $objCartSess);
     $this->cartKey = $objCartSess->getKey();
     // ログイン済みの場合は次画面に遷移
     if ($objCustomer->isLoginSuccess(true)) {
         SC_Response_Ex::sendRedirect($this->getNextlocation($this->cartKey, $this->tpl_uniqid, $objCustomer, $objPurchase, $objSiteSess));
         SC_Response_Ex::actionExit();
         // 非会員かつ, ダウンロード商品の場合はエラー表示
     } else {
         if ($this->cartKey == PRODUCT_TYPE_DOWNLOAD) {
             $msg = 'ダウンロード商品を含むお買い物は、会員登録が必要です。<br/>' . 'お手数ですが、会員登録をお願いします。';
             SC_Utils_Ex::sfDispSiteError(FREE_ERROR_MSG, $objSiteSess, false, $msg);
             SC_Response_Ex::actionExit();
         }
     }
     // 携帯端末IDが一致する会員が存在するかどうかをチェックする。
     if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_MOBILE) {
         $this->tpl_valid_phone_id = $objCustomer->checkMobilePhoneId();
     }
     switch ($this->getMode()) {
         // ログイン実行
         case 'login':
             $this->lfInitLoginFormParam($objFormParam);
             $objFormParam->setParam($_POST);
             $objFormParam->trimParam();
             $objFormParam->convParam();
             $objFormParam->toLower('login_email');
             $this->arrErr = $objFormParam->checkError();
             // ログイン判定
             if (SC_Utils_Ex::isBlank($this->arrErr) && $objCustomer->doLogin($objFormParam->getValue('login_email'), $objFormParam->getValue('login_pass'))) {
                 // クッキー保存判定
                 if ($objFormParam->getValue('login_memory') == '1' && strlen($objFormParam->getValue('login_email')) >= 1) {
                     $objCookie->setCookie('login_email', $objFormParam->getValue('login_email'));
                 } else {
                     $objCookie->setCookie('login_email', '');
                 }
                 // モバイルサイトで携帯アドレスの登録が無い場合、携帯アドレス登録ページへ遷移
                 if (SC_Display_Ex::detectDevice() == DEVICE_TYPE_MOBILE) {
                     if (!$objCustomer->hasValue('email_mobile')) {
                         SC_Response_Ex::sendRedirectFromUrlPath('entry/email_mobile.php');
                         SC_Response_Ex::actionExit();
                     }
                     // スマートフォンの場合はログイン成功を返す
                 } elseif (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                     echo SC_Utils_Ex::jsonEncode(array('success' => $this->getNextLocation($this->cartKey, $this->tpl_uniqid, $objCustomer, $objPurchase, $objSiteSess)));
                     SC_Response_Ex::actionExit();
                 }
                 SC_Response_Ex::sendRedirect($this->getNextLocation($this->cartKey, $this->tpl_uniqid, $objCustomer, $objPurchase, $objSiteSess));
                 SC_Response_Ex::actionExit();
                 // ログインに失敗した場合
             } else {
                 // 仮登録の場合
                 if (SC_Helper_Customer_Ex::checkTempCustomer($objFormParam->getValue('login_email'))) {
                     if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                         echo $this->lfGetErrorMessage(TEMP_LOGIN_ERROR);
                         SC_Response_Ex::actionExit();
                     } else {
                         SC_Utils_Ex::sfDispSiteError(TEMP_LOGIN_ERROR);
                         SC_Response_Ex::actionExit();
                     }
                 } else {
                     if (SC_Display_Ex::detectDevice() === DEVICE_TYPE_SMARTPHONE) {
                         echo $this->lfGetErrorMessage(SITE_LOGIN_ERROR);
                         SC_Response_Ex::actionExit();
                     } else {
                         SC_Utils_Ex::sfDispSiteError(SITE_LOGIN_ERROR);
                         SC_Response_Ex::actionExit();
                     }
                 }
             }
             break;
             // お客様情報登録
         // お客様情報登録
         case 'nonmember_confirm':
             $this->tpl_mainpage = $nonmember_mainpage;
             $this->tpl_title = $nonmember_title;
             $this->lfInitParam($objFormParam);
             $objFormParam->setParam($_POST);
             $this->arrErr = $this->lfCheckError($objFormParam);
             if (SC_Utils_Ex::isBlank($this->arrErr)) {
                 $this->lfRegistData($this->tpl_uniqid, $objPurchase, $objCustomer, $objFormParam);
                 $arrParams = $objFormParam->getHashArray();
                 $shipping_id = $arrParams['deliv_check'] == '1' ? 1 : 0;
                 $objPurchase->setShipmentItemTempForSole($objCartSess, $shipping_id);
                 $objSiteSess->setRegistFlag();
                 SC_Response_Ex::sendRedirect(SHOPPING_PAYMENT_URLPATH);
                 SC_Response_Ex::actionExit();
             }
             break;
             // 前のページに戻る
         // 前のページに戻る
         case 'return':
             SC_Response_Ex::sendRedirect(CART_URL);
             SC_Response_Ex::actionExit();
             break;
             // 複数配送ページへ遷移
         // 複数配送ページへ遷移
         case 'multiple':
             // 複数配送先指定が無効な場合はエラー
             if (USE_MULTIPLE_SHIPPING === false) {
                 SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, '', true);
                 SC_Response_Ex::actionExit();
             }
             $this->lfInitParam($objFormParam);
             $objFormParam->setParam($_POST);
             $this->arrErr = $this->lfCheckError($objFormParam);
             if (SC_Utils_Ex::isBlank($this->arrErr)) {
                 $this->lfRegistData($this->tpl_uniqid, $objPurchase, $objCustomer, $objFormParam, true);
                 $objSiteSess->setRegistFlag();
                 SC_Response_Ex::sendRedirect(MULTIPLE_URLPATH);
                 SC_Response_Ex::actionExit();
             }
             $this->tpl_mainpage = $nonmember_mainpage;
             $this->tpl_title = $nonmember_title;
             break;
             // お客様情報入力ページの表示
         // お客様情報入力ページの表示
         case 'nonmember':
             $this->tpl_mainpage = $nonmember_mainpage;
             $this->tpl_title = $nonmember_title;
             $this->lfInitParam($objFormParam);
             // ※breakなし
         // ※breakなし
         default:
             // 前のページから戻ってきた場合は, お客様情報入力ページ
             if (isset($_GET['from']) && $_GET['from'] == 'nonmember') {
                 $this->tpl_mainpage = $nonmember_mainpage;
                 $this->tpl_title = $nonmember_title;
                 $this->lfInitParam($objFormParam);
             } else {
                 // 通常はログインページ
                 $this->lfInitLoginFormParam($objFormParam);
             }
             $this->setFormParams($objFormParam, $objPurchase, $this->tpl_uniqid);
             break;
     }
     // 入力値の取得
     $this->arrForm = $objFormParam->getFormParamList();
     // 記憶したメールアドレスを取得
     $this->tpl_login_email = $objCookie->getCookie('login_email');
     if (!SC_Utils_Ex::isBlank($this->tpl_login_email)) {
         $this->tpl_login_memory = '1';
     }
 }