fangq hace 4 años
padre
commit
fed2e74b52

+ 20 - 0
src/api/device/videoclouddevice.js

@@ -127,3 +127,23 @@ export const sync = (row) => {
   })
 }
 
+
+export const updateVideoDevice = (row) => {
+  return request({
+    url: '/api/cyzh-smart-device/videoclouddevice/update',
+    method: 'post',
+    data: row
+  })
+}
+
+export const bindResidentialBatch = (deviceIds,residentialId,buildingId) => {
+  return request({
+    url: '/api/cyzh-smart-device/videoclouddevice/bindResidentialBatch',
+    method: 'post',
+    params: {
+      deviceIds,
+      residentialId,
+      buildingId
+    }
+  })
+}

+ 10 - 0
src/api/person/basicinfo.js

@@ -32,6 +32,16 @@ export const remove = (ids) => {
   })
 }
 
+export const delFace = (ids) => {
+  return request({
+    url: '/api/cyzh-person/houseuser/delFace',
+    method: 'post',
+    params: {
+      ids,
+    }
+  })
+}
+
 export const add = (row) => {
   return request({
     url: '/api/cyzh-person/houseuser/submit',

+ 0 - 2
src/views/device/elevatoralarm.vue

@@ -241,7 +241,6 @@ export default {
       stopPlay(this.player);
     },
     getAlarmVideoData(row){
-      debugger
       let alarmCode = row.alarmCode;
       this.videoAlarmName = row.$alarmType;
       this.videoAlarmVisible = true;
@@ -254,7 +253,6 @@ export default {
 
     },
     videoDetail(videoUrl){
-
       let elementId = 'videoAlarm';
       this.player = startPlay(elementId, videoUrl, this.player);
     },

+ 23 - 91
src/views/device/videoclouddevice.vue

@@ -52,7 +52,6 @@
                width="50%">
       <div style="text-align: center;">
         <avue-form v-model="bindBatchForm" :option="bindOption" @submit="bindBatchDevice">
-
         </avue-form>
         <!-- <el-select v-model="selectValue" filterable placeholder="请选择">
           <el-option v-for="item in residentialList" :key="item.id" :label="item.name" :value="item.id">
@@ -143,6 +142,7 @@ export default {
           label: "设备编号",
           prop: "deviceId",
           hide: true,
+          disabled: true,
           addDisplay:false,
           editDisplay:false,
           span: 12,
@@ -178,6 +178,7 @@ export default {
             prop: "devicePassword",
             span: 12,
             hide: true,
+            display: false,
             rules: [{
               required: true,
               message: "请输入设备密码",
@@ -207,6 +208,7 @@ export default {
             prop: "modelSequence",
             span: 12,
             hide: true,
+            display: false,
             rules: [{
               required: true,
               message: "请输入型号",
@@ -219,6 +221,7 @@ export default {
             prop: "protocolType",
             span: 12,
             hide: true,
+            display: false,
             rules: [{
               required: true,
               message: "请输入协议类型(1:GB28181,2:ONVIF)",
@@ -232,6 +235,7 @@ export default {
             dataType: "number",
             type: "select",
             search: true,
+            display: false,
             dicData:[
               {
                 label:'在线',
@@ -258,6 +262,7 @@ export default {
             label: "是否支持云存储",
             prop: "isSupportCloudStorage",
             span: 12,
+            disabled: true,
             hide: true,
             type:'select',
             dicData:[
@@ -282,6 +287,7 @@ export default {
             prop: "isSupportLocalStorage",
             type:'select',
             span: 12,
+            disabled: true,
             hide: true,
             dicData:[
               {
@@ -304,6 +310,7 @@ export default {
             prop: "isSupportPtz",
             span: 12,
             dataType: "number",
+            disabled: true,
             type: "select",
             dicData:[
               {
@@ -333,6 +340,7 @@ export default {
             span: 12,
             hide: true,
             type:'select',
+            disabled: true,
             dicData:[
               {
                 label:'支持',
@@ -356,6 +364,7 @@ export default {
             span: 12,
             hide: true,
             type:'select',
+            disabled: true,
             dicData:[
               {
                 label:'支持',
@@ -379,6 +388,7 @@ export default {
             span: 12,
             hide: true,
             type:"select",
+            disabled: true,
             dicData:[
               {
                 label:'支持',
@@ -402,6 +412,7 @@ export default {
             span: 12,
             hide: true,
             type:'select',
+            disabled: true,
             dicData:[
               {
                 label:'支持',
@@ -423,6 +434,7 @@ export default {
             prop: "cloudStorageType",
             span: 12,
             type: "select",
+            disabled: true,
             dataType: "number",
             dicUrl: "/api/blade-system/dict-biz/dictionary?code=cloud_storage_type",
             props: {
@@ -440,6 +452,7 @@ export default {
             prop: "cloudStorageConfId",
             span: 12,
             hide: true,
+            disabled: true,
             rules: [{
               required: true,
               message: "请输入云存储配置id",
@@ -453,6 +466,7 @@ export default {
             span: 12,
             hide: true,
             type:'select',
+            disabled: true,
             dicData:[
               {
                 label:'主动推流',
@@ -521,6 +535,7 @@ export default {
             span: 12,
             hide: true,
             type:'select',
+            disabled: true,
             dicData:[
               {
                 label:'正常',
@@ -576,6 +591,7 @@ export default {
             span: 12,
             hide: true,
             type:'select',
+            disabled: true,
             dicData:[
               {
                 label:'封存',
@@ -608,6 +624,7 @@ export default {
             prop: "routeId",
             span: 12,
             hide: true,
+            disabled: true,
             rules: [{
               required: true,
               message: "请输入路由器id",
@@ -619,7 +636,8 @@ export default {
             label: "摄像头类型",
             prop: "equipType",
             span: 12,
-            hide: true,
+            disabled: true,
+              hide: true,
             type:'select',
             dicData:[
               {
@@ -642,6 +660,7 @@ export default {
             prop: "updateStateTimeString",
             span: 12,
             hide: true,
+            disabled: true,
             rules: [{
               required: true,
               message: "请输入设备最后状态更新时间",
@@ -700,6 +719,7 @@ export default {
             prop: "accountName",
             span: 12,
             hide: true,
+
             rules: [{
               required: true,
               message: "请输入所属账户",
@@ -708,70 +728,6 @@ export default {
           },
         ]
       },
-      bindOption: {
-        column: [
-          //   {
-          //   label: "所属小区",
-          //   prop: "residentialId",
-          //   search: true,
-          //   span:24,
-          //   cascaderItem: ['buildingId'],
-          //   type: "select",
-          //   remote: true,
-          //   // dicUrl: "/api/cyzh-community/residential/list?name={{key}}",
-          //   dicUrl: "/api/cyzh-community/residential/list?size=10000",
-          //   props: {
-          //     label: "name",
-          //     value: "id"
-          //   },
-          //   rules: [{
-          //     required: true,
-          //     message: "请选择所属小区",
-          //     trigger: "blur"
-          //   }]
-          // },
-          {
-            label: "所属小区",
-            prop: "residentialId",
-            type: "select",
-            search: true,
-            span:24,
-            cascaderItem: ['buildingId'],
-            dicUrl: "/api/cyzh-community/residential/list?size=9999",
-            dicFormatter:(res)=>{
-              return res.data.records;//返回字典的层级结构
-            },
-            props: {
-              label: "name",
-              value: "id"
-            },
-            rules: [{
-              required: true,
-              message: "请选择所属小区",
-              trigger: "blur"
-            }]
-          },
-          {
-            label: "所属楼栋",
-            prop: "buildingId",
-            search: true,
-            type: "select",
-            span:24,
-            cascaderIndex: 0,
-            // dicFlag: true,
-            dicUrl: "/api/cyzh-community/building/list?residentialId={{key}}",
-            dicFormatter:(res) => {
-              return res.data.records;//返回字典层级结构
-            },
-            filterable: true,
-            props: {
-              label: "name",
-              value: "id"
-            },
-          }]
-      },
-
-
       option1:{
         menu: true,
         height: 'auto',
@@ -1358,32 +1314,13 @@ export default {
       },
       bindOption: {
         column: [
-          //   {
-          //   label: "所属小区",
-          //   prop: "residentialId",
-          //   search: true,
-          //   span:24,
-          //   cascaderItem: ['buildingId'],
-          //   type: "select",
-          //   remote: true,
-          //   // dicUrl: "/api/cyzh-community/residential/list?name={{key}}",
-          //   dicUrl: "/api/cyzh-community/residential/list?size=10000",
-          //   props: {
-          //     label: "name",
-          //     value: "id"
-          //   },
-          //   rules: [{
-          //     required: true,
-          //     message: "请选择所属小区",
-          //     trigger: "blur"
-          //   }]
-          // },
           {
             label: "所属小区",
             prop: "residentialId",
             type: "select",
             search: true,
             span:24,
+            filterable: true,
             cascaderItem: ['buildingId'],
             dicUrl: "/api/cyzh-community/residential/list?size=9999",
             dicFormatter:(res)=>{
@@ -1473,7 +1410,6 @@ export default {
       if (this.residentialList.length == 0) {
         //  请求获取小区列表
         getAllList().then(res => {
-          console.log(res.data.data);
           this.residentialList = res.data.data;
           this.selectValue = "";
           this.bindBatchVisible = true;
@@ -1505,9 +1441,7 @@ export default {
       //   return;
       // }
       //保存
-      // debugger
       bindResidentialBatch(this.ids, this.bindBatchForm.residentialId,this.bindBatchForm.buildingId).then(() => {
-        // debugger
         this.bindBatchVisible = false;
         this.bindBatchForm = {};
         this.onLoad(this.page);
@@ -1637,12 +1571,10 @@ export default {
       this.onLoad(this.page, this.query);
     },
     edit(row) {
-      console.log(row,"编辑数据")
       this.editForm = row;
       this.editVisiable = true;
     },
     view(row) {
-      console.log(row,"详情数据")
       this.detailForm = row;
       this.detailVisible = true;
     },

+ 1 - 83
src/views/device/videodevice/videocloud/videoclouddevice.vue

@@ -713,69 +713,6 @@ export default {
           },
         ]
       },
-      bindOption: {
-        column: [
-          //   {
-          //   label: "所属小区",
-          //   prop: "residentialId",
-          //   search: true,
-          //   span:24,
-          //   cascaderItem: ['buildingId'],
-          //   type: "select",
-          //   remote: true,
-          //   // dicUrl: "/api/cyzh-community/residential/list?name={{key}}",
-          //   dicUrl: "/api/cyzh-community/residential/list?size=10000",
-          //   props: {
-          //     label: "name",
-          //     value: "id"
-          //   },
-          //   rules: [{
-          //     required: true,
-          //     message: "请选择所属小区",
-          //     trigger: "blur"
-          //   }]
-          // },
-          {
-            label: "所属小区",
-            prop: "residentialId",
-            type: "select",
-            search: true,
-            span:24,
-            cascaderItem: ['buildingId'],
-            dicUrl: "/api/cyzh-community/residential/list?size=9999",
-            dicFormatter:(res)=>{
-              return res.data.records;//返回字典的层级结构
-            },
-            props: {
-              label: "name",
-              value: "id"
-            },
-            rules: [{
-              required: true,
-              message: "请选择所属小区",
-              trigger: "blur"
-            }]
-          },
-          {
-            label: "所属楼栋",
-            prop: "buildingId",
-            search: true,
-            type: "select",
-            span:24,
-            cascaderIndex: 0,
-            // dicFlag: true,
-            dicUrl: "/api/cyzh-community/building/list?residentialId={{key}}",
-            dicFormatter:(res) => {
-              return res.data.records;//返回字典层级结构
-            },
-            filterable: true,
-            props: {
-              label: "name",
-              value: "id"
-            },
-          }]
-      },
-
       option1:{
         menu: true,
         height: 'auto',
@@ -1363,31 +1300,12 @@ export default {
       },
       bindOption: {
         column: [
-          //   {
-          //   label: "所属小区",
-          //   prop: "residentialId",
-          //   search: true,
-          //   span:24,
-          //   cascaderItem: ['buildingId'],
-          //   type: "select",
-          //   remote: true,
-          //   // dicUrl: "/api/cyzh-community/residential/list?name={{key}}",
-          //   dicUrl: "/api/cyzh-community/residential/list?size=10000",
-          //   props: {
-          //     label: "name",
-          //     value: "id"
-          //   },
-          //   rules: [{
-          //     required: true,
-          //     message: "请选择所属小区",
-          //     trigger: "blur"
-          //   }]
-          // },
           {
             label: "所属小区",
             prop: "residentialId",
             type: "select",
             search: true,
+            filterable: true,
             span:24,
             cascaderItem: ['buildingId'],
             dicUrl: "/api/cyzh-community/residential/list?size=9999",

+ 34 - 20
src/views/person/basicinfo.vue

@@ -26,6 +26,13 @@
                    v-if="permission.basicinfo_delete"
                    @click="handleDelete">删 除
         </el-button>
+        <el-button type="warning"
+                   size="small"
+                   icon="el-icon-delete"
+                   plain
+                   v-if="permission.basicinfo_delete"
+                   @click="handleDelFace">人脸删除
+        </el-button>
       </template>
       <!--      <template slot="buildingId" slot-scope="scope">-->
       <!--        <span v-if="scope.row.buildingId!==-1">-->
@@ -217,12 +224,6 @@
                 trigger: "blur"
               }]
             },
-            { //列表是展示
-              label: "所属社区",
-              prop: "agencyName",
-              addDisplay: false,
-              editDisplay: false,
-            },
             {
               label: "所属社区",
               prop: "agencyId",
@@ -230,8 +231,7 @@
               cascaderItem: ['residentialId'],
               type: "select",
               // remote: true,
-              // dicData: [],
-              dicUrl: "/api/cyzh-community/agency/list?size=500",
+              dicUrl: "/api/cyzh-community/agency/list?size=9999",
               dicFormatter:(res)=>{
                 return res.data.records;//返回字典的层级结构
               },
@@ -243,28 +243,21 @@
                 required: true,
                 message: "请选择所属社区",
                 trigger: "blur"
-              }],
-              hide: true,
-              viewDisplay: false
-            },
-            {
-              label: "所属小区",
-              prop: "residentialName",
-              addDisplay: false,
-              editDisplay: false,
+              }]
             },
             {
               label: "所属小区",
               prop: "residentialId",
-              dataType:'number',
               type: "select",
               search: true,
+              searchFilterable: true,
               cascaderItem: ['buildingId'],
-              dicUrl: "/api/cyzh-community/residential/list?agencyId={{key}}&size=500",
+              dicUrl: "/api/cyzh-community/residential/list?agencyId={{key}}",
               dicFormatter:(res)=>{
                 return res.data.records;//返回字典的层级结构
               },
-              // filterable: true,
+              // dicFlag: false,
+              filterable: true,
               props: {
                 label: "name",
                 value: "id"
@@ -755,6 +748,27 @@
             });
           });
       },
+      handleDelFace(row) {
+        if (this.selectionList.length === 0) {
+          this.$message.warning("请选择至少一条数据");
+          return;
+        }
+        this.$confirm("确定要删除选择的人脸?", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+          .then(() => {
+            return delFace(this.ids);
+          })
+          .then(() => {
+            this.onLoad(this.page);
+            this.$message({
+              type: "success",
+              message: "操作成功!"
+            });
+          });
+      },
       handleDelete() {
         if (this.selectionList.length === 0) {
           this.$message.warning("请选择至少一条数据");

+ 2 - 2
vue.config.js

@@ -27,8 +27,8 @@ module.exports = {
     proxy: {
       '/api': {
         //本地服务接口地址
-        // target: 'http://localhost',
-        target: 'http://36.103.227.152:1777/api',
+        target: 'http://localhost',
+        // target: 'http://36.103.227.152:1777/api',
         ws: true,
         pathRewrite: {
           '^/api': '/'