From f280311895f7354eed1b51732c0d9f0db978e114 Mon Sep 17 00:00:00 2001 From: zyzm <1534695664@qq.com> Date: Mon, 7 Nov 2022 17:16:16 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E6=97=A5=E5=BF=97?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/system/logManage/doorLog/index.vue | 8 ++++++-- src/views/system/logManage/loginLog/index.vue | 4 ++-- src/views/system/logManage/warnLog/index.vue | 4 ++-- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/views/system/logManage/doorLog/index.vue b/src/views/system/logManage/doorLog/index.vue index 6d8e7c8..010c603 100644 --- a/src/views/system/logManage/doorLog/index.vue +++ b/src/views/system/logManage/doorLog/index.vue @@ -70,8 +70,9 @@ import rrOperation from '@crud/RR.operation' import CRUD, { presenter, crud } from '@crud/crud' import DateRangePicker from '@/components/DateRangePicker' import pagination from '@crud/Pagination' -import { exportFile } from '@/utils/index' +import { parseTime, saveAs, getBlob } from '@/utils/index' import { mapGetters } from 'vuex' +import qs from 'qs' export default { name: 'DoorLog', components: { rrOperation, DateRangePicker, pagination }, @@ -123,7 +124,10 @@ export default { // 导出 handleDownload() { this.crud.downloadLoading = true - exportFile(this.baseApi + '/api/securitydoor/exportSecurityDoorLogList') + const fileName = parseTime(new Date()) + '-门禁日志.xlsx' + getBlob(this.baseApi + '/api/securitydoor/exportSecurityDoorLogList' + '?' + qs.stringify(this.crud.query, { indices: false }), function(blob) { + saveAs(blob, fileName) + }) this.crud.downloadLoading = false }, clickRowHandler(row) { diff --git a/src/views/system/logManage/loginLog/index.vue b/src/views/system/logManage/loginLog/index.vue index 5e6f003..56b48a4 100644 --- a/src/views/system/logManage/loginLog/index.vue +++ b/src/views/system/logManage/loginLog/index.vue @@ -63,6 +63,7 @@ import DateRangePicker from '@/components/DateRangePicker' import pagination from '@crud/Pagination' import { mapGetters } from 'vuex' import { parseTime, saveAs, getBlob } from '@/utils/index' +import qs from 'qs' export default { name: 'LoginLog', components: { rrOperation, DateRangePicker, pagination }, @@ -111,7 +112,7 @@ export default { handleDownload() { this.crud.downloadLoading = true const fileName = parseTime(new Date()) + '-登录日志' - getBlob(this.baseApi + '/api/loginlogs/download', function(blob) { + getBlob(this.baseApi + '/api/loginlogs/download' + '?' + qs.stringify(this.crud.query, { indices: false }), function(blob) { saveAs(blob, fileName) }) this.crud.downloadLoading = false @@ -131,5 +132,4 @@ export default { diff --git a/src/views/system/logManage/warnLog/index.vue b/src/views/system/logManage/warnLog/index.vue index 2470724..f7ee44a 100644 --- a/src/views/system/logManage/warnLog/index.vue +++ b/src/views/system/logManage/warnLog/index.vue @@ -85,7 +85,7 @@ import DateRangePicker from '@/components/DateRangePicker' import pagination from '@crud/Pagination' import { warnRemark } from '@/api/system/logs' import { parseTime, saveAs, getBlob } from '@/utils/index' -// import qs from 'qs' +import qs from 'qs' import { mapGetters } from 'vuex' export default { name: 'LoginLog', @@ -151,7 +151,7 @@ export default { handleDownload() { this.crud.downloadLoading = true const fileName = parseTime(new Date()) + '-报警日志' - getBlob(this.baseApi + '/api/alarmlog/download', function(blob) { + getBlob(this.baseApi + '/api/alarmlog/download' + '?' + qs.stringify(this.crud.query, { indices: false }), function(blob) { saveAs(blob, fileName) }) this.crud.downloadLoading = false From 357b51bc1f13a021245484c6117af1db220e0ca1 Mon Sep 17 00:00:00 2001 From: zyzm <1534695664@qq.com> Date: Tue, 8 Nov 2022 09:16:45 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E8=AE=BE=E5=A4=87=E7=BC=96=E8=BE=91?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/storeManage/deviceManage/module/deviceDetail.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/storeManage/deviceManage/module/deviceDetail.vue b/src/views/storeManage/deviceManage/module/deviceDetail.vue index ef30d18..9bcc98f 100644 --- a/src/views/storeManage/deviceManage/module/deviceDetail.vue +++ b/src/views/storeManage/deviceManage/module/deviceDetail.vue @@ -27,6 +27,7 @@
+ @@ -418,7 +419,6 @@ export default { return false }, [CRUD.HOOK.beforeSubmit]() { - this.crud.form.storeroomId = this.storeroomId this.crud.form.supplierId = this.supplierOptions.find(item => item.id === this.crud.form.supplier) this.crud.form.deviceTypeId = this.deviceTypeOptions.find(item => item.name === this.selectedDeviceType) }, From 9343e70e1c196b6c60db3549e372f17bab3d148a Mon Sep 17 00:00:00 2001 From: zyzm <1534695664@qq.com> Date: Wed, 9 Nov 2022 10:44:04 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E9=BA=92=E9=BA=9F=E7=B3=BB=E7=BB=9F?= =?UTF-8?q?=E8=8E=B7=E5=8F=96mac=E5=9C=B0=E5=9D=80=E5=88=87=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/RFID/RFID.js | 3 ++- src/api/storeManage/deviceManage/mac.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/api/RFID/RFID.js b/src/api/RFID/RFID.js index f7b74a8..cdaea12 100644 --- a/src/api/RFID/RFID.js +++ b/src/api/RFID/RFID.js @@ -26,7 +26,8 @@ export function writeEPC(params) { export function getDeviceMac() { return request({ - url: 'api/RFID/getDeviceMac', + // url: 'api/RFID/getDeviceMac', + url: 'api/RFID/getDeviceMacLinux', method: 'get' }) } diff --git a/src/api/storeManage/deviceManage/mac.js b/src/api/storeManage/deviceManage/mac.js index 4649b05..ced9eed 100644 --- a/src/api/storeManage/deviceManage/mac.js +++ b/src/api/storeManage/deviceManage/mac.js @@ -2,7 +2,8 @@ import request from '@/utils/request' export function getMac() { return request({ - url: 'api/RFID/getDeviceMac', + // url: 'api/RFID/getDeviceMac', + url: 'api/RFID/getDeviceMacLinux', method: 'get' }) }