From 46f828b435f7705b3aeba3d7c55194df77ecc127 Mon Sep 17 00:00:00 2001 From: yanyizhou <2311759275@qq.com> Date: Wed, 10 Nov 2021 16:26:04 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E7=82=B9=E9=97=AE=E9=A2=98=E7=AE=A1?= =?UTF-8?q?=E6=8E=A7=20-=20=E6=89=B9=E9=87=8F=E5=85=B3=E9=97=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../nonConfomity/pages/businessDivision.vue | 38 ++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/src/pages/regulatoryRepository/nonConfomity/pages/businessDivision.vue b/src/pages/regulatoryRepository/nonConfomity/pages/businessDivision.vue index 3271a1037..0d8d85d26 100644 --- a/src/pages/regulatoryRepository/nonConfomity/pages/businessDivision.vue +++ b/src/pages/regulatoryRepository/nonConfomity/pages/businessDivision.vue @@ -25,6 +25,8 @@ placeholder="请输入" clearable :maxlength="100"> + @@ -120,6 +122,7 @@ style="width: 100%;" height="100%" border + @selection-change="standSelectChange" :header-cell-style="{background: '#e8e8e8', color: '#333333', fontSize: '16px', fontWeight: 'bold', height: '48px'}" > @@ -228,10 +231,12 @@ export default { name: "businessDivision", data() { return { + selectedList: [], //标准选中的数据 sarAccessListTotal: 0, sarAccessListDatas: [], // 查询相关参数 sarSarAccessEOSearch: { + isClose:'0', lawNumOrName: '', // 编号/名称 productType: '', // 产品类型 responseDept: '', // 责任部门 @@ -262,9 +267,40 @@ export default { this.sarSarAccessEOSearch.lawName = this.sarSarAccessEOSearch.lawNumOrName this.sarSarAccessEOSearch.lawNumber = this.sarSarAccessEOSearch.lawNumOrName }, + // 修改成表格样式后,选择项勾选改变 + standSelectChange (data) { + this.selectedList = [] + for (let i = 0; i < data.length; i++) { + this.selectedList.push(data[i].id) + } + }, //点击批量关闭按钮事件 userCloAll() { - console.log('至少选择一条数据'); + if (this.selectedList.length === 0){ + this.$message.warning('请选择一条数据进行关闭') + }else{ + this.$confirm('确认关闭这些数据?', '提示', { + confirmButtonText: '确定', + confirmButtonClass: 'common-button-primary', + cancelButtonTxe: '取消', + type: 'warning', + roundButton: false, + }).then(() => { + this.$http.post('sarStandUnqualified/businessDeptIssue/closeIssue',{ + ids: this.selectedList + },{ + _this: this + }, res => { + if (res.ok) { + this.searchSarAccessBtn() + this.selectedList = [] + this.$message.success('关闭成功') + } + }) + }).catch(() => { + + }) + } }, //点击历史数据按钮事件 historyClick() {