shiyeyoushi.vue
3.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
<template>
<div class="containerbox">
<div class="flextwo sharetopk zuixin" @click="back">
<div class="leftrow leftrowkimg">
<img src="../../../assets/leftrowk.png" alt />
</div>
<div class="sharemiddle newacty">唐元集事业优势</div>
<div class="sharebtn">
<!-- <img src="../../../assets/sharebtn.png" alt /> -->
</div>
</div>
<div class="shiyeimg">
<div class="comtexttop flexthree zhaoshangtop" style="margin-bottom:0.3rem">
<div class="textleft flexone">
<div class="textleftheng"></div>
<div class="textyuan"></div>
</div>
<div class="textname zhaoshangvideo">{{intended.goodness_title}}</div>
<div class="textleft flexone">
<div class="textkyuan"></div>
<div class="textrightheng"></div>
</div>
</div>
<div class="shiyebox">
<div v-html="goodness"></div>
</div>
</div>
<div class="comtexttop flexthree zhaoshangtop" style="margin-bottom:0.3rem">
<div class="textleft flexone">
<div class="textleftheng"></div>
<div class="textyuan"></div>
</div>
<div class="textname zhaoshangvideo">{{intended.business_video_title}}</div>
<div class="textleft flexone">
<div class="textkyuan"></div>
<div class="textrightheng"></div>
</div>
</div>
<div class="videoimg" @click="videoplay">
<img :src="videoinfo.business_image" alt v-if="videoplaytrue" />
<video
v-else
controls
autoplay
id="video"
:src="videoinfo.business_video"
loop="loop"
controlslist="nodownload"
height="100%"
width="100%"
webkit-playsinline="true"
x5-video-player-type="h5"
x5-video-player-fullscreen="true"
x5-video-orientation="portraint"
></video>
<img src="../../../assets/anniu.png" alt class="videobtn" v-if="showbtn" />
</div>
<div class="clicknext" style="margin-top:0.4rem">点击下一页查看唐元集经销商故事>> >></div>
<div class="shibot flextwo">
<div class="shibotleft" @click="prepage">上一页</div>
<div class="shibotright" @click="nextpage">下一页</div>
</div>
</div>
</template>
<script>
export default {
data() {
return {
subid: "",
goodness: "",
videoinfo: "",
showbtn: true,
controls: false,
videoplaytrue: true,
intended: ""
};
},
created() {
document.title = "唐元集公众号";
this.subid = this.$route.query.subid;
console.log("999", this.subid);
this.getshiyeyoushi();
this.intended = JSON.parse(localStorage.getItem("intended"));
console.log(this.intended)
},
methods: {
back() {
this.$router.go(-1);
},
nextpage() {
this.$router.push({
path: "/dailistory",
query: { subid: this.subid }
});
},
prepage() {
this.$router.go(-1);
},
getshiyeyoushi() {
let that = this;
var url = "/api/common/goodness";
let param = {};
that.$axios
.post(url, param)
.then(function (res) {
console.log(res);
that.videoinfo = res.data;
that.goodness = res.data.goodness;
})
.catch(function (err) {
console.log(err);
});
},
videoplay() {
console.log(344389);
var video = document.getElementById("video");
this.videoplaytrue = false;
this.showbtn = false;
if (video.paused) {
video.play();
this.showbtn = false;
} else {
video.pause();
this.showbtn = true;
}
}
}
};
</script>
<style scoped>
@import "../../../style/usercenter.css";
.shiyebox {
top: 0.8rem;
/* width: 6.2rem; */
}
</style>