浏览代码

门禁问题

Shannon_mu 3 年之前
父节点
当前提交
276fe6129a

+ 10 - 2
accessControlSystem/src/views/deviceManagement/accessControlMachineManagement/index.vue

@@ -160,7 +160,8 @@ export default {
             ],
             thisLeftData: {},
             selectRow: [],
-            mixins_post: 'get'
+            mixins_post: 'get',
+            productOptions:{}
         };
     },
     methods: {
@@ -302,7 +303,8 @@ export default {
                     height: '500px',
                     props: {
                         callback: resolve,
-                        row
+                        row,
+                        productOptions:this.productOptions
                     },
                     hideStar: false,
                     title: '门禁机替换'
@@ -327,6 +329,11 @@ export default {
             }).then(() => {
                 this.mixins_search();
             });
+        },
+        getProductOptions() {
+            this.$http.postForm('/sc-community/devicetype/selectList', { name: '' }).then((data) => {
+                this.productOptions = data;
+            });
         }
     },
     watch: {
@@ -342,6 +349,7 @@ export default {
         this.mixins_dataUrl = '/sc-gate-web/gate/page'; // 分页查询接口
         this.mixins_query = {};
         this.mixins_search();
+        this.getProductOptions()
     }
 };
 </script>

+ 13 - 10
accessControlSystem/src/views/deviceManagement/accessControlMachineManagement/popups/replaceDevice.vue

@@ -136,12 +136,6 @@ export default {
                 }
             });
         },
