| | |
| | | |
| | | <template slot-scope="{ type, size, row }" slot="menu"> |
| | | <el-button |
| | | icon="el-icon-check" |
| | | icon="el-icon-s-order" |
| | | :size="size" |
| | | :type="type" |
| | | @click.stop="handleHistory(row)" |
| | | >历史</el-button |
| | | > |
| | | <el-button |
| | | icon="el-icon-check" |
| | | icon="el-icon-video-camera-solid" |
| | | :size="size" |
| | | :type="type" |
| | | @click.stop="handleStart(row)" |
| | | >视频</el-button |
| | | > |
| | | <el-button |
| | | icon="el-icon-check" |
| | | icon="el-icon-edit" |
| | | :size="size" |
| | | :type="type" |
| | | @click.stop="handleManage(row)" |
| | | >处置</el-button |
| | | > |
| | | <el-button |
| | | icon="el-icon-check" |
| | | icon="el-icon-location-outline" |
| | | :size="size" |
| | | :type="type" |
| | | @click.stop="handleMap(row)" |
| | |
| | | title="警情处置" |
| | | :visible.sync="dialogTableVisible" |
| | | append-to-body="true" |
| | | @close="innerVisibleVideo = false" |
| | | > |
| | | <el-dialog |
| | | class="old-video-dialog" |
| | |
| | | :visible.sync="innerVisibleVideo" |
| | | :close-on-press-escape="false" |
| | | append-to-body |
| | | @opened="openOldVideoBox()" |
| | | @opened="openOldVideoBox" |
| | | @close="closeOldVideoBox" |
| | | > |
| | | <video |
| | |
| | | </el-form> |
| | | </el-dialog> |
| | | |
| | | <<<<<<< HEAD |
| | | <el-drawer |
| | | title="电子地图" |
| | | append-to-body="true" |
| | |
| | | width="100%" |
| | | height="100%" |
| | | ></iframe> |
| | | ======= |
| | | <el-drawer title="电子地图" append-to-body="true" :visible.sync="showMap"> |
| | | <iframe :src="mapUrl" frameborder="0" width="100%" height="100%"></iframe> |
| | | >>>>>>> cb724c3b33fc850771b87c3c6feaa582addac56a |
| | | </el-drawer> |
| | | </basic-container> |
| | | </template> |
| | |
| | | data() { |
| | | return { |
| | | showMap: false, |
| | | <<<<<<< HEAD |
| | | ======= |
| | | mapUrl: "https://s16s652780.51mypc.cn/jfpt/map/index.html", |
| | | >>>>>>> cb724c3b33fc850771b87c3c6feaa582addac56a |
| | | hls: "", |
| | | videoSource: "", |
| | | dialogTableVisible: false, |
| | |
| | | indexLabel: "序号", |
| | | calcHeight: 30, |
| | | labelWidth: "100", |
| | | menuWidth: 300, |
| | | size:"mini", |
| | | menuWidth: 240, |
| | | dialogWidth: 950, |
| | | tip: false, |
| | | searchShow: true, |
| | |
| | | border: true, |
| | | index: true, |
| | | viewBtn: true, |
| | | selection: true, |
| | | selection: false, |
| | | dialogClickModal: false, |
| | | column: [ |
| | | { |
| | |
| | | ] |
| | | }, |
| | | { |
| | | label: "行政区", |
| | | label: "省份", |
| | | prop: "province", |
| | | search: true, |
| | | searchSpan: 3, |
| | | searchLabelWidth: 60, |
| | | placeholder: "行政区", |
| | | placeholder: "省份", |
| | | type: "select", |
| | | props: { |
| | | label: "name", |
| | |
| | | permissionList() { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.real_add, false), |
| | | viewBtn: this.vaildData(this.permission.real_view, false), |
| | | viewBtn: this.vaildData(null, false), |
| | | delBtn: this.vaildData(this.permission.real_delete, false), |
| | | editBtn: this.vaildData(this.permission.real_edit, false) |
| | | }; |
| | |
| | | ...this.query |
| | | }; |
| | | values.releaseTimeRange = null; |
| | | }else{ |
| | | values = { |
| | | ...params, |
| | | ...this.query |
| | | }; |
| | | } |
| | | this.loading = true; |
| | | getList(page.currentPage, page.pageSize, values).then(res => { |
| | | const data = res.data.data; |
| | | this.page.total = data.total; |
| | | |
| | | data.records.sort((a,b)=>{ |
| | | return a.jtype - b.jtype; |
| | | }); |
| | | |
| | | this.data = data.records; |
| | | this.loading = false; |
| | | this.selectionClear(); |
| | |
| | | }; |
| | | } else { |
| | | return { |
| | | color: "#ff7627" |
| | | color: "#ff2727" |
| | | }; |
| | | } |
| | | }, |
| | |
| | | } else { |
| | | axios({ |
| | | url: |
| | | "http://192.168.0.102:1888/api/blade-jfpts/jingdan/jingdan/submit", |
| | | "https://s16s652780.51mypc.cn/api/blade-jfpts/jingdan/jingdan/submit", |
| | | method: "post", |
| | | data: { |
| | | rName: row.rname, |
| | |
| | | var that = this; |
| | | axios({ |
| | | url: |
| | | "http://192.168.0.102:1888/api/blade-jfpts/alarm/alarm/deletejj?id=" + |
| | | "https://s16s652780.51mypc.cn/api/blade-jfpts/alarm/alarm/deletejj?id=" + |
| | | row.id, |
| | | method: "post" |
| | | }).then(function() { |
| | |
| | | var that = this; |
| | | axios({ |
| | | url: |
| | | "http://192.168.0.102:1888/api/blade-jfpts/alarm/alarm/updateJtype?id=" + |
| | | "https://s16s652780.51mypc.cn/api/blade-jfpts/alarm/alarm/updateJtype?id=" + |
| | | row.id + |
| | | "&czTime=" + |
| | | row.czTime + |
| | |
| | | }; |
| | | }, |
| | | queryOldVideo(data) { |
| | | console.log(data); |
| | | var newAxios = axios.create({ |
| | | baseURL: "https://s16s652780.51mypc.cn", |
| | | withCredentials: false, |
| | |
| | | } |
| | | ) |
| | | .then(res => { |
| | | console.log(res.data.data.accessToken); |
| | | |
| | | newAxios |
| | | .get( |
| | | `/GetPlayUrl?deviceCode=${data.channelNumber}&chl=${data.serialNumber}` |
| | |
| | | |
| | | this.hls = new Hls(); |
| | | |
| | | console.log(this.videoSource, "19028321321r073"); |
| | | |
| | | var m3u8Url = decodeURIComponent(this.videoSource); |
| | | |
| | | console.log(m3u8Url); |
| | | |
| | | this.hls.loadSource(m3u8Url); |
| | | |
| | |
| | | if (dom.getAttribute("src") != "") { |
| | | dom.pause(); |
| | | |
| | | dom.setAttribute(""); |
| | | dom.setAttribute("src", ""); |
| | | |
| | | this.hls.destroy(); |
| | | } |
| | | }, |
| | | aKeyToCall(e, form) { |
| | | var newAxios = axios.create({ |
| | | var newCallAxios = axios.create({ |
| | | baseURL: "https://s16s652780.51mypc.cn", |
| | | withCredentials: false, |
| | | headers: { |
| | |
| | | if (this.isActive == true) { |
| | | this.isActive = false; |
| | | |
| | | newAxios |
| | | newCallAxios |
| | | .post( |
| | | `/api_control`, |
| | | {}, |
| | |
| | | } |
| | | ) |
| | | .then(result => { |
| | | console.log(result, 11111111); |
| | | var formData = new FormData(); |
| | | var blob = this.recorder.getPCMBlob() //获取wav格式音频数据 |
| | | var blob = this.recorder.getPCMBlob(); //获取pcm格式音频数据 |
| | | //此处获取到blob对象后需要设置fileName满足当前项目上传需求,其它项目可直接传把blob作为file塞入formData |
| | | var newbolb = new Blob([blob], { type: "audio/pcm" }); |
| | | var fileOfBlob = new File([newbolb], new Date().getTime() + ".pcm"); |
| | | formData.append("file", fileOfBlob); |
| | | |
| | | console.log(blob, newbolb, fileOfBlob, 99999); |
| | | document |
| | | .getElementById("real_audio") |
| | | .setAttribute("src", URL.createObjectURL(blob)); |
| | | |
| | | newAxios |
| | | .post(`/api_control`, formData, { |
| | | console.log( |
| | | blob, |
| | | newbolb, |
| | | fileOfBlob, |
| | | window.URL.createObjectURL(blob), |
| | | 99999 |
| | | ); |
| | | |
| | | this.recorder.play(); |
| | | |
| | | newCallAxios |
| | | .post(`/api_control`, blob, { |
| | | params: { |
| | | param: { |
| | | PktType: "Talk", |
| | |
| | | } |
| | | } |
| | | }) |
| | | .then(result => { |
| | | console.log(result); |
| | | }); |
| | | .then(result => {}); |
| | | }); |
| | | } else { |
| | | this.isActive = true; |
| | | |
| | | Recorder.getPermission().then( |
| | | () => { |
| | | console.log("给权限了"); |
| | | |
| | | this.recorder.start().then( |
| | | () => { |
| | | // 开始录音 |
| | | console.log("开始录音了"); |
| | | }, |
| | | error => { |
| | | // 出错了 |
| | | console.log(`${error.name} : ${error.message}`); |
| | | } |
| | | ); |
| | | }, |
| | | error => { |
| | | console.log(`${error.name} : ${error.message}`); |
| | | } |
| | | ); |
| | | |
| | | var newAxios = axios.create({ |
| | | baseURL: "https://s16s652780.51mypc.cn", |
| | | withCredentials: false, |
| | | headers: { |
| | | "Content-Type": "application/json;" |
| | | } |
| | | }); |
| | | |
| | | newAxios |
| | | .post(`/talk?deviceCode=${form.channelNumber}`, "12345") |
| | | .then(result => { |
| | | console.log(result); |
| | | Recorder.getPermission().then(() => { |
| | | this.recorder.start().then(() => { |
| | | // 开始录音 |
| | | }); |
| | | }); |
| | | } |
| | | } |
| | | } |