Commit 8080d959 authored by 王启林's avatar 王启林

perf: 优化业务关联事项详情

parent 0ce85d1e
......@@ -4,7 +4,7 @@
"homepage": "https://iczer.github.io/vue-antd-admin",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"serve": "SET NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve",
"build": "vue-cli-service build --mode production",
"beta": "vue-cli-service build --mode beta",
"test": "vue-cli-service build --mode test",
......
......@@ -47,15 +47,19 @@
</span>
</template>
<template slot="action" slot-scope="text">
<a-tooltip>
<template slot="title"> 解除查看 </template>
<a-space>
<span
class="primary pointer"
@click="handleisUnbound(true,text)"
>关联详情</span
>
<span
href="javascript:;"
class="delete pointer"
@click="handleisUnbound(text)"
@click="handleisUnbound(false,text)"
>解除</span
>
</a-tooltip>
</a-space>
</template>
</a-table>
</div>
......@@ -214,11 +218,12 @@
<a-modal
:maskClosable="false"
v-model="isUnbound"
title="解除确认"
:title="checkFlag ? '关联详情':'解除确认'"
@ok="handleUnbound"
@cancel="handleCloseUnbound"
>
<p>此操作将解除</p>
<p v-if="checkFlag">已关联 <span class="primary">{{ unboundMatterData.length }}</span> 件事项</p>
<p v-else>此操作将解除</p>
<a-form-model :wrapper-col="{ span: 24 }">
<a-form-model-item>
<div class="business">
......@@ -241,7 +246,7 @@
>
<a-tag color="#108ee9"> 事项 </a-tag>
<span class="matter-name">{{ v.matterName }}</span>
<a-tooltip>
<a-tooltip v-if="!checkFlag">
<template slot="title"> 解除此项 </template>
<a-icon
class="delete-icon"
......@@ -385,6 +390,7 @@ export default {
siteBusinessName: "",
},
allCorrelationData: [], // 关联业务事项数据
checkFlag:true, // 查看标杆
rules: {
siteBusinessId: [
{ required: true, message: "业务不能为空", trigger: "change" },
......@@ -496,8 +502,10 @@ export default {
this.leftCurrent = 1;
this.getBusinessMatterData();
},
// 左边解除按钮
handleisUnbound(data) {
handleisUnbound(isCheck,data) {
this.checkFlag = isCheck
this.unboundBusinessData = data;
this.isUnbound = true;
this.getMatterlistData({
......@@ -515,6 +523,11 @@ export default {
// 解除确认
async handleUnbound(val = {}) {
if(this.checkFlag){
this.handleCloseUnbound()
this.isUnbound = false;
return
}
let str;
if (this.unboundMatterItem.length > 0) {
str = this.unboundMatterItem.join(",");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment