好店推荐调整 review by chenlin
Showing
2 changed files
with
8 additions
and
6 deletions
@@ -54,11 +54,13 @@ export default class ShopRecommend extends Component{ | @@ -54,11 +54,13 @@ export default class ShopRecommend extends Component{ | ||
54 | let shopItem = list[i]; | 54 | let shopItem = list[i]; |
55 | if (shopId == shopItem.shopId) { | 55 | if (shopId == shopItem.shopId) { |
56 | if (type == 'top') { | 56 | if (type == 'top') { |
57 | - imageUrl = SlicedImage.getSlicedUrl(shopItem.src, 240*DEVICE_WIDTH_RATIO, 116*DEVICE_WIDTH_RATIO, 2); | ||
58 | - }else if (type == 'left') { | ||
59 | - imageUrl = SlicedImage.getSlicedUrl(shopItem.goods0.src, 92*DEVICE_WIDTH_RATIO, 135*DEVICE_WIDTH_RATIO, 2); | ||
60 | - }else if (type == 'right') { | ||
61 | - imageUrl = SlicedImage.getSlicedUrl(shopItem.goods1.src, 92*DEVICE_WIDTH_RATIO, 135*DEVICE_WIDTH_RATIO, 2); | 57 | + imageUrl = shopItem.src && SlicedImage.getSlicedUrl(shopItem.src, 240*DEVICE_WIDTH_RATIO, 116*DEVICE_WIDTH_RATIO, 2); |
58 | + } else if (type == 'left') { | ||
59 | + imageUrl = shopItem.goods0 && shopItem.goods0.src && SlicedImage.getSlicedUrl(shopItem.goods0.src, 80*DEVICE_WIDTH_RATIO, 106*DEVICE_WIDTH_RATIO, 2); | ||
60 | + } else if (type == 'right') { | ||
61 | + imageUrl = shopItem.goods2 && shopItem.goods2.src && SlicedImage.getSlicedUrl(shopItem.goods2.src, 80*DEVICE_WIDTH_RATIO, 106*DEVICE_WIDTH_RATIO, 2); | ||
62 | + } else if (type == 'center') { | ||
63 | + imageUrl = shopItem.goods1 && shopItem.goods1.src && SlicedImage.getSlicedUrl(shopItem.goods1.src, 80*DEVICE_WIDTH_RATIO, 106*DEVICE_WIDTH_RATIO, 2); | ||
62 | } | 64 | } |
63 | break; | 65 | break; |
64 | } | 66 | } |
@@ -108,7 +108,7 @@ class HomeContainer extends Component { | @@ -108,7 +108,7 @@ class HomeContainer extends Component { | ||
108 | 108 | ||
109 | componentDidMount() { | 109 | componentDidMount() { |
110 | // this.props.actions.loadChannelCachedData(); | 110 | // this.props.actions.loadChannelCachedData(); |
111 | - // this.home && this.home.trigggePullToRefresh(); | 111 | + this.home && this.home.trigggePullToRefresh(); |
112 | } | 112 | } |
113 | 113 | ||
114 | componentWillUnmount() { | 114 | componentWillUnmount() { |
-
Please register or login to post a comment