| | |
| | | <template> |
| | | <el-container style="height: 100%"> |
| | | <el-container class="video-container" style="height: 100%"> |
| | | <el-aside heigth="100%" width="200px"> |
| | | <department-aside @selectedDepartment="selectedDepartment" /> |
| | | </el-aside> |
| | | |
| | | <el-container> |
| | | <el-container class="video-body-right"> |
| | | <el-header style="display: flex; flex-direction: column; height: 120px"> |
| | | <div |
| | | style="display: flex; justify-content: space-between; height: 80px" |
| | |
| | | " |
| | | >整体趋势</span |
| | | > |
| | | <el-date-picker v-model="value" type="date" placeholder="选择日期"> |
| | | <el-date-picker |
| | | class="video-time-select" |
| | | v-model="value" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | > |
| | | </el-date-picker> |
| | | </div> |
| | | <!-- <div style="height: 60px; display: flex; justify-content: flex-start"> |
| | |
| | | mounted() {}, |
| | | methods: { |
| | | loadVideo(item) { |
| | | if (item.platResourceId) { |
| | | if (item.code || item.platResourceId) { |
| | | if (Hls.isSupported()) { |
| | | var video = document.getElementById(item.id); |
| | | var hls = new Hls(); |
| | | videoPoint.getVideoPointUrl(item.platResourceId).then((res) => { |
| | | if (res.code === 0) { |
| | | hls.loadSource(res.data); |
| | | hls.attachMedia(video); |
| | | // hls.on(Hls.Events.MANIFEST_PARSED, function () { |
| | | // video.play(); |
| | | // document.body.addEventListener( |
| | | // "click", |
| | | // function () { |
| | | // video.play(); |
| | | // }, |
| | | // false |
| | | // ); |
| | | // }); |
| | | setTimeout(() => { |
| | | video.play(); |
| | | }, 2000); |
| | | } |
| | | }); |
| | | videoPoint |
| | | .getVideoPointUrl(item.code || item.platResourceId) |
| | | .then((res) => { |
| | | if (res.code === 0) { |
| | | hls.loadSource(res.data); |
| | | hls.attachMedia(video); |
| | | setTimeout(() => { |
| | | video.play(); |
| | | }, 2000); |
| | | } |
| | | }); |
| | | } |
| | | } else { |
| | | this.$message.error("暂无视频"); |
| | |
| | | if (res) { |
| | | // 连接客户端成功 |
| | | this.ws.login({ |
| | | loginIp: "183.245.159.161", |
| | | loginPort: "8282", |
| | | loginIp: "172.28.194.180", |
| | | loginPort: "7902", |
| | | userName: "suichang", |
| | | userPwd: "a12345677", |
| | | https: 1, |
| | |
| | | }); |
| | | }, |
| | | create(item) { |
| | | if (item.code) { |
| | | if (item.platResourceId && item.code) { |
| | | const DHWsInstance = DHWs.getInstance(); |
| | | this.ws = DHWsInstance; |
| | | console.log(this.ws); |
| | |
| | | }; |
| | | </script> |
| | | <style lang="scss" scoped> |
| | | .video-time-select { |
| | | &::v-deep .el-input__prefix { |
| | | height: auto; |
| | | } |
| | | } |
| | | .video-body-right { |
| | | padding: 10px; |
| | | border: 1px solid #ccc; |
| | | margin-left: 5px; |
| | | } |
| | | .button-one { |
| | | height: 40px; |
| | | width: 80px; |
| | | margin-left: 20px; |
| | | padding: 0; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | color: rgb(75, 155, 183); |
| | | border: 1px solid rgb(75, 155, 183); |
| | | } |
| | |
| | | height: 40px; |
| | | width: 80px; |
| | | padding: 0; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | color: rgb(75, 155, 183); |
| | | border: 1px solid rgb(75, 155, 183); |
| | | } |
| | |
| | | height: 40px; |
| | | width: 80px; |
| | | padding: 0; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | color: rgb(75, 155, 183); |
| | | border: 1px solid rgb(75, 155, 183); |
| | | } |
| | |
| | | } |
| | | |
| | | ::v-deep .el-header { |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | color: #000; |
| | | line-height: 60px; |
| | | } |
| | | |
| | | ::v-deep .el-aside { |
| | | background-color: #09152f; |
| | | } |
| | | // ::v-deep .el-aside { |
| | | // background-color: #09152f; |
| | | // } |
| | | |
| | | ::v-deep .el-menu { |
| | | background-color: #09152f; |
| | | } |
| | | // ::v-deep .el-menu { |
| | | // background-color: #09152f; |
| | | // } |
| | | |
| | | ::v-deep .el-main, |
| | | ::v-deep .el-footer { |
| | | background-color: #09152f; |
| | | } |
| | | // ::v-deep .el-footer { |
| | | // background-color: #09152f; |
| | | // } |
| | | |
| | | ::v-deep .el-tree-node__label { |
| | | line-height: 30px; |
| | |
| | | video::-webkit-media-controls-toggle-closed-captions-button { |
| | | display: none; |
| | | } |
| | | </style> |
| | | </style> |