From dfb7a8a63e87390dc095e81b04f0404697246d9f Mon Sep 17 00:00:00 2001 From: 张涛 <“2538313560@qq.com”> Date: 星期五, 22 十一月 2024 20:20:56 +0800 Subject: [PATCH] 增加跳转的接口 --- src/views/authority/organization/index.vue | 23 ++++++++++++++++++++--- 1 files changed, 20 insertions(+), 3 deletions(-) diff --git a/src/views/authority/organization/index.vue b/src/views/authority/organization/index.vue index 65ae930..3f5d129 100644 --- a/src/views/authority/organization/index.vue +++ b/src/views/authority/organization/index.vue @@ -7,11 +7,21 @@ <a-card :title="$t('menu.organization.title')" :bordered="false" - style=" 'width': '100%'; height: calc(100vh - 250px);; 'overflow-y': 'auto' " + :header-style="{ textAlign: 'left' }" + style=" 'width': '100%'; height: calc(100vh - 250px); overflow-y:auto " > + <template #title> + <span>{{ $t('menu.organization.title') }}</span> + <a-tooltip content="鐐瑰嚮鍚庡彲閫氳繃鎷栨嫿鏇存敼鏈烘瀯缁撴瀯,鍐嶆鐐瑰嚮鏉ュ叧闂�" background-color="#165DFF"> + <a-button type="outline" style="float: right;" @click="toggleDraggable" :style="{color: buttonColor}" + v-has-permi="'/base/syorganization!update'"> + <component :is="lockIcon" /> + </a-button> + </a-tooltip> + </template> <a-tree class="tree-demo" - draggable + :draggable="draggable" blockNode :data="treeData" :show-line="showLine" @@ -158,7 +168,9 @@ address: '', deptId: '', }); - +let draggable = ref(false); +let buttonColor = ref(""); +let lockIcon = ref("IconLock"); const onIconClick = (nodeData) => { deptform.value.deptName = ""; deptform.value.email = ""; @@ -276,6 +288,11 @@ }; OrganizationData(''); + const toggleDraggable = () =>{ + draggable.value = !draggable.value; + buttonColor.value= draggable.value ? '#575757' : ''; + lockIcon.value = draggable.value ? 'IconUnlock' : 'IconLock'; + }; </script> <style scoped> -- Gitblit v1.8.0