From fd5532b46ab8d7800e0186a47270fdc9281d8b0a Mon Sep 17 00:00:00 2001 From: puriphatt Date: Fri, 19 Jul 2024 04:56:08 +0000 Subject: [PATCH] feat: 01 functional hold dialog --- src/pages/01_branch-management/MainPage.vue | 97 ++++++++++++++++++--- 1 file changed, 85 insertions(+), 12 deletions(-) diff --git a/src/pages/01_branch-management/MainPage.vue b/src/pages/01_branch-management/MainPage.vue index 59fb474d..a6f89c39 100644 --- a/src/pages/01_branch-management/MainPage.vue +++ b/src/pages/01_branch-management/MainPage.vue @@ -68,7 +68,7 @@ const expandedTree = ref([]); const profileFileImg = ref(undefined); const imageUrl = ref(''); -const currentTreehHeadOfficeId = ref(''); +const currentNode = ref(); const inputFileImg = (() => { const element = document.createElement('input'); @@ -492,9 +492,12 @@ function changeTitle( return ''; } -function handleHold() { +function handleHold(node: BranchWithChildren) { if ($q.screen.gt.xs) return; - holdDialog.value = true; + return function (props: unknown) { + holdDialog.value = true; + currentNode.value = node; + }; } watch(locale, () => { @@ -633,7 +636,7 @@ watch(