Authored by 郝肖肖

通过shopid判断是基础模板还是经典模板

@@ -695,7 +695,15 @@ class ShopModel @@ -695,7 +695,15 @@ class ShopModel
695 695
696 public static function getIntro($shopId, $uid) 696 public static function getIntro($shopId, $uid)
697 { 697 {
698 - $data = array('brandName' => '', 'brandCont' => '', 'domain'=> '', 'logo'=> '', 'is_favorite'=> false, 'multBrandShopType' => 0); 698 + $data = array(
  699 + 'brandName' => '',
  700 + 'brandCont' => '',
  701 + 'domain'=> '',
  702 + 'logo'=> '',
  703 + 'is_favorite'=> false,
  704 + 'multBrandShopType' => 0,
  705 + 'shop_template_type' => 0
  706 + );
699 707
700 $intro = ShopData::getIntro($shopId, $uid); 708 $intro = ShopData::getIntro($shopId, $uid);
701 709
@@ -706,6 +714,7 @@ class ShopModel @@ -706,6 +714,7 @@ class ShopModel
706 'domain'=> $intro['data']['shop_domain'], 714 'domain'=> $intro['data']['shop_domain'],
707 'logo'=> $intro['data']['shop_logo'], 715 'logo'=> $intro['data']['shop_logo'],
708 'isFavorite'=> ($intro['data']['is_favorite'] === 'Y'), 716 'isFavorite'=> ($intro['data']['is_favorite'] === 'Y'),
  717 + 'shopTemplateType'=> intval($intro['data']['shop_template_type']),
709 'multBrandShopType'=> intval($intro['data']['mult_brand_shop_type']) 718 'multBrandShopType'=> intval($intro['data']['mult_brand_shop_type'])
710 ); 719 );
711 } 720 }
@@ -41,9 +41,9 @@ class IndexController extends WebAction @@ -41,9 +41,9 @@ class IndexController extends WebAction
41 $this->go('http://search.yohobuy.com/?query=' . $domain); 41 $this->go('http://search.yohobuy.com/?query=' . $domain);
42 } else { 42 } else {
43 $shopIntro = ShopModel::getIntro($shopId, $uid); 43 $shopIntro = ShopModel::getIntro($shopId, $uid);
44 - if (!empty($shopIntro['multBrandShopType']) && $shopIntro['multBrandShopType'] === 1) { 44 + if (!empty($shopIntro['shopTemplateType']) && $shopIntro['shopTemplateType'] === 1) {
45 //基础模板多个品牌 45 //基础模板多个品牌
46 - $result['shopTemplateType'] = $shopIntro['multBrandShopType']; 46 + $result['shopTemplateType'] = $shopIntro['shopTemplateType'];
47 $result['shopId'] = $shopIntro['shopId']; 47 $result['shopId'] = $shopIntro['shopId'];
48 break; 48 break;
49 } 49 }