Authored by whb

修改sale

@@ -13,13 +13,15 @@ class SaleController extends WebAction @@ -13,13 +13,15 @@ class SaleController extends WebAction
13 public function indexAction() 13 public function indexAction()
14 { 14 {
15 //获取专区ID 15 //获取专区ID
16 - $specialsaleId = $this->param('specialsaleId'); 16 + $specialsaleId = $this->get('specialsale_id');
17 $specialInfo = SaleData::getSpecial($specialsaleId); 17 $specialInfo = SaleData::getSpecial($specialsaleId);
  18 + if(isset($specialInfo['data'])) {
18 $special = $specialInfo['data']; 19 $special = $specialInfo['data'];
19 - 20 + } else {
  21 + $special = array();
  22 + }
20 //获取促销ID 23 //获取促销ID
21 - $promotion = $this->param('promotion');  
22 - 24 + $promotion = $this->get('promotion');
23 //专区ID和促销ID都为空时,跳转到主页 25 //专区ID和促销ID都为空时,跳转到主页
24 if (empty($specialsaleId) && empty($promotion)) { 26 if (empty($specialsaleId) && empty($promotion)) {
25 $this->go(SITE_MAIN); 27 $this->go(SITE_MAIN);