-
+
+
{
+ 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();