-        getProductOptions(resolve) {
-            this.$http.postForm('/sc-community/devicetype/selectList', { name: '' }).then((data) => {
-                this.productOptions = data;
-                resolve && resolve();
-            });
-        },
         inFormValue(thisObj, obj) {
             for (let val in thisObj) {
                 thisObj[val] = obj[val] || '';
@@ -160,14 +154,23 @@ export default {
             this.$refs.uploaduserlogo.clearFiles();
         },
         fiterLabel() {
-            let arr = this.$refs.deviceText.getCheckedNodes()[0].pathLabels;
-            this.showText.deviceTypeText = arr.join('/');
+            try {
+                let arr = this.$refs.deviceText.getCheckedNodes()[0].pathLabels;
+                this.showText.deviceTypeText = arr.join('/');
+            } catch {}
+        },
+        getDe(resolve, id) {
+            this.$http.get(' /sc-gate-web/gate/find/' + id).then(({ data, msg, status }) => {
+                console.log(data);
+                this.showText.deviceType = !!data.deviceType ? [null, null, data.deviceType + ''] : '';
+                resolve && resolve();
+            });
         }
     },
     created() {
         new Promise((resolve) => {
-            this.showText.deviceType = !!this.params.row.deviceType ? [null, null, this.params.row.deviceType + ''] : '';
-            this.getProductOptions(resolve);
+            this.productOptions = this.params.productOptions;
+            this.getDe(resolve, this.params.row.id);
         }).then((res) => {
             this.fiterLabel();
             this.showText.deviceNo = this.params.row.deviceNo || '';

+ 7 - 0
accessControlSystem/src/views/deviceManagement/accessControlMachineManagement/popups/temporaryPassword.vue

@@ -53,6 +53,12 @@ export default {
                 if (valid) {
                     var loading = this.$loading();
                     let installData = JSON.parse(JSON.stringify(this.formData));
+                    if (this.tempPasswordStatus == 0) {
+                        delete installData.tempPassword;
+                        delete installData.expirationTime;
+                    } else if (this.tempPasswordStatus == 1) {
+                        delete installData.tempPassword;
+                    }
                     this.$http
                         .post('/sc-gate-web/gate/tempPassword', installData)
                         .then(({ status, msg }) => {
@@ -90,6 +96,7 @@ export default {
     created() {
         this.formData.expirationTime = this.params.row.expirationTime || '';
         this.formData.tempPassword = this.params.row.tempPassword || '';
+        this.formData.tempPasswordStatus = this.params.row.tempPasswordStatus || '';
         this.formData.id = this.params.row.id || '';
     }
 };

+ 1 - 1
accessControlSystem/src/views/deviceManagement/distributionRecord/index.vue

@@ -93,7 +93,7 @@ export default {
             cols: [
                 {
                     label: '门禁卡号',
-                    prop: 'cardId'
+                    prop: 'doorCardNo'
                 },
                 {
                     label: '设备名称',

+ 27 - 14
accessControlSystem/src/views/trafficRecord/accessControlCapture/index.vue

@@ -6,13 +6,10 @@
                 <el-select v-model="mixins_query.guid" clearable placeholder="门禁机">
                     <el-option v-for="(item, index) in organList" :key="index" :label="item.deviceName" :value="item.id"></el-option>
                 </el-select>
-                <el-select v-model="mixins_query.householdType" clearable placeholder="人员类型">
-                    <el-option :value="1" label="业主"></el-option>
-                    <el-option :value="2" label="亲属"></el-option>
-                    <el-option :value="3" label="租客"></el-option>
-                    <el-option :value="4" label="物业员工"></el-option>
-                    <el-option :value="5" label="陌生人"></el-option>
-                    <el-option :value="6" label="其他"></el-option>
+                <el-select v-model="mixins_query.userTypeId" clearable placeholder="人员类型">
+                    <el-option :value="0" label="全部"></el-option>
+                    <el-option :value="1" label="住户"></el-option>
+                    <el-option :value="2" label="陌生人"></el-option>
                 </el-select>
                 <el-date-picker
                     v-model="pickerTime"
@@ -22,6 +19,7 @@
                     start-placeholder="开始日期"
                     end-placeholder="结束日期"
                     @change="timeToggle"
+                    :picker-options="pickerOptions"
                     :editable="false"
                 ></el-date-picker>
                 <el-button
@@ -42,6 +40,11 @@
                 :pageset="mixins_pageset"
                 @page-change="pageChange"
             >
+                <template slot-scope="scope" slot="imageObject">
+                    <div class="imgVdio">
+                        <el-image class="imgs" :src="scope.row.imageObject" :preview-src-list="[scope.row.imageObject]"></el-image>
+                    </div>
+                </template>
             </zz-table>
         </div>
     </div>
@@ -79,13 +82,19 @@ export default {
                 },
                 {
                     label: '抓拍图片',
-                    prop: 'imageObject'
+                    prop: 'imageObject',
+                    slot: 'imageObject'
                 },
                 {
                     label: '抓拍时间',
                     prop: 'createdAt'
                 }
             ],
+            pickerOptions: {
+                disabledDate(time) {
+                    return time.getTime() > Date.now();
+                }
+            },
             thisLeftData: {},
             communityArr: [],
             organList: [],
@@ -128,19 +137,20 @@ export default {
             let start = '00:00:00',
                 end = '23:59:59';
             if (!!e) {
-                this.mixins_query.startTime = `${e[0]} ${start}`;
-                this.mixins_query.endTime = `${e[1]} ${end}`;
+                this.mixins_query.beginDate = `${e[0]} ${start}`;
+                this.mixins_query.endDate = `${e[1]} ${end}`;
             } else {
-                this.mixins_query.startTime = ``;
-                this.mixins_query.endTime = ``;
+                this.mixins_query.beginDate = ``;
+                this.mixins_query.endDate = ``;
             }
         }
     },
     watch: {
         currentId(newValue, oldValue) {
-            this.mixins_query.communityId = newValue.communityId;
+            this.mixins_query.depId = newValue.communityId;
+            this.mixins_query.depName = newValue.communityName;
             this.mixins_query.buildingId = newValue.buildingId;
-            this.mixins_query.unitName = newValue.unitName;
+            this.mixins_query.unitId = newValue.unitName;
             this.thisLeftData = newValue;
             this.mixins_search();
         }
@@ -149,6 +159,9 @@ export default {
         this.getorgTree();
         this.getOrganList();
         this.mixins_dataUrl = '/sc-gate-web/record/visitor/page'; // 分页查询接口
+        this.mixins_query = {
+            userTypeId: 0
+        };
         this.mixins_search();
     }
 };