From f7ca508a9cca330caeb63371bcdd4514b4b8195b Mon Sep 17 00:00:00 2001 From: dyhj625 Date: Thu, 13 Feb 2025 16:25:20 +0900 Subject: [PATCH] =?UTF-8?q?=ED=9C=B4=EA=B0=80=EA=B0=80=EB=A6=AC=EC=8A=A4?= =?UTF-8?q?=ED=8A=B8=20=EB=AA=A8=EB=8B=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/modal/VacationModal.vue | 165 ++++++++++++++++++++++ src/components/vacation/ProfileList.vue | 91 ++++++------ src/views/vacation/VacationManagement.vue | 42 +++++- 3 files changed, 252 insertions(+), 46 deletions(-) create mode 100644 src/components/modal/VacationModal.vue diff --git a/src/components/modal/VacationModal.vue b/src/components/modal/VacationModal.vue new file mode 100644 index 0000000..6e90f44 --- /dev/null +++ b/src/components/modal/VacationModal.vue @@ -0,0 +1,165 @@ + + + + + diff --git a/src/components/vacation/ProfileList.vue b/src/components/vacation/ProfileList.vue index ba4d594..32ffdd5 100644 --- a/src/components/vacation/ProfileList.vue +++ b/src/components/vacation/ProfileList.vue @@ -1,67 +1,71 @@ diff --git a/src/views/vacation/VacationManagement.vue b/src/views/vacation/VacationManagement.vue index 5b9d8f1..bb11afd 100644 --- a/src/views/vacation/VacationManagement.vue +++ b/src/views/vacation/VacationManagement.vue @@ -5,8 +5,17 @@
- +
+ { + try { + console.log(`๐Ÿ” ${user.MEMBERSEQ}๋‹˜์˜ ์—ฐ์ฐจ ๋‚ด์—ญ ์š”์ฒญ ์ค‘...`); + const response = await axios.get(`vacation/history`); + + if (response.status === 200 && response.data) { + console.log("โœ… ์—ฐ์ฐจ ๋‚ด์—ญ ์‘๋‹ต:", response.data); + myVacations.value = response.data.data.usedVacations || []; + receivedVacations.value = response.data.data.receivedVacations || []; + + console.log("๐Ÿ“Œ myVacations:", myVacations.value); + console.log("๐Ÿ“Œ receivedVacations:", receivedVacations.value); + + isModalOpen.value = true; + } else { + console.warn("โŒ ์—ฐ์ฐจ ๋‚ด์—ญ์„ ๋ถˆ๋Ÿฌ์˜ค์ง€ ๋ชปํ–ˆ์Šต๋‹ˆ๋‹ค."); + } + } catch (error) { + console.error("๐Ÿšจ ์—ฐ์ฐจ ๋ฐ์ดํ„ฐ ๋ถˆ๋Ÿฌ์˜ค๊ธฐ ์‹คํŒจ:", error); + } +}; + const fetchUserList = async () => { try { await userStore.fetchUserList();