|
|
|
@ -2,8 +2,12 @@
|
|
|
|
<view>
|
|
|
|
<view>
|
|
|
|
<view class="u-skeleton">
|
|
|
|
<view class="u-skeleton">
|
|
|
|
<view class="product-picture u-skeleton-rect">
|
|
|
|
<view class="product-picture u-skeleton-rect">
|
|
|
|
<video style="width: 100%;" v-if="showFlag === 0" :src="detail.video"
|
|
|
|
<swiper class="service-show-swiper" :indicator-dots="true" v-if="showFlag === 0">
|
|
|
|
play-btn-position="center"></video>
|
|
|
|
<swiper-item v-for="(img,index) in detail.confinement_picture_video" :key="index">
|
|
|
|
|
|
|
|
<video :src="img.picture" style="width: 100%;height: 100%;" play-btn-position="center"></video>
|
|
|
|
|
|
|
|
</swiper-item>
|
|
|
|
|
|
|
|
</swiper>
|
|
|
|
|
|
|
|
|
|
|
|
<swiper class="product-picture-swiper" :indicator-dots="true"
|
|
|
|
<swiper class="product-picture-swiper" :indicator-dots="true"
|
|
|
|
@change="e => swiperIndex = e.detail.current + 1" v-if="showFlag === 1">
|
|
|
|
@change="e => swiperIndex = e.detail.current + 1" v-if="showFlag === 1">
|
|
|
|
<swiper-item v-for="(img,index) in detail.confinement_picture" :key="index">
|
|
|
|
<swiper-item v-for="(img,index) in detail.confinement_picture" :key="index">
|
|
|
|
@ -19,10 +23,11 @@
|
|
|
|
</image>
|
|
|
|
</image>
|
|
|
|
<view class="service-show-btn-img__num">{{detail.confinement_picture.length}}</view>
|
|
|
|
<view class="service-show-btn-img__num">{{detail.confinement_picture.length}}</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="service-show-btn-video" v-if="detail.video" @click="showFlag = 0">
|
|
|
|
<view class="service-show-btn-video" v-if="detail.confinement_picture_video.length>0"
|
|
|
|
|
|
|
|
@click="showFlag = 0">
|
|
|
|
<image src="../../static/video.png">
|
|
|
|
<image src="../../static/video.png">
|
|
|
|
</image>
|
|
|
|
</image>
|
|
|
|
<view class="service-show-btn-img__num">1</view>
|
|
|
|
<view class="service-show-btn-img__num">{{detail.confinement_picture_video.length}}</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
@ -78,8 +83,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
<view class="service-baseinfo-center-store u-skeleton-fillet">
|
|
|
|
<view class="service-baseinfo-center-store u-skeleton-fillet">
|
|
|
|
|
|
|
|
|
|
|
|
<video :src="detail.video" v-if="detail.video" style="width: 100%;"
|
|
|
|
<video :src="detail.video" v-if="detail.video" style="width: 100%;" play-btn-position="center"></video>
|
|
|
|
play-btn-position="center"></video>
|
|
|
|
|
|
|
|
<u-image :src="detail.cover_picture" v-else mode="aspectFill" height="397" width="100%"
|
|
|
|
<u-image :src="detail.cover_picture" v-else mode="aspectFill" height="397" width="100%"
|
|
|
|
border-radius="30" @load="$u.debounce(init,100)">
|
|
|
|
border-radius="30" @load="$u.debounce(init,100)">
|
|
|
|
</u-image>
|
|
|
|
</u-image>
|
|
|
|
@ -168,7 +172,19 @@
|
|
|
|
id
|
|
|
|
id
|
|
|
|
},
|
|
|
|
},
|
|
|
|
utilSuccess: (res) => {
|
|
|
|
utilSuccess: (res) => {
|
|
|
|
this.detail = res
|
|
|
|
let confinement_picture_video = [];
|
|
|
|
|
|
|
|
let confinement_picture = [];
|
|
|
|
|
|
|
|
res.confinement_picture.map(item => {
|
|
|
|
|
|
|
|
if (item.picture.indexOf("mp4") > -1) {
|
|
|
|
|
|
|
|
confinement_picture_video.push(item)
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
confinement_picture.push(item)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.detail = res;
|
|
|
|
|
|
|
|
this.detail.confinement_picture_video = confinement_picture_video;
|
|
|
|
|
|
|
|
this.detail.confinement_picture = confinement_picture;
|
|
|
|
this.loading = false
|
|
|
|
this.loading = false
|
|
|
|
console.log(res);
|
|
|
|
console.log(res);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|