|
|
@@ -9,35 +9,12 @@
|
|
|
<button v-if="ghsCgScene!=''" class="admin-button-com big" style="width:70vw;margin-top:18upx;" @click="goHome">返回首页</button>
|
|
|
<button v-else class="admin-button-com big" style="width:70vw;margin-top:18upx;" @click="goBack">返回</button>
|
|
|
|
|
|
- <view style="margin-top:10upx;" v-if="showFirstGuide">
|
|
|
- <view style="margin-bottom:10upx;margin-top:15upx;" @click="openGuideVideo">
|
|
|
- <image style="width:80vw;" :src="`${constant.imgUrl}/cg/hd_cg_route9.png`" mode="widthFix"></image>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
-
|
|
|
</view>
|
|
|
<!-- #ifdef MP-WEIXIN -->
|
|
|
<view style="width:690upx;height:25upx;background-color: #f5f5f5;"></view>
|
|
|
<ad-custom unit-id="adunit-b3f48f1b6c1a39ff"></ad-custom>
|
|
|
<!-- #endif -->
|
|
|
</view>
|
|
|
-
|
|
|
- <uni-popup ref="guideVideoPopup" background-color="#fff" type="center" :animation="true" @change="onGuideVideoPopupChange">
|
|
|
- <view class="guide-video-popup">
|
|
|
- <video
|
|
|
- v-if="guideVideoUrl"
|
|
|
- id="guideVideo"
|
|
|
- class="guide-video"
|
|
|
- :src="guideVideoUrl"
|
|
|
- :autoplay="true"
|
|
|
- object-fit="contain"
|
|
|
- controls
|
|
|
- show-center-play-btn
|
|
|
- @loadedmetadata="playGuideVideo"
|
|
|
- ></video>
|
|
|
- <button class="admin-button-com default guide-video-close" @click="closeGuideVideo">关闭</button>
|
|
|
- </view>
|
|
|
- </uni-popup>
|
|
|
</view>
|
|
|
</template>
|
|
|
<script>
|
|
|
@@ -54,19 +31,12 @@ export default {
|
|
|
currentEnv:'production',
|
|
|
fromCg:0,
|
|
|
flowersList:[],
|
|
|
- onlyCg:1,
|
|
|
- showFirstGuide:true,
|
|
|
- guideVideoUrl:''
|
|
|
+ onlyCg:1
|
|
|
}
|
|
|
},
|
|
|
onLoad () {
|
|
|
this.hasInit = true
|
|
|
|
|
|
- const storageKey = 'particularsVisitCount'
|
|
|
- let visitCount = Number(uni.getStorageSync(storageKey) || 0) + 1
|
|
|
- uni.setStorageSync(storageKey, visitCount)
|
|
|
- this.showFirstGuide = visitCount <= 3
|
|
|
-
|
|
|
//供货商打开太阳码分享给客户,客户需要采购进来
|
|
|
let scene = uni.getStorageSync('ghsCgScene')
|
|
|
if(scene){
|
|
|
@@ -159,36 +129,6 @@ export default {
|
|
|
this.pageTo({url: '/pagesPurchase/purDetails?id='+this.option.id+'&status=2',type:2})
|
|
|
//this.subscribe()
|
|
|
},
|
|
|
- openGuideVideo() {
|
|
|
- this.guideVideoUrl = `${this.constant.hostUrl}/buy_list.mp4`
|
|
|
- this.$refs.guideVideoPopup.open('center')
|
|
|
- this.$nextTick(() => {
|
|
|
- this.playGuideVideo()
|
|
|
- })
|
|
|
- },
|
|
|
- playGuideVideo() {
|
|
|
- if (!this.guideVideoUrl) {
|
|
|
- return
|
|
|
- }
|
|
|
- const videoContext = uni.createVideoContext('guideVideo', this)
|
|
|
- if (videoContext) {
|
|
|
- videoContext.play()
|
|
|
- }
|
|
|
- },
|
|
|
- closeGuideVideo() {
|
|
|
- const videoContext = uni.createVideoContext('guideVideo', this)
|
|
|
- if (videoContext) {
|
|
|
- videoContext.stop()
|
|
|
- }
|
|
|
- uni.setStorageSync('particularsVisitCount', 4)
|
|
|
- this.showFirstGuide = false
|
|
|
- this.$refs.guideVideoPopup.close()
|
|
|
- },
|
|
|
- onGuideVideoPopupChange(e) {
|
|
|
- if (!e.show) {
|
|
|
- this.guideVideoUrl = ''
|
|
|
- }
|
|
|
- },
|
|
|
subscribe(){
|
|
|
// #ifdef MP-WEIXIN
|
|
|
if(this.getDictionariesInfo && this.getDictionariesInfo.subscribeMessage && this.getDictionariesInfo.subscribeMessage == 1 && this.getDictionariesInfo.hdMiniMessage && this.getDictionariesInfo.hdMiniMessage.cgSuccess && this.getDictionariesInfo.hdMiniMessage.remindHdClear && this.getDictionariesInfo.hdMiniMessage.fhNotice){
|
|
|
@@ -330,23 +270,4 @@ export default {
|
|
|
width: 100%;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
-.guide-video-popup {
|
|
|
- padding: 24upx;
|
|
|
- box-sizing: border-box;
|
|
|
- text-align: center;
|
|
|
-}
|
|
|
-
|
|
|
-.guide-video {
|
|
|
- width: 700upx;
|
|
|
- height: 1000upx;
|
|
|
-}
|
|
|
-
|
|
|
-.guide-video-close {
|
|
|
- margin-top: 24upx;
|
|
|
- width: 200upx;
|
|
|
- padding-top: 20upx;
|
|
|
- padding-bottom: 20upx;
|
|
|
- font-size: 32upx;
|
|
|
-}
|
|
|
</style>
|