Changeset 19091
- Timestamp:
- 2010/11/06 22:18:21 (13 years ago)
- Location:
- branches/camp/camp-2_5-E/data/class/pages/shopping
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/camp/camp-2_5-E/data/class/pages/shopping/LC_Page_Shopping.php
r18853 r19091 69 69 */ 70 70 function process() { 71 global $objCampaignSess; 72 73 $objView = new SC_SiteView(); 71 parent::process(); 72 $this->action(); 73 $this->endResponse(); 74 } 75 76 /** 77 * Page のプロセス. 78 * 79 * @return void 80 */ 81 function action() { 74 82 $objSiteSess = new SC_SiteSession(); 75 83 $objCartSess = new SC_CartSession(); 76 $objCampaignSess = new SC_CampaignSession();77 84 $objCustomer = new SC_Customer(); 78 85 $objCookie = new SC_Cookie(); … … 192 199 193 200 $this->transactionid = $this->getToken(); 194 $objView->assignobj($this);195 // フレームを選択(キャンペーンページから遷移なら変更)196 $objCampaignSess->pageView($objView);197 201 } 198 202 … … 208 212 209 213 /** 214 * Page のアクション(モバイル). 215 * 216 * @return void 217 */ 218 function mobileProcess() { 219 parent::mobileProcess(); 220 $this->mobileAction(); 221 $this->endResponse(); 222 } 223 224 /** 210 225 * Page のプロセス(モバイル). 211 226 * 212 227 * @return void 213 228 */ 214 function mobile Process() {229 function mobileAction() { 215 230 $objView = new SC_MobileView(); 216 231 $objSiteSess = new SC_SiteSession(); … … 257 272 $this->tpl_login_memory = "1"; 258 273 } 259 260 $objView->assignobj($this);261 $objView->display(SITE_FRAME);262 274 } 263 275 -
branches/camp/camp-2_5-E/data/class/pages/shopping/LC_Page_Shopping_Complete.php
r18910 r19091 59 59 */ 60 60 function process() { 61 global $objCampaignSess; 62 61 $this->action(); 62 $this->sendResponse(); 63 } 64 65 /** 66 * Page のアクション. 67 * 68 * @return void 69 */ 70 function action() { 63 71 $objView = new SC_SiteView(); 64 72 $objSiteInfo = $objView->objSiteInfo; 65 73 $this->arrInfo = $objSiteInfo->data; 66 67 $objView->assignobj($this);68 $objView->display(SITE_FRAME);69 74 } 70 75 … … 93 98 */ 94 99 function mobileProcess() { 100 $this->mobileAction(); 101 $this->sendResponse(); 102 } 103 /** 104 * Page のプロセス(モバイル). 105 * 106 * @return void 107 */ 108 function mobileAction() { 95 109 $objView = new SC_MobileView(); 96 110 $this->objSiteSess = new SC_SiteSession(); … … 152 166 } 153 167 } 154 155 $objView->assignobj($this);156 $objView->display(SITE_FRAME);157 168 } 158 169 … … 234 245 } 235 246 // 一時テーブルを受注テーブルに格納する 236 if (defined("MOBILE_SITE")) { 237 $order_id = $this->lfRegistOrder($objQuery, $arrData); 238 } else { 239 $order_id = $this->lfRegistOrder($objQuery, $arrData, $this->objCampaignSess); 240 } 247 $order_id = $this->lfRegistOrder($objQuery, $arrData); 241 248 // カート商品を受注詳細テーブルに格納する 242 249 $this->lfRegistOrderDetail($objQuery, $order_id, $this->objCartSess); 243 250 // 受注一時テーブルの情報を削除する。 244 251 $this->lfDeleteTempOrder($objQuery, $uniqid); 245 // キャンペーンからの遷移の場合登録する。246 if (!defined("MOBILE_SITE")) {247 if($this->objCampaignSess->getIsCampaign() and $this->objCartSess->chkCampaign($this->objCampaignSess->getCampaignId())) {248 $this->lfRegistCampaignOrder($objQuery, $objCampaignSess, $order_id);249 }250 }251 252 252 253 // セッションカート内の商品を削除する。 … … 381 382 * @return integer 注文番号 382 383 */ 383 function lfRegistOrder($objQuery, $arrData , $objCampaignSess = null) {384 function lfRegistOrder($objQuery, $arrData) { 384 385 $objDb = new SC_Helper_DB_Ex(); 385 386 $sqlval = $arrData; … … 432 433 $sqlval['create_date'] = 'Now()'; // 受注日 433 434 $sqlval['update_date'] = 'Now()'; // 更新日時 434 435 // キャンペーンID436 if (!defined("MOBILE_SITE")) {437 if ($objCampaignSess->getIsCampaign()) $sqlval['campaign_id'] = $objCampaignSess->getCampaignId();438 }439 435 440 436 // 受注テーブルの登録 … … 489 485 } 490 486 491 // キャンペーン受注テーブルへ登録492 function lfRegistCampaignOrder(&$objQuery, &$objCampaignSess, $order_id) {493 494 // 受注データを取得495 $cols = "order_id, campaign_id, customer_id, message, order_name01, order_name02,".496 "order_kana01, order_kana02, order_email, order_tel01, order_tel02, order_tel03,".497 "order_fax01, order_fax02, order_fax03, order_zip01, order_zip02, order_pref, order_addr01,".498 "order_addr02, order_sex, order_birth, order_job, deliv_name01, deliv_name02, deliv_kana01,".499 "deliv_kana02, deliv_tel01, deliv_tel02, deliv_tel03, deliv_fax01, deliv_fax02, deliv_fax03,".500 "deliv_zip01, deliv_zip02, deliv_pref, deliv_addr01, deliv_addr02, payment_total";501 502 $arrOrder = $objQuery->select($cols, "dtb_order", "order_id = ?", array($order_id));503 504 $sqlval = $arrOrder[0];505 $sqlval['create_date'] = 'Now()';506 507 // INSERTの実行508 $objQuery->insert("dtb_campaign_order", $sqlval);509 510 // 申し込み数の更新511 $total_count = $objQuery->get("dtb_campaign", "total_count", "campaign_id = ?", array($sqlval['campaign_id']));512 $arrCampaign['total_count'] = $total_count += 1;513 $objQuery->update("dtb_campaign", $arrCampaign, "campaign_id = ?", array($sqlval['campaign_id']));514 515 }516 517 518 519 487 /* 受注一時テーブルの削除 */ 520 488 function lfDeleteTempOrder(&$objQuery, $uniqid) { -
branches/camp/camp-2_5-E/data/class/pages/shopping/LC_Page_Shopping_Confirm.php
r18871 r19091 62 62 */ 63 63 function process() { 64 global $objCampaignSess; 65 64 $this->action(); 65 $this->sendResponse(); 66 } 67 68 /** 69 * Page のプロセス. 70 * 71 * @return void 72 */ 73 function process() { 66 74 $objView = new SC_SiteView(); 67 75 $objCartSess = new SC_CartSession(); 68 76 $objSiteInfo = $objView->objSiteInfo; 69 77 $objSiteSess = new SC_SiteSession(); 70 $objCampaignSess = new SC_CampaignSession();71 78 $objCustomer = new SC_Customer(); 72 79 $objQuery = new SC_Query(); … … 167 174 break; 168 175 } 169 170 $this->arrData = $arrData;171 $this->arrInfo = $objSiteInfo->data;172 $objView->assignobj($this);173 // フレームを選択(キャンペーンページから遷移なら変更)174 $objCampaignSess->pageView($objView);175 176 } 176 177 … … 190 191 */ 191 192 function mobileProcess() { 193 $this->mobileAction(); 194 $this->sendResponse(); 195 } 196 197 /** 198 * Page のアクション(モバイル). 199 * 200 * @return void 201 */ 202 function mobileAction() { 192 203 $objView = new SC_MobileView(); 193 204 $objCartSess = new SC_CartSession(); … … 270 281 $this->arrData = $arrData; 271 282 $this->arrInfo = $objSiteInfo->data; 272 $objView->assignobj($this);273 $objView->display(SITE_FRAME);274 283 } 275 284 -
branches/camp/camp-2_5-E/data/class/pages/shopping/LC_Page_Shopping_Deliv.php
r18880 r19091 67 67 */ 68 68 function process() { 69 global $objCampaignSess; 70 69 $this->action(); 70 $this->sendResponse(); 71 } 72 73 /** 74 * Page のプロセス. 75 * 76 * @return void 77 */ 78 function action() { 71 79 $objView = new SC_SiteView(); 72 80 $objSiteSess = new SC_SiteSession(); 73 81 $objCartSess = new SC_CartSession(); 74 $objCampaignSess = new SC_CampaignSession();75 82 $objCustomer = new SC_Customer(); 76 83 $objDb = new SC_Helper_DB_Ex(); … … 225 232 $this->arrForm = $this->objFormParam->getFormParamList(); 226 233 $this->arrErr = $arrErr; 227 228 $objView->assignobj($this);229 // フレームを選択(キャンペーンページから遷移なら変更)230 $objCampaignSess->pageView($objView);231 234 } 232 235 … … 246 249 */ 247 250 function mobileProcess() { 251 $this->mobileAction(); 252 $this->sendResponse(); 253 } 254 255 /** 256 * Page のプロセス(モバイル). 257 * 258 * @return void 259 */ 260 function mobileAction() { 248 261 $objView = new SC_MobileView(); 249 262 $objSiteSess = new SC_SiteSession(); … … 426 439 $this->arrForm = $this->objFormParam->getFormParamList(); 427 440 $this->arrErr = $arrErr; 428 $objView->assignobj($this);429 $objView->display(SITE_FRAME);430 441 } 431 442 -
branches/camp/camp-2_5-E/data/class/pages/shopping/LC_Page_Shopping_DelivAddr.php
r18853 r19091 52 52 */ 53 53 function process() { 54 $this->action(); 55 $this->sendResponse(); 56 } 57 58 /** 59 * Page のアクション. 60 * 61 * @return void 62 */ 63 function action() { 54 64 } 55 65 … … 72 82 */ 73 83 function mobileProcess() { 84 $this->mobileAction(); 85 $this->sendResponse(); 86 } 87 88 /** 89 * Page のアクション(モバイル). 90 * 91 * @return void 92 */ 93 function mobileAction() { 74 94 $objView = new SC_MobileView(false); 75 95 $objQuery = new SC_Query(); … … 186 206 } 187 207 } 188 189 $objView->assignobj($this);190 $objView->display(SITE_FRAME);191 208 } 192 209 -
branches/camp/camp-2_5-E/data/class/pages/shopping/LC_Page_Shopping_Payment.php
r18860 r19091 65 65 */ 66 66 function process() { 67 global $objCampaignSess; 68 69 $objView = new SC_SiteView(); 67 $this->action(); 68 $this->sendResponse(); 69 } 70 71 /** 72 * Page のプロセス. 73 * 74 * @return void 75 */ 76 function action() { 70 77 $objSiteSess = new SC_SiteSession(); 71 78 $objCartSess = new SC_CartSession(); 72 $objCampaignSess = new SC_CampaignSession();73 79 $objDb = new SC_Helper_DB_Ex(); 74 80 $this->objCustomer = new SC_Customer(); … … 175 181 176 182 $this->arrForm = $this->objFormParam->getFormParamList(); 177 178 $objView->assignobj($this);179 // フレームを選択(キャンペーンページから遷移なら変更)180 $objCampaignSess->pageView($objView);181 183 } 182 184 … … 196 198 */ 197 199 function mobileProcess() { 198 $objView = new SC_MobileView(); 200 $this->mobileAction(); 201 $this->sendResponse(); 202 } 203 204 /** 205 * Page のプロセス(モバイル). 206 * 207 * @return void 208 */ 209 function mobileProcess() { 199 210 $objSiteSess = new SC_SiteSession(); 200 211 $objCartSess = new SC_CartSession(); … … 338 349 339 350 $this->arrForm = $this->objFormParam->getFormParamList(); 340 341 $objView->assignobj($this);342 $objView->display(SITE_FRAME);343 351 } 344 352
Note: See TracChangeset
for help on using the changeset viewer.