Lita-Tako hai 4 meses
pai
achega
546700ccf6
Modificáronse 1 ficheiros con 6 adicións e 4 borrados
  1. 6 4
      src/components/common/player/playback_v2.vue

+ 6 - 4
src/components/common/player/playback_v2.vue

@@ -200,8 +200,10 @@ export default {
200 200
       this.getPlaybackVideo(n.cameraIndexCode).then(resp => {
201 201
         const {url} = resp
202 202
         if(url) {
203
-          const { startTime, endTime } = this.date
204
-          this.player.JS_Play(url, { playURL: url, mode: this.mode }, 0, startTime, endTime).then(
203
+          const [realUrl, params] = url.split('?')
204
+          const [ startTime, endTime ] = this.date
205
+          console.log('实际播放的 url', realUrl)
206
+          this.player.JS_Play(realUrl, { playURL: realUrl, mode: this.mode }, 0, startTime, endTime).then(
205 207
             () => {
206 208
               console.log('playbackStart success')
207 209
             },
@@ -216,7 +218,7 @@ export default {
216 218
     getPlaybackVideo(cameraIndexCode) {
217 219
       const [beginTime, endTime] = this.date
218 220
       return getPlayback({
219
-        beginTime, endTime, cameraIndexCode, recordLocation: 1, protocol: 'WSS'
221
+        beginTime, endTime, cameraIndexCode, recordLocation: 1, protocol: 'wss'
220 222
       })
221 223
     },
222 224
 
@@ -283,7 +285,7 @@ export default {
283 285
     <div class="control-box">
284 286
       <el-tabs v-model="activeName" type="card">
285 287
         <el-tab-pane label="摄像头列表" name="cameraList" style="margin: 5px 5px 5px 5px;">
286
-          回放日期: <el-date-picker type="datetimerange" value-format="yyyy-MM-ddTHH:mm:ssZ" v-model="date" style="margin-top: 5px;"/>
288
+          回放日期: <el-date-picker type="datetimerange" value-format="yyyy-MM-ddTHH:mm:ss.000+08:00" v-model="date" style="margin-top: 5px;"/>
287 289
           <el-tree :data="cameraListData" :props="{children: 'children', label: 'label'}" @node-click="onTreeNodeClick" style="margin-top: 10px" />
288 290
         </el-tab-pane>
289 291
         <el-tab-pane label="操作" name="options" style="margin: 5px 5px 5px 5px;">