Commit 6ffbb058 by 陈羽

update: 优化

parent 5ee61a35
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* @LastEditTime: 2021-04-12 15:57:24 * @LastEditTime: 2021-04-12 15:57:24
--> -->
<!-- <!--
<el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="!scope.row.fromMaterialId">分配企业</el-button> <el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="scope.row.fromMaterialId =='-1'">分配企业</el-button>
<distribution-enterprise :editRow="distributionEditRow" :show="showDistribution" @closeText="closeTextDistribution" @submitText="submitTextDistribution"></distribution-enterprise> <distribution-enterprise :editRow="distributionEditRow" :show="showDistribution" @closeText="closeTextDistribution" @submitText="submitTextDistribution"></distribution-enterprise>
<script> <script>
...@@ -104,6 +104,10 @@ export default { ...@@ -104,6 +104,10 @@ export default {
methods: { methods: {
toCancel() { toCancel() {
this.$emit('closeText'); this.$emit('closeText');
this.form.checkedList = [];
this.hasCheckAll = false;
this.checkAll = false;
this.isIndeterminate = false;
this.$refs['ruleForm'].resetFields(); this.$refs['ruleForm'].resetFields();
}, },
submitForm: _debounce(function(formName) { submitForm: _debounce(function(formName) {
...@@ -159,6 +163,8 @@ export default { ...@@ -159,6 +163,8 @@ export default {
const data = { const data = {
materialId: this.editRow.materialId materialId: this.editRow.materialId
}; };
this.checkAll = false;
this.hasCheckAll = false;
getRequest('/haoban-manage3-web/agent-wx-enterprise-list', data) getRequest('/haoban-manage3-web/agent-wx-enterprise-list', data)
.then(res => { .then(res => {
let resData = res.data; let resData = res.data;
...@@ -178,6 +184,7 @@ export default { ...@@ -178,6 +184,7 @@ export default {
this.hasCheckAll = true; this.hasCheckAll = true;
} }
this.options = [...options]; this.options = [...options];
this.handleCheckedListChange(this.form.checkedList);
} else { } else {
errMsg.errorMsg(resData); errMsg.errorMsg(resData);
} }
......
...@@ -45,7 +45,7 @@ ...@@ -45,7 +45,7 @@
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="!scope.row.fromMaterialId">分配企业</el-button> <el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="scope.row.fromMaterialId == '-1'">分配企业</el-button>
<el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button> <el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button>
<el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button> <el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button>
</template> </template>
......
...@@ -45,7 +45,7 @@ ...@@ -45,7 +45,7 @@
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="!scope.row.fromMaterialId">分配企业</el-button> <el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="scope.row.fromMaterialId == '-1'">分配企业</el-button>
<el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button> <el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button>
<el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button> <el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button>
</template> </template>
......
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="!scope.row.fromMaterialId">分配企业</el-button> <el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="scope.row.fromMaterialId == '-1'">分配企业</el-button>
<el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button> <el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button>
<el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button> <el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button>
</template> </template>
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="!scope.row.fromMaterialId">分配企业</el-button> <el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="scope.row.fromMaterialId == '-1'">分配企业</el-button>
<el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button> <el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button>
<el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button> <el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button>
</template> </template>
......
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="!scope.row.fromMaterialId">分配企业</el-button> <el-button type="text" @click="toDistribute(scope.$index, scope.row)" v-if="scope.row.fromMaterialId == '-1'">分配企业</el-button>
<el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button> <el-button type="text" @click="toEdit(scope.$index, scope.row)">编辑</el-button>
<el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button> <el-button type="text" @click="toDel(scope.$index, scope.row)">删除</el-button>
</template> </template>
......
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