Authored by hf

code review by fei.hong: do merge yang.yang and shaofeng.zhou fixes bugs codes

@@ -502,7 +502,7 @@ lazyLoad($('#details-html img')); @@ -502,7 +502,7 @@ lazyLoad($('#details-html img'));
502 } 502 }
503 503
504 if (hasOnlyOneSize) { 504 if (hasOnlyOneSize) {
505 - $sizes.find('li').click(); 505 + $sizes.eq(0).find('li').click();
506 } 506 }
507 }()); 507 }());
508 508
@@ -31,7 +31,10 @@ class CommonController extends WebAction @@ -31,7 +31,10 @@ class CommonController extends WebAction
31 // 首页资源品牌,采用内存存储 31 // 首页资源品牌,采用内存存储
32 $key = WebCacheConfig::KEY_WEB_INDEX_BRANDS_LIST_DATA . '_' . $type; 32 $key = WebCacheConfig::KEY_WEB_INDEX_BRANDS_LIST_DATA . '_' . $type;
33 // array('logoBrand'=>'','moreBrand'=>'') 33 // array('logoBrand'=>'','moreBrand'=>'')
34 - $data = Cache::get($key); 34 + $data = Cache::get($key,'master');
  35 + if(empty($data)) {//从slave取数据
  36 + $data = Cache::get($key, 'slave');
  37 + }
35 38
36 } while (false); 39 } while (false);
37 40
@@ -170,7 +170,7 @@ class ItemModel @@ -170,7 +170,7 @@ class ItemModel
170 } 170 }
171 } 171 }
172 //分享相关 172 //分享相关
173 - $goodsInfo['weixinUrl'] = Helpers::Url($_SERVER['REQUEST_URI'], array(),'item'); 173 + $goodsInfo['weixinUrl'] = Helpers::url($_SERVER['REQUEST_URI'], array(),'item');
174 $goodsInfo['sharedTitle'] = $goodsInfo['name']; 174 $goodsInfo['sharedTitle'] = $goodsInfo['name'];
175 $goodsInfo['shareImg'] = $goodsInfo['img']; 175 $goodsInfo['shareImg'] = $goodsInfo['img'];
176 $goodsInfo['shareDesc'] = $baseInfo['phrase']; 176 $goodsInfo['shareDesc'] = $baseInfo['phrase'];