From 093fd6696ab7f34a48e9397050ee98ea1aa170c9 Mon Sep 17 00:00:00 2001 From: smallchill Date: Sun, 4 Aug 2019 20:14:58 +0800 Subject: [PATCH] =?UTF-8?q?:zap:=20=E5=88=A0=E9=99=A4=E5=90=8E=E6=B8=85?= =?UTF-8?q?=E7=A9=BA=E8=A2=AB=E9=80=89=E9=A1=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/authority/apiscope.vue | 6 ++++++ src/views/authority/datascope.vue | 6 ++++++ src/views/authority/role.vue | 5 +++++ src/views/desk/notice.vue | 6 ++++++ src/views/flow/follow.vue | 5 +++++ src/views/flow/manager.vue | 5 +++++ src/views/flow/model.vue | 5 +++++ src/views/resource/oss.vue | 5 +++++ src/views/system/client.vue | 5 +++++ src/views/system/dept.vue | 5 +++++ src/views/system/dict.vue | 5 +++++ src/views/system/menu.vue | 5 +++++ src/views/system/param.vue | 5 +++++ src/views/system/tenant.vue | 5 +++++ src/views/system/topmenu.vue | 5 +++++ src/views/system/user.vue | 5 +++++ src/views/tool/code.vue | 5 +++++ src/views/work/claim.vue | 5 +++++ src/views/work/done.vue | 5 +++++ src/views/work/send.vue | 5 +++++ src/views/work/start.vue | 5 +++++ src/views/work/todo.vue | 5 +++++ 22 files changed, 113 insertions(+) diff --git a/src/views/authority/apiscope.vue b/src/views/authority/apiscope.vue index cf4b83f..9b7c641 100644 --- a/src/views/authority/apiscope.vue +++ b/src/views/authority/apiscope.vue @@ -439,6 +439,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -480,6 +484,7 @@ getMenuList(page.currentPage, page.pageSize, params).then(res => { this.data = res.data.data; this.loading = false; + this.selectionClear(); }); }, // 数据权限模块 @@ -596,6 +601,7 @@ const data = res.data.data; this.pageScope.total = data.total; this.dataScope = data.records; + this.selectionListScope = []; }); }, } diff --git a/src/views/authority/datascope.vue b/src/views/authority/datascope.vue index c7ecb2b..4557b9b 100644 --- a/src/views/authority/datascope.vue +++ b/src/views/authority/datascope.vue @@ -469,6 +469,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -510,6 +514,7 @@ getMenuList(page.currentPage, page.pageSize, params).then(res => { this.data = res.data.data; this.loading = false; + this.selectionClear(); }); }, // 数据权限模块 @@ -626,6 +631,7 @@ const data = res.data.data; this.pageScope.total = data.total; this.dataScope = data.records; + this.selectionListScope = []; }); }, } diff --git a/src/views/authority/role.vue b/src/views/authority/role.vue index 1bda544..2c7399f 100644 --- a/src/views/authority/role.vue +++ b/src/views/authority/role.vue @@ -290,6 +290,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleRole() { if (this.selectionList.length !== 1) { this.$message.warning("只能选择一条数据"); @@ -349,6 +353,7 @@ this.option.column[index].dicData = data; }); this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/desk/notice.vue b/src/views/desk/notice.vue index 5a68253..3a5b7f3 100644 --- a/src/views/desk/notice.vue +++ b/src/views/desk/notice.vue @@ -4,6 +4,7 @@ :table-loading="loading" :data="data" :page="page" + ref="crud" @row-del="rowDel" v-model="form" :permission="permissionList" @@ -218,6 +219,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -273,6 +278,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/flow/follow.vue b/src/views/flow/follow.vue index 6f38128..59eb892 100644 --- a/src/views/flow/follow.vue +++ b/src/views/flow/follow.vue @@ -162,6 +162,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, currentChange(currentPage) { this.page.currentPage = currentPage; }, @@ -175,6 +179,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/flow/manager.vue b/src/views/flow/manager.vue index 05a0899..2a07ff3 100644 --- a/src/views/flow/manager.vue +++ b/src/views/flow/manager.vue @@ -233,6 +233,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -323,6 +327,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/flow/model.vue b/src/views/flow/model.vue index 065b041..3dda259 100644 --- a/src/views/flow/model.vue +++ b/src/views/flow/model.vue @@ -211,6 +211,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -307,6 +311,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); getDictionary({code: 'flow'}).then(res => { this.category = res.data.data; diff --git a/src/views/resource/oss.vue b/src/views/resource/oss.vue index 61eea78..74ef617 100644 --- a/src/views/resource/oss.vue +++ b/src/views/resource/oss.vue @@ -230,6 +230,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleEnable(row) { this.$confirm("是否确定启用这条配置?", { confirmButtonText: "确定", @@ -291,6 +295,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/client.vue b/src/views/system/client.vue index 3401368..2bf91a5 100644 --- a/src/views/system/client.vue +++ b/src/views/system/client.vue @@ -242,6 +242,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -285,6 +289,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/dept.vue b/src/views/system/dept.vue index d53a0ac..cd426b7 100644 --- a/src/views/system/dept.vue +++ b/src/views/system/dept.vue @@ -259,6 +259,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, beforeOpen(done, type) { if (["edit", "view"].includes(type)) { getDept(this.form.id).then(res => { @@ -283,6 +287,7 @@ this.option.column[index].dicData = data; }); this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/dict.vue b/src/views/system/dict.vue index 7bde324..92746c5 100644 --- a/src/views/system/dict.vue +++ b/src/views/system/dict.vue @@ -201,6 +201,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -247,6 +251,7 @@ this.option.column[index].dicData = data; }); this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/menu.vue b/src/views/system/menu.vue index ddd725c..c828f4b 100644 --- a/src/views/system/menu.vue +++ b/src/views/system/menu.vue @@ -260,6 +260,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -301,6 +305,7 @@ getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => { this.data = res.data.data; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/param.vue b/src/views/system/param.vue index 3fa842d..b241efa 100644 --- a/src/views/system/param.vue +++ b/src/views/system/param.vue @@ -161,6 +161,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -196,6 +200,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/tenant.vue b/src/views/system/tenant.vue index 79492b4..6a1ae76 100644 --- a/src/views/system/tenant.vue +++ b/src/views/system/tenant.vue @@ -181,6 +181,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -216,6 +220,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/topmenu.vue b/src/views/system/topmenu.vue index 8daae6c..0ee47ee 100644 --- a/src/views/system/topmenu.vue +++ b/src/views/system/topmenu.vue @@ -273,6 +273,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, currentChange(currentPage) { this.page.currentPage = currentPage; }, @@ -286,6 +290,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/system/user.vue b/src/views/system/user.vue index 57edaf8..46d0412 100644 --- a/src/views/system/user.vue +++ b/src/views/system/user.vue @@ -344,6 +344,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -416,6 +420,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); getDeptTree(this.form.tenantId).then(res => { const index = this.$refs.crud.findColumnIndex("deptId"); diff --git a/src/views/tool/code.vue b/src/views/tool/code.vue index 87c0c18..e0260d2 100644 --- a/src/views/tool/code.vue +++ b/src/views/tool/code.vue @@ -220,6 +220,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDelete() { if (this.selectionList.length === 0) { this.$message.warning("请选择至少一条数据"); @@ -286,6 +290,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/work/claim.vue b/src/views/work/claim.vue index a5292be..8e0ed08 100644 --- a/src/views/work/claim.vue +++ b/src/views/work/claim.vue @@ -160,6 +160,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleClaim(row) { this.$confirm("确定签收此任务?", { confirmButtonText: "确定", @@ -201,6 +205,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/work/done.vue b/src/views/work/done.vue index 3b76d78..0087a2a 100644 --- a/src/views/work/done.vue +++ b/src/views/work/done.vue @@ -153,6 +153,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDetail(row) { this.$router.push({path: `/work/process/${flowRoute(this.flowRoutes, row.category)}/detail/${row.processInstanceId}/${row.businessId}`}); }, @@ -177,6 +181,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/work/send.vue b/src/views/work/send.vue index 64c7cfd..719d04a 100644 --- a/src/views/work/send.vue +++ b/src/views/work/send.vue @@ -163,6 +163,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleDetail(row) { this.$router.push({ path: `/work/process/${flowRoute(this.flowRoutes, row.category)}/detail/${row.processInstanceId}/${row.businessId}` }); }, @@ -187,6 +191,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/work/start.vue b/src/views/work/start.vue index 2ed285a..83b4a92 100644 --- a/src/views/work/start.vue +++ b/src/views/work/start.vue @@ -166,6 +166,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleStart(row) { this.$router.push({path: `/work/process/${flowRoute(this.flowRoutes, row.category)}/form/${row.id}`}); }, @@ -190,6 +194,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } } diff --git a/src/views/work/todo.vue b/src/views/work/todo.vue index af50472..82094d8 100644 --- a/src/views/work/todo.vue +++ b/src/views/work/todo.vue @@ -160,6 +160,10 @@ selectionChange(list) { this.selectionList = list; }, + selectionClear() { + this.selectionList = []; + this.$refs.crud.toggleSelection(); + }, handleWork(row) { this.$router.push({ path: `/work/process/${flowRoute(this.flowRoutes, row.category)}/handle/${row.taskId}/${row.processInstanceId}/${row.businessId}` }); }, @@ -187,6 +191,7 @@ this.page.total = data.total; this.data = data.records; this.loading = false; + this.selectionClear(); }); } }