Commit b8909ea9a64dce9bc89bf815d01780c32da5f13a

Authored by zhiyangdu
1 parent a11bf9fb

init

src/App.vue
@@ -24,21 +24,4 @@ @@ -24,21 +24,4 @@
24 background-color: transparent !important; 24 background-color: transparent !important;
25 } 25 }
26 } 26 }
27 - /*设置不同的视频封面*/  
28 - .video1_poster{  
29 - .vjs-poster{  
30 - width: 100%;  
31 - height:401px;  
32 - background-image: url("../static/img/index/video1.png") !important;  
33 - background-size: 100%;  
34 - }  
35 - }  
36 - .video2_poster{  
37 - .vjs-poster{  
38 - width: 100%;  
39 - height:401px;  
40 - background-image: url("../static/img/index/video2.png") !important;  
41 - background-size: 100%;  
42 - }  
43 - }  
44 </style> 27 </style>
src/pages/index/index.less
@@ -138,4 +138,22 @@ @@ -138,4 +138,22 @@
138 margin-top: 0; 138 margin-top: 0;
139 } 139 }
140 } 140 }
  141 + /*设置不同的视频封面*/
  142 + .video1_poster{
  143 + .vjs-poster{
  144 + width: 100%;
  145 + height:401px;
  146 + background-image: url("https://wjj.ys2.cnliveimg.com/769/shop/img/2019/12/30/5e0956907e4d7.png") !important;
  147 + background-size: 100%;
  148 + }
  149 + }
  150 + .video2_poster{
  151 + .vjs-poster{
  152 + width: 100%;
  153 + height:401px;
  154 + background-image: url("https://wjj.ys2.cnliveimg.com/769/shop/img/2019/12/30/5e095690ae715.png") !important;
  155 + background-size: 100%;
  156 + }
  157 + }
  158 +
141 } 159 }
src/pages/index/index.vue
@@ -121,19 +121,19 @@ @@ -121,19 +121,19 @@
121 * @param {object} $event [播放器对象] 121 * @param {object} $event [播放器对象]
122 */ 122 */
123 onPlayerPlay($event) { 123 onPlayerPlay($event) {
124 - if(this.isiPhone.value && window.webkit && window.webkit.messageHandlers && window.webkit.messageHandlers.CNDSPlayer) {  
125 - window.webkit.messageHandlers.CNDSPlayer.postMessage({body: {  
126 - playUrl:"https://v.youku.com/v_show/id_XNDQyOTAxNjE2MA==.html?s=e438e14b3fa94613a1bb&scm=20140719.manual.15319.show_e438e14b3fa94613a1bb",  
127 -// playUrl: this.playerOptions.sources[0].src, // 视频URL  
128 - isLive: 0 // 0录播1直播  
129 - }});  
130 - } 124 +// if(this.isiPhone.value && window.webkit && window.webkit.messageHandlers && window.webkit.messageHandlers.CNDSPlayer) {
  125 +// window.webkit.messageHandlers.CNDSPlayer.postMessage({body: {
  126 +// playUrl:"https://v.youku.com/v_show/id_XNDQyOTAxNjE2MA==.html?s=e438e14b3fa94613a1bb&scm=20140719.manual.15319.show_e438e14b3fa94613a1bb",
  127 +//// playUrl: this.playerOptions.sources[0].src, // 视频URL
  128 +// isLive: 0 // 0录播1直播
  129 +// }});
  130 +// }
131 }, 131 },
132 } 132 }
133 } 133 }
134 </script> 134 </script>
135 135
136 <!-- Add "scoped" attribute to limit CSS to this component only --> 136 <!-- Add "scoped" attribute to limit CSS to this component only -->
137 -<style rel="stylesheet/less" lang="less" scoped> 137 +<style rel="stylesheet/less" lang="less">
138 @import "index"; 138 @import "index";
139 </style> 139 </style>