Authored by yangyang

修改注释

@@ -1085,7 +1085,7 @@ class HelperSearch @@ -1085,7 +1085,7 @@ class HelperSearch
1085 } 1085 }
1086 1086
1087 //组织静态资源数据格式 1087 //组织静态资源数据格式
1088 - public static function formatNodeContent($code) 1088 + public static function getNodeContent($code)
1089 { 1089 {
1090 $nodeContent = BrandData::getByNodeContent($code); 1090 $nodeContent = BrandData::getByNodeContent($code);
1091 if (isset($nodeContent['code']) && $nodeContent['code'] === 200) { 1091 if (isset($nodeContent['code']) && $nodeContent['code'] === 200) {
@@ -1102,6 +1102,7 @@ class HelperSearch @@ -1102,6 +1102,7 @@ class HelperSearch
1102 $result[$key]['href'] = $vo; 1102 $result[$key]['href'] = $vo;
1103 $result[$key]['src'] = $img[1][$key]; 1103 $result[$key]['src'] = $img[1][$key];
1104 } 1104 }
  1105 +
1105 return $result; 1106 return $result;
1106 } 1107 }
1107 } 1108 }
@@ -71,7 +71,7 @@ class Bootstrap extends Bootstrap_Abstract @@ -71,7 +71,7 @@ class Bootstrap extends Bootstrap_Abstract
71 $controller = 'Index'; 71 $controller = 'Index';
72 $action = 'Index'; 72 $action = 'Index';
73 // 二级域名 73 // 二级域名
74 - if (2 === $level) { 74 + if (3 === $level) {
75 $url = strtolower($dispatcher->getRequest()->getRequestUri()); 75 $url = strtolower($dispatcher->getRequest()->getRequestUri());
76 if(empty($url) || $url == '/index' || $url == '/') { 76 if(empty($url) || $url == '/index' || $url == '/') {
77 $urlAction = '/index'; 77 $urlAction = '/index';
@@ -40,7 +40,7 @@ class BrandsModel @@ -40,7 +40,7 @@ class BrandsModel
40 40
41 //获取静态内容 41 //获取静态内容
42 if ($options['node']) { 42 if ($options['node']) {
43 - $nodeContent = HelperSearch::formatNodeContent($options['node']); 43 + $nodeContent = HelperSearch::getNodeContent($options['node']);
44 $data['leftContent'][]['picLink']['list'] = $nodeContent; 44 $data['leftContent'][]['picLink']['list'] = $nodeContent;
45 } 45 }
46 46
@@ -35,14 +35,16 @@ class SaleModel @@ -35,14 +35,16 @@ class SaleModel
35 $data = HelperSearch::getList($result, $searchCondition['options']); 35 $data = HelperSearch::getList($result, $searchCondition['options']);
36 36
37 //组织sale数据 37 //组织sale数据
  38 + $special = array();
38 if (isset($specialInfo['data']) && !empty($specialInfo['data']['banner_img'])) { 39 if (isset($specialInfo['data']) && !empty($specialInfo['data']['banner_img'])) {
39 $banner = json_decode($specialInfo['data']['banner_img'], true); 40 $banner = json_decode($specialInfo['data']['banner_img'], true);
40 foreach ($banner as $k => $v) { 41 foreach ($banner as $k => $v) {
41 $v['img'] = Images::getSourceUrl($v['img'], 'couponImg'); 42 $v['img'] = Images::getSourceUrl($v['img'], 'couponImg');
42 $specialInfo['data']['banner'][] = $v; 43 $specialInfo['data']['banner'][] = $v;
43 } 44 }
44 - $special = $specialInfo['data']; 45 + $special = $specialInfo['data'];
45 } 46 }
  47 +
46 //Sale首页 banner数据 48 //Sale首页 banner数据
47 $data['saleBanner']['bannerHeight'] = $special['banner'][0]['height']; 49 $data['saleBanner']['bannerHeight'] = $special['banner'][0]['height'];
48 $data['saleBanner']['img'] = $special['banner'][0]['img']; 50 $data['saleBanner']['img'] = $special['banner'][0]['img'];
@@ -51,7 +53,7 @@ class SaleModel @@ -51,7 +53,7 @@ class SaleModel
51 53
52 //获取广告位数据 54 //获取广告位数据
53 if (isset($special['left_ad_code'])) { 55 if (isset($special['left_ad_code'])) {
54 - $nodeContent = HelperSearch::formatNodeContent($special['left_ad_code']); 56 + $nodeContent = HelperSearch::getNodeContent($special['left_ad_code']);
55 $data['leftContent'][]['picLink']['list'] = $nodeContent; 57 $data['leftContent'][]['picLink']['list'] = $nodeContent;
56 } 58 }
57 59
@@ -32,7 +32,7 @@ class SaleController extends WebAction @@ -32,7 +32,7 @@ class SaleController extends WebAction
32 if(!empty($special['brand_id'])){ 32 if(!empty($special['brand_id'])){
33 $condition['brand'] = $special['brand_id']; 33 $condition['brand'] = $special['brand_id'];
34 } 34 }
35 - //传促销id 35 + //传促销id,促销id为空时传专区id
36 if(!empty($special['ispromotion'])){ 36 if(!empty($special['ispromotion'])){
37 $condition['promotion'] = $special['ispromotion']; 37 $condition['promotion'] = $special['ispromotion'];
38 }else{ 38 }else{
@@ -40,7 +40,6 @@ class SaleController extends WebAction @@ -40,7 +40,6 @@ class SaleController extends WebAction
40 } 40 }
41 41
42 $options = array( 42 $options = array(
43 - 'specialsale_id' => 'Y',  
44 'controller' => $this->_request->controller, 43 'controller' => $this->_request->controller,
45 'reviewNum' => 6 44 'reviewNum' => 6
46 ); 45 );