|
@@ -1,7 +1,8 @@
|
1
|
1
|
<template>
|
2
|
|
- <div>
|
3
|
|
- <div class="newsTitle"> {{articles.title}}</div>
|
|
2
|
+ <div class="page_newsDetail">
|
|
3
|
+ <div class="newsTitle">{{articles.title}}</div>
|
4
|
4
|
<div class="msg" v-html="articles.content" v-show="articleshow"></div>
|
|
5
|
+<<<<<<< .mine
|
5
|
6
|
<div class="video" v-show="videoshow">
|
6
|
7
|
<video id="example_video_1" class="video-js vjs-default-skin"
|
7
|
8
|
controls preload="auto" width="100%" height="100%"
|
|
@@ -10,47 +11,78 @@
|
10
|
11
|
<source :src="articles.video_url" type='video/mp4' />
|
11
|
12
|
</video>
|
12
|
13
|
</div>
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+=======
|
|
22
|
+ <div class="video" v-show="videoshow">
|
|
23
|
+ <video
|
|
24
|
+ id="example_video_1"
|
|
25
|
+ class="video-js vjs-default-skin"
|
|
26
|
+ controls
|
|
27
|
+ preload="auto"
|
|
28
|
+ width="640"
|
|
29
|
+ height="300"
|
|
30
|
+ poster="http://video-js.zencoder.com/oceans-clip.png"
|
|
31
|
+ data-setup="{"example_option":true}"
|
|
32
|
+ ref="video"
|
|
33
|
+ >
|
|
34
|
+ <source :src="articles.video_url" type="video/mp4" />
|
|
35
|
+ </video>
|
|
36
|
+ </div>
|
|
37
|
+>>>>>>> .theirs
|
13
|
38
|
</div>
|
14
|
39
|
</template>
|
15
|
40
|
<script>
|
16
|
|
- import { singleArticleInfo } from "@/api/micro/micro"
|
17
|
|
- export default{
|
18
|
|
- data(){
|
19
|
|
- return{
|
20
|
|
- articles:[],
|
21
|
|
- videoshow:false,
|
22
|
|
- articleshow:true,
|
23
|
|
- }
|
24
|
|
- },
|
25
|
|
- methods:{
|
26
|
|
- singleArticleInfo(id,orgid){
|
27
|
|
- singleArticleInfo(id,orgid).then(response=>{
|
28
|
|
- if(response.data.state == 1){
|
29
|
|
- var articles = response.data.data.articles;
|
30
|
|
- console.log("articles是什么",articles)
|
31
|
|
- this.articles = articles;
|
32
|
|
- if(articles.video_url != ""){
|
33
|
|
- this.articleshow = false;
|
34
|
|
- this.videoshow = true;
|
35
|
|
- this.$refs.video.src = articles.video_url;
|
36
|
|
- }
|
37
|
|
-
|
38
|
|
- }
|
39
|
|
- })
|
|
41
|
+import { singleArticleInfo } from "@/api/micro/micro";
|
|
42
|
+export default {
|
|
43
|
+ data() {
|
|
44
|
+ return {
|
|
45
|
+ articles: [],
|
|
46
|
+ videoshow: false,
|
|
47
|
+ articleshow: true
|
|
48
|
+ };
|
|
49
|
+ },
|
|
50
|
+ methods: {
|
|
51
|
+ singleArticleInfo(id, orgid) {
|
|
52
|
+ singleArticleInfo(id, orgid).then(response => {
|
|
53
|
+ if (response.data.state == 1) {
|
|
54
|
+ var articles = response.data.data.articles;
|
|
55
|
+ console.log("articles是什么", articles);
|
|
56
|
+ this.articles = articles;
|
|
57
|
+ if (articles.video_url != "") {
|
|
58
|
+ this.articleshow = false;
|
|
59
|
+ this.videoshow = true;
|
|
60
|
+ this.$refs.video.src = articles.video_url;
|
40
|
61
|
}
|
41
|
|
- },
|
42
|
|
- created(){
|
43
|
|
- const id = this.$route.query.id;
|
44
|
|
- const orgid = this.$route.query.orgid;
|
45
|
|
- console.log("id是多少",id)
|
46
|
|
- console.log("orgid是多少",orgid)
|
47
|
|
- this.singleArticleInfo(id,orgid)
|
48
|
|
- },
|
49
|
|
- }
|
50
|
|
- </script>
|
|
62
|
+ }
|
|
63
|
+ });
|
|
64
|
+ }
|
|
65
|
+ },
|
|
66
|
+ created() {
|
|
67
|
+ const id = this.$route.query.id;
|
|
68
|
+ const orgid = this.$route.query.orgid;
|
|
69
|
+ console.log("id是多少", id);
|
|
70
|
+ console.log("orgid是多少", orgid);
|
|
71
|
+ this.singleArticleInfo(id, orgid);
|
|
72
|
+ }
|
|
73
|
+};
|
|
74
|
+</script>
|
51
|
75
|
|
52
|
76
|
|
53
|
77
|
<style lang="scss" scoped>
|
|
78
|
+.page_newsDetail {
|
|
79
|
+ overflow: hidden;
|
|
80
|
+ height: 100%;
|
|
81
|
+ overflow-y: auto;
|
|
82
|
+ &::-webkit-scrollbar {
|
|
83
|
+ width: 0;
|
|
84
|
+ }
|
|
85
|
+}
|
54
|
86
|
.newsTitle {
|
55
|
87
|
width: 19.9375rem;
|
56
|
88
|
height: 3.75rem;
|