|
|
@@ -1,6 +1,9 @@
|
|
|
<template>
|
|
|
<div class="top-right-btn" :style="style">
|
|
|
<el-row>
|
|
|
+ <el-tooltip class="item" effect="dark" :content="showOrgTree ? '隐藏机构':'显示机构'" placement="top" v-if="orgTree">
|
|
|
+ <el-button size="mini" circle :icon="showOrgTree ? 'el-icon-s-fold': 'el-icon-s-unfold'" @click="toggleOrgTree()" />
|
|
|
+ </el-tooltip>
|
|
|
<el-tooltip class="item" effect="dark" :content="showSearch ? '折叠搜索' : '展开搜索'" placement="top" v-if="search">
|
|
|
<el-button size="mini" circle :icon="showSearch ? 'el-icon-top':'el-icon-bottom'" @click="toggleSearch()" />
|
|
|
</el-tooltip>
|
|
|
@@ -35,6 +38,10 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
props: {
|
|
|
+ showOrgTree: {
|
|
|
+ type: Boolean,
|
|
|
+ default: true,
|
|
|
+ },
|
|
|
showSearch: {
|
|
|
type: Boolean,
|
|
|
default: true,
|
|
|
@@ -42,6 +49,10 @@ export default {
|
|
|
columns: {
|
|
|
type: Array,
|
|
|
},
|
|
|
+ orgTree: {
|
|
|
+ type: Boolean,
|
|
|
+ default: true,
|
|
|
+ },
|
|
|
search: {
|
|
|
type: Boolean,
|
|
|
default: true,
|
|
|
@@ -69,6 +80,9 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ toggleOrgTree(){
|
|
|
+ this.$emit("update:showOrgTree", !this.showOrgTree);
|
|
|
+ },
|
|
|
// 搜索
|
|
|
toggleSearch() {
|
|
|
this.$emit("update:showSearch", !this.showSearch);
|