Commit d1bcc0bb794b035a9ece7de4ddf3f09dda0dfd73

Authored by wangfan
1 parent be38db89

商家大图

@@ -166,4 +166,28 @@ Page({ @@ -166,4 +166,28 @@ Page({
166 this.location=e.detail 166 this.location=e.detail
167 this.GetSellerDetail(); 167 this.GetSellerDetail();
168 }, 168 },
  169 + reviweBanner(){
  170 + wx.previewImage({
  171 + current:this.data.seller.envi_image[this.data.current],
  172 + urls:this.data.seller.envi_image
  173 + })
  174 + },
  175 + reviweRoomImage(e){
  176 + wx.previewImage({
  177 + current:util.attr(e,'current'),
  178 + urls:this.data.seller.room_image
  179 + })
  180 + },
  181 + reviweDishesImage(e){
  182 + let urls=[];
  183 + this.data.seller.dishes.forEach(d=>{
  184 + if(d.image){
  185 + urls.push(d.image)
  186 + }
  187 + })
  188 + wx.previewImage({
  189 + current:util.attr(e,'current'),
  190 + urls:urls
  191 + })
  192 + },
169 }) 193 })
@@ -5,7 +5,7 @@ @@ -5,7 +5,7 @@
5 indicator-dots="{{false}}" autoplay="{{true}}" circular="{{false}}" vertical="{{false}}" 5 indicator-dots="{{false}}" autoplay="{{true}}" circular="{{false}}" vertical="{{false}}"
6 interval="2000" duration="500" 6 interval="2000" duration="500"
7 previous-margin="{{0}}px" next-margin="{{0}}px" 7 previous-margin="{{0}}px" next-margin="{{0}}px"
8 - current="{{current}}" bindchange="bindtransition"> 8 + current="{{current}}" bindchange="bindtransition" bindtap="reviweBanner">
9 <block wx:for="{{seller.envi_image}}" wx:key="sellers.key"> 9 <block wx:for="{{seller.envi_image}}" wx:key="sellers.key">
10 <swiper-item> 10 <swiper-item>
11 <image class="image" mode="aspectFill" 11 <image class="image" mode="aspectFill"
@@ -71,7 +71,7 @@ @@ -71,7 +71,7 @@
71 71
72 <block wx:for="{{seller.room_image}}" wx:key="sellers.key"> 72 <block wx:for="{{seller.room_image}}" wx:key="sellers.key">
73 <view class="image"> 73 <view class="image">
74 - <image mode="aspectFill" 74 + <image mode="aspectFill" bindtap="reviweRoomImage" data-current="{{item}}"
75 src="{{item}}?imageView2/2/w/640/interlace/0/q/100"></image> 75 src="{{item}}?imageView2/2/w/640/interlace/0/q/100"></image>
76 </view> 76 </view>
77 </block> 77 </block>
@@ -93,7 +93,7 @@ @@ -93,7 +93,7 @@
93 <block wx:for="{{seller.dishes}}" wx:key="sellers.key"> 93 <block wx:for="{{seller.dishes}}" wx:key="sellers.key">
94 <view class="image-view" wx:if="{{item.image}}"> 94 <view class="image-view" wx:if="{{item.image}}">
95 <view class="image"> 95 <view class="image">
96 - <image mode="aspectFill" 96 + <image mode="aspectFill" bindtap="reviweDishesImage" data-current="{{item.image}}"
97 src="{{item.image}}?imageView2/2/w/640/interlace/0/q/100"></image> 97 src="{{item.image}}?imageView2/2/w/640/interlace/0/q/100"></image>
98 </view> 98 </view>
99 <view class="text Semibold">{{item.name}}</view> 99 <view class="text Semibold">{{item.name}}</view>