|
|
@@ -7,6 +7,7 @@
|
|
|
width="1100px"
|
|
|
top="10vh"
|
|
|
append-to-body
|
|
|
+ @close="onClose"
|
|
|
>
|
|
|
<div class="el-dialog-div">
|
|
|
<el-row :gutter="20">
|
|
|
@@ -142,6 +143,10 @@ export default {
|
|
|
customTreeRequest: {
|
|
|
type: Function,
|
|
|
},
|
|
|
+ clearSelectOnClose: {
|
|
|
+ type: Boolean,
|
|
|
+ default: true,
|
|
|
+ },
|
|
|
},
|
|
|
methods: {
|
|
|
getLabel,
|
|
|
@@ -161,6 +166,9 @@ export default {
|
|
|
this.isShow = true;
|
|
|
// this.refresh()
|
|
|
},
|
|
|
+ clearSelected() {
|
|
|
+ this.selectList = [];
|
|
|
+ },
|
|
|
resetQuery() {
|
|
|
this.search.username = null;
|
|
|
this.search.name = null;
|
|
|
@@ -175,6 +183,11 @@ export default {
|
|
|
onSelect(item) {
|
|
|
this.selectList = item;
|
|
|
},
|
|
|
+ onClose() {
|
|
|
+ if (this.clearSelectOnClose) {
|
|
|
+ this.clearSelected();
|
|
|
+ }
|
|
|
+ },
|
|
|
refresh() {
|
|
|
this.$nextTick(() => {
|
|
|
this.$refs.searchTable.refresh();
|