Changeset 14112 for branches/rel/data
- Timestamp:
- 2007/06/01 16:25:20 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/rel/data/class/SC_CartSession.php
r12157 r14112 173 173 174 174 // ¥«¡¼¥È¤Ø¤Î¾¦ÉÊÄɲà 175 function addProduct($id, $quantity ) {175 function addProduct($id, $quantity, $is_campaign) { 176 176 $find = false; 177 177 $max = $this->getMax(); … … 182 182 if(strlen($val) <= INT_LEN) { 183 183 $_SESSION[$this->key][$i]['quantity']+= $quantity; 184 if($is_campaign) $_SESSION[$this->key][$i]['is_campaign'] = $is_campaign; 184 185 } 185 186 $find = true; … … 190 191 $_SESSION[$this->key][$max+1]['quantity'] = $quantity; 191 192 $_SESSION[$this->key][$max+1]['cart_no'] = $this->getNextCartID(); 193 if($is_campaign) $_SESSION[$this->key][$max+1]['is_campaign'] = $is_campaign; 192 194 } 193 195 } … … 322 324 } 323 325 } 324 326 327 /** 328 * ¥«¡¼¥È¤ÎÃæ¤Î¥¥ã¥ó¥Ú¡¼¥ó¾¦ÉʤΥÁ¥§¥Ã¥¯ 329 * @param void 330 * @return boolean True:¥¥ã¥ó¥Ú¡¼¥ó¾¦ÉÊͤê False:¥¥ã¥ó¥Ú¡¼¥ó¾¦ÉÊ̵¤· 331 */ 332 function chkCampaign(){ 333 $max = $this->getMax(); 334 for($i = 0; $i <= $max; $i++) { 335 if($_SESSION[$this->key][$i]['is_campaign']) return true; 336 } 337 338 return false; 339 } 340 325 341 } 326 342 ?>
Note: See TracChangeset
for help on using the changeset viewer.