Authored by 郭成尧

del log

@@ -232,7 +232,7 @@ const brand = (req, res, next) => { @@ -232,7 +232,7 @@ const brand = (req, res, next) => {
232 }, params); 232 }, params);
233 233
234 // 无店铺:0--->品牌页 无单品店有多品店:1--->搜索页 有单品店:2--->店铺页面 234 // 无店铺:0--->品牌页 无单品店有多品店:1--->搜索页 有单品店:2--->店铺页面
235 - if (brandLogo.type === '2' && brandLogo.shopId) { 235 + if (req.query.from !== 'search' && brandLogo.type === '2' && brandLogo.shopId) {
236 _shop(req, res, brandLogo.shopId); 236 _shop(req, res, brandLogo.shopId);
237 } else { // 获取品牌店铺信息 237 } else { // 获取品牌店铺信息
238 listModel.getBrandShops(brandId).then(brandShop => { 238 listModel.getBrandShops(brandId).then(brandShop => {
@@ -46,12 +46,12 @@ const list = (req, res, next) => { @@ -46,12 +46,12 @@ const list = (req, res, next) => {
46 query = query.toLowerCase(); 46 query = query.toLowerCase();
47 _.forEach(result[0], obj => { 47 _.forEach(result[0], obj => {
48 48
49 - if (query === obj.brandDomain && /^[a-z0-9]+$/i.test(obj.brandName)) { // 精确查品牌域名 49 + if (query === obj.brandDomain) { // 精确查品牌域名
50 domain = query; 50 domain = query;
51 return false; 51 return false;
52 } 52 }
53 53
54 - if (query === obj.brandName || query === obj.brandName || query === obj.brandName && /^[a-z0-9]+$/i.test(obj.brandName)) { // 精确查品牌名称 54 + if (query === obj.brandName || query === obj.brandName || query === obj.brandName) { // 精确查品牌名称
55 domain = obj.brandDomain; 55 domain = obj.brandDomain;
56 return false; 56 return false;
57 } 57 }
@@ -670,7 +670,6 @@ const getBrandShops = (brandId) => { @@ -670,7 +670,6 @@ const getBrandShops = (brandId) => {
670 code: 200, 670 code: 200,
671 cache: true 671 cache: true
672 }).then(result => { 672 }).then(result => {
673 - console.log(result);  
674 if (_.isArray(result.data)) { 673 if (_.isArray(result.data)) {
675 return _processBrandShops(result.data); 674 return _processBrandShops(result.data);
676 } else { 675 } else {