diff --git a/src/components/scBind/index.vue b/src/components/scBind/index.vue
new file mode 100644
index 00000000..4c37f48e
--- /dev/null
+++ b/src/components/scBind/index.vue
@@ -0,0 +1,130 @@
+
+
+
+
+ {{ bindName }}
+
+
+
+
+
+
+
+
+ 绑定
+ 解绑
+
+
+
+
diff --git a/src/scui.js b/src/scui.js
index f77ee3ff..285b8d39 100644
--- a/src/scui.js
+++ b/src/scui.js
@@ -5,6 +5,7 @@ import http from "./utils/request"
import { permission, rolePermission } from './utils/permission'
import scTable from './components/scTable'
+import scBind from './components/scBind'
import scTableColumn from './components/scTable/column.js'
import scFilterBar from './components/scFilterBar'
import scUpload from './components/scUpload'
@@ -45,6 +46,7 @@ export default {
app.config.globalProperties.$ROLE = rolePermission;
//注册全局组件
+ app.component('scBind', scBind);
app.component('scTable', scTable);
app.component('scTableColumn', scTableColumn);
app.component('scFilterBar', scFilterBar);
diff --git a/src/views/am/area.vue b/src/views/am/area.vue
index ccb0b06c..431caca2 100644
--- a/src/views/am/area.vue
+++ b/src/views/am/area.vue
@@ -379,6 +379,7 @@ export default {
handleDel(row) {
this.$API.am.area.delete.req(row.id).then((res) => {
this.$refs.table.refresh();
+ this.refreshArea();
this.$message.success("删除成功");
});
},
@@ -464,6 +465,19 @@ export default {
} else if (mode == "edit") {
this.$refs.table.refresh();
}
+ this.refreshArea();
+ },
+ //更新区域缓存
+ refreshArea(){
+ let that = this;
+ that.$API.am.area.list.req({page_size:999}).then(res => {
+ if (res.err_msg) {
+ } else {
+ let areaList = res.results;
+ that.$TOOL.data.remove("qyjyAreaList");
+ that.$TOOL.data.set("qyjyAreaList", areaList);
+ }
+ })
},
//本地更新数据
handleSaveSuccessAccess(data, mode) {
diff --git a/src/views/am/audio.vue b/src/views/am/audio.vue
index b4bd8813..3162843e 100644
--- a/src/views/am/audio.vue
+++ b/src/views/am/audio.vue
@@ -23,7 +23,7 @@
row-key="id" @selection-change="selectionChange" stripe @resetQuery="resetQuery">
-
+
{{
@@ -31,6 +31,11 @@
}}
+
+
+ {{ scope.row.extra.config.sn }}
+
+
{{ scope.row.extra.ip }}
@@ -97,12 +102,16 @@ export default {
handlePosition(row) {
debugger;
console.log(row)
- this.channelId = row.my_info.id ? row.my_info.id : null;
- this.channelArea = row.my_info.area ? row.my_info.area : '';
- this.channelAreas = row.my_info.areas ? row.my_info.areas : [];
- this.channelLocation = row.my_info.location ? row.my_info.location : {};
- this.channelName = row.name;
- this.dialogSave = true;
+ if(row.my_info.id&&row.my_info.id!==null){
+ this.channelId = row.my_info.id ? row.my_info.id : null;
+ this.channelArea = row.my_info.area ? row.my_info.area : '';
+ this.channelAreas = row.my_info.areas ? row.my_info.areas : [];
+ this.channelLocation = row.my_info.location ? row.my_info.location : {};
+ this.channelName = row.name;
+ this.dialogSave = true;
+ }else{
+ this.$message.error("请先完成设备同步");
+ }
},
//表格选择后回调事件
selectionChange(selection) {
diff --git a/src/views/am/monitor.vue b/src/views/am/monitor.vue
index 6d0b4b05..5af5142f 100644
--- a/src/views/am/monitor.vue
+++ b/src/views/am/monitor.vue
@@ -26,6 +26,7 @@
+
未启用
@@ -81,8 +82,8 @@
-
-
+
+
关闭
@@ -156,6 +157,7 @@ export default {
that.channelCode = row.channelCode;
that.channelName = row.channelName;
that.limitedVisible = true;
+
// that.$API.am.video.item.req(this.params).then((res) => {
// this.url = res.url;
// if (flvjs.isSupported()) {
@@ -176,12 +178,17 @@ export default {
handlePosition(row) {
debugger;
console.log(row)
- this.channelId = row.my_info.id ? row.my_info.id : null;
- this.channelArea = row.my_info.area ? row.my_info.area : '';
- this.channelAreas = row.my_info.areas ? row.my_info.areas : [];
- this.channelLocation = row.my_info.location ? row.my_info.location : {};
- this.channelName = row.channelName;
- this.dialogSave = true;
+ if(row.my_info.id&&row.my_info.id!==null){
+ this.channelId = row.my_info.id ? row.my_info.id : null;
+ this.channelArea = row.my_info.area ? row.my_info.area : '';
+ this.channelAreas = row.my_info.areas ? row.my_info.areas : [];
+ this.channelLocation = row.my_info.location ? row.my_info.location : {};
+ this.channelName = row.channelName;
+ this.dialogSave = true;
+ }else{
+ this.$message.error("请先完成设备同步");
+ }
+
},
//表格选择后回调事件
selectionChange(selection) {
@@ -204,3 +211,9 @@ export default {
},
};
+
diff --git a/src/views/am/vchannel_view.vue b/src/views/am/vchannel_view.vue
index 3e1c7681..0c3cac66 100644
--- a/src/views/am/vchannel_view.vue
+++ b/src/views/am/vchannel_view.vue
@@ -113,6 +113,7 @@ export default {
}
});
window.map.openMapById('0000');
+
window.map.on('loadComplete', e => {
debugger;
console.log(that.channelLocation)
@@ -155,9 +156,9 @@ export default {
console.log(feature.geometry);//type:POINT;coordinates:[114.63028499839209,38.81195080123784,0]
let floorNo = feature.properties.floorNo=='室外'?'Floor1':feature.properties.floorNo;
let floorId = feature.properties.floorId;
- this.form.location = feature.geometry.coordinates;
- this.form.location.push(floorNo);
- this.form.location.push(floorId);
+ that.form.location = feature.geometry.coordinates;
+ that.form.location.push(floorNo);
+ that.form.location.push(floorId);
},
//移除相应点的回调,返回相应点信息
removeCallback: (feature) => {
@@ -173,13 +174,21 @@ export default {
}
});
window.map.addControl(drawTool);
+ let compassControl = new jsmap.JSCompassControl({
+ position: jsmap.JSControlPosition.LEFT_TOP,
+ offset: {
+ x: 50,
+ y: 50
+ }
+ });
+ window.map.addControl(compassControl);
});
},
closeDrawer() {
this.$emit('closed');
},
getArea() {
- this.areasList = that.$TOOL.data.get('qyjyAreaList');
+ this.areasList = this.$TOOL.data.get('qyjyAreaList');
},
//表单提交方法
submit() {
diff --git a/src/views/am/videoView.vue b/src/views/am/videoView.vue
index 3d8979d9..887f9b23 100644
--- a/src/views/am/videoView.vue
+++ b/src/views/am/videoView.vue
@@ -1,6 +1,6 @@
-