public function EndSession() { // セッション情報破棄の前にcustomer_idを保存 $customer_id = $_SESSION['customer']['customer_id']; // $_SESSION['customer']の解放 unset($_SESSION['customer']); // セッションの配送情報を全て破棄する PurchaseHelper::unsetAllShippingTemp(true); // トランザクショントークンの破棄 SessionHelper::destroyToken(); /* @var $objSiteSess SiteSession */ $objSiteSess = Application::alias('eccube.site_session'); $objSiteSess->unsetUniqId(); // ログに記録する $log = sprintf("logout : user=%d\tip=%s", $customer_id, $this->getRemoteHost()); GcUtils::gfPrintLog($log, CUSTOMER_LOG_REALFILE, false); }
/** * データの一時登録を行う. * * 非会員向けの処理 * @param integer $uniqid 受注一時テーブルのユニークID * @param PurchaseHelper $objPurchase PurchaseHelper インスタンス * @param Customer $objCustomer Customer インスタンス * @param FormParam $objFormParam FormParam インスタンス * @param boolean $isMultiple 複数配送の場合 true */ public function lfRegistData($uniqid, &$objPurchase, Customer &$objCustomer, &$objFormParam, $isMultiple = false) { $arrParams = $objFormParam->getHashArray(); // 注文者をお届け先とする配列を取得 $arrShippingOwn = array(); $objPurchase->copyFromOrder($arrShippingOwn, $arrParams); // 都度入力されたお届け先 $arrShipping = $objPurchase->extractShipping($arrParams); if ($isMultiple) { $objPurchase->unsetOneShippingTemp(0); $objPurchase->unsetOneShippingTemp(1); $objPurchase->saveShippingTemp($arrShippingOwn, 0); if ($arrParams['deliv_check'] == '1') { $objPurchase->saveShippingTemp($arrShipping, 1); } } else { $objPurchase->unsetAllShippingTemp(true); if ($arrParams['deliv_check'] == '1') { $objPurchase->saveShippingTemp($arrShipping, 1); } else { $objPurchase->saveShippingTemp($arrShippingOwn, 0); } } $arrValues = $objFormParam->getDbArray(); // 登録データの作成 $arrValues['order_birth'] = Utils::sfGetTimestamp($arrParams['order_year'], $arrParams['order_month'], $arrParams['order_day']); $arrValues['update_date'] = 'CURRENT_TIMESTAMP'; $arrValues['customer_id'] = '0'; $objPurchase->saveOrderTemp($uniqid, $arrValues, $objCustomer); }
/** * セッションの配送情報を破棄する. * * @deprecated 2.12.0 から EC-CUBE 本体では使用していない。 * @return void */ public function unsetShippingTemp() { PurchaseHelper::unsetAllShippingTemp(true); }