|
@@ -21,25 +21,26 @@
|
|
>
|
|
>
|
|
<div class="search-icon">
|
|
<div class="search-icon">
|
|
<el-tooltip class="item" effect="light" placement="bottom" content="添加">
|
|
<el-tooltip class="item" effect="light" placement="bottom" content="添加">
|
|
- <i class="zoniot_font zoniot-icon-tianjia2" @click="addCard()"></i>
|
|
|
|
|
|
+ <i class="zoniot_font zoniot-icon-tianjia2" @click="addList()"></i>
|
|
</el-tooltip>
|
|
</el-tooltip>
|
|
<el-tooltip class="item" effect="light" placement="bottom" content="删除">
|
|
<el-tooltip class="item" effect="light" placement="bottom" content="删除">
|
|
- <i class="zoniot_font zoniot-icon-shanchu2" @click="deleteCard()"></i>
|
|
|
|
|
|
+ <i class="zoniot_font zoniot-icon-shanchu2" @click="deleteList()"></i>
|
|
</el-tooltip>
|
|
</el-tooltip>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<zz-table
|
|
<zz-table
|
|
- :settings="{ showIndex: true, stripe: true }"
|
|
|
|
|
|
+ :settings="{ showCheckbox: true, stripe: true }"
|
|
:cols="cols"
|
|
:cols="cols"
|
|
:loading="mixins_onQuery"
|
|
:loading="mixins_onQuery"
|
|
:data="mixins_list"
|
|
:data="mixins_list"
|
|
:pageset="mixins_pageset"
|
|
:pageset="mixins_pageset"
|
|
@page-change="pageChange"
|
|
@page-change="pageChange"
|
|
|
|
+ @selection-change="selectionChange"
|
|
>
|
|
>
|
|
<template slot-scope="scope" slot="opt">
|
|
<template slot-scope="scope" slot="opt">
|
|
<div class="opt">
|
|
<div class="opt">
|
|
<el-tooltip class="item" effect="light" placement="bottom" content="删除">
|
|
<el-tooltip class="item" effect="light" placement="bottom" content="删除">
|
|
- <i class="zoniot_font zoniot-icon-shanchu1 redText" @click="lookPage(scope.row)"></i>
|
|
|
|
|
|
+ <i class="zoniot_font zoniot-icon-shanchu1 redText" @click="deleteList(scope.row)"></i>
|
|
</el-tooltip>
|
|
</el-tooltip>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
@@ -92,6 +93,7 @@ export default {
|
|
width: 150
|
|
width: 150
|
|
}
|
|
}
|
|
],
|
|
],
|
|
|
|
+ selectRow: [],
|
|
mixins_post: 'get'
|
|
mixins_post: 'get'
|
|
};
|
|
};
|
|
},
|
|
},
|
|
@@ -99,6 +101,9 @@ export default {
|
|
currentOrganId(data) {
|
|
currentOrganId(data) {
|
|
this.currentId = data.id || '';
|
|
this.currentId = data.id || '';
|
|
},
|
|
},
|
|
|
|
+ selectionChange(val) {
|
|
|
|
+ this.selectRow = val;
|
|
|
|
+ },
|
|
timeToggle(e) {
|
|
timeToggle(e) {
|
|
let start = '00:00:00',
|
|
let start = '00:00:00',
|
|
end = '23:59:59';
|
|
end = '23:59:59';
|
|
@@ -109,6 +114,49 @@ export default {
|
|
this.mixins_query.startTime = ``;
|
|
this.mixins_query.startTime = ``;
|
|
this.mixins_query.endTime = ``;
|
|
this.mixins_query.endTime = ``;
|
|
}
|
|
}
|
|
|
|
+ },
|
|
|
|
+ addList() {
|
|
|
|
+ new Promise((resolve) => {
|
|
|
|
+ this.$store.dispatch('addPopup', {
|
|
|
|
+ url: '/deviceManagement/propertyManagementMachine/popups/add.vue',
|
|
|
|
+ width: '548px',
|
|
|
|
+ height: '400px',
|
|
|
|
+ props: {
|
|
|
|
+ callback: resolve
|
|
|
|
+ },
|
|
|
|
+ hideStar: false,
|
|
|
|
+ title: '添加物管机'
|
|
|
|
+ });
|
|
|
|
+ }).then(() => {
|
|
|
|
+ this.mixins_search();
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ deleteList() {
|
|
|
|
+ //获取选中列表的ids
|
|
|
|
+ let ids = [];
|
|
|
|
+ if (!this.selectRow.length) {
|
|
|
|
+ this.$message.error('您尚未选择,请选择后再操作');
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ this.selectRow.forEach((v) => {
|
|
|
|
+ ids.push(v.id);
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ this.$msgBox(`删除确认`, '门禁设备删除后,人员将无法正常开启门禁')
|
|
|
|
+ .then(() => {
|
|
|
|
+ this.$http.post('/sc-gate-web/gate/delete', { ids: ids }).then(({ status, data, msg }) => {
|
|
|
|
+ if (0 === status) {
|
|
|
|
+ this.$message({
|
|
|
|
+ type: 'success',
|
|
|
|
+ message: '删除成功!'
|
|
|
|
+ });
|
|
|
|
+ this.mixins_search();
|
|
|
|
+ } else {
|
|
|
|
+ this.$message.error(msg);
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ })
|
|
|
|
+ .catch(() => {});
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
|