From 40c2a166a458772487c023125e496e3cc0e0f9f0 Mon Sep 17 00:00:00 2001 From: yoon Date: Tue, 11 Feb 2025 12:59:40 +0900 Subject: [PATCH 01/12] =?UTF-8?q?userList=20filter=20css=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/css/custom.css | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/public/css/custom.css b/public/css/custom.css index 5c3e23b..bee9d0c 100644 --- a/public/css/custom.css +++ b/public/css/custom.css @@ -93,4 +93,11 @@ top: 0px !important; left: 5px !important; text-align: left !important; - } \ No newline at end of file + } + + /* userList */ + + .grayscaleImg { + filter: grayscale(100%); + } + \ No newline at end of file From 8ab9e79b5a12f3a508945716b3e65bf378681413 Mon Sep 17 00:00:00 2001 From: yoon Date: Tue, 11 Feb 2025 12:59:49 +0900 Subject: [PATCH 02/12] =?UTF-8?q?userlist=20=EC=BD=94=EB=93=9C=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/user/UserList.vue | 52 ++++++++++++-------------------- 1 file changed, 20 insertions(+), 32 deletions(-) diff --git a/src/components/user/UserList.vue b/src/components/user/UserList.vue index 87ec5b8..f4d9e6c 100644 --- a/src/components/user/UserList.vue +++ b/src/components/user/UserList.vue @@ -1,24 +1,26 @@ @@ -68,18 +70,4 @@ const getTooltipTitle = (user) => { From 558008acc5d9828ca37abb81dd817bfad253dcd0 Mon Sep 17 00:00:00 2001 From: yoon Date: Thu, 13 Feb 2025 14:38:07 +0900 Subject: [PATCH 03/12] =?UTF-8?q?commonApi=20=EB=A1=9C=EC=A7=81=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/commonApi.js | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/src/common/commonApi.js b/src/common/commonApi.js index f7098e0..6049bd8 100644 --- a/src/common/commonApi.js +++ b/src/common/commonApi.js @@ -8,29 +8,35 @@ import { ref, onMounted } from "vue"; import $api from '@api'; -const commonApi = () => { +const commonApi = (options = {}) => { const colorList = ref([]); const mbtiList = ref([]); const pwhintList = ref([]); const yearCategory = ref([]); const cateList = ref([]); - const CommonCode = async (path, endpoint, targetList) => { - - const response = await $api.get(`${path}/${endpoint}`); + // type 파라미터를 추가로 받도록 수정 + const CommonCode = async (path, endpoint, targetList, type = null) => { + const params = type ? { type } : {}; + const response = await $api.get(`${path}/${endpoint}`, { + params + }); targetList.value = response.data.data.map(item => ({ label: item.CMNCODNAM, value: item.CMNCODVAL, })); - }; onMounted(async () => { - await CommonCode("user", "color", colorList); - await CommonCode("user", "mbti", mbtiList); - await CommonCode("user", "pwhint", pwhintList); - await CommonCode("project", "yearCategory", yearCategory); - await CommonCode("worddict", "getWordCategory", cateList); + // 요청할 데이터가 옵션으로 전달 -> 그에 맞게 호출 + // color 옵션에 type 정보 포함 + if (options.loadColor) { + await CommonCode("user", "color", colorList, options.colorType); + } + if (options.loadMbti) await CommonCode("user", "mbti", mbtiList); + if (options.loadPwhint) await CommonCode("user", "pwhint", pwhintList); + if (options.loadYearCategory) await CommonCode("project", "yearCategory", yearCategory); + if (options.loadCateList) await CommonCode("worddict", "getWordCategory", cateList); }); return { colorList, mbtiList, pwhintList, yearCategory, cateList }; From c8ca8f936f275a0939c181684724d8c7cc49da86 Mon Sep 17 00:00:00 2001 From: yoon Date: Thu, 13 Feb 2025 14:46:38 +0900 Subject: [PATCH 04/12] =?UTF-8?q?=EC=A3=BC=EC=84=9D=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/commonApi.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/commonApi.js b/src/common/commonApi.js index 6049bd8..27a5a7f 100644 --- a/src/common/commonApi.js +++ b/src/common/commonApi.js @@ -29,7 +29,7 @@ const commonApi = (options = {}) => { onMounted(async () => { // 요청할 데이터가 옵션으로 전달 -> 그에 맞게 호출 - // color 옵션에 type 정보 포함 + // color 옵션에 type 포함 if (options.loadColor) { await CommonCode("user", "color", colorList, options.colorType); } From 2304c3d4d3e84a888b5aca4b1ac6c9d0770d62dc Mon Sep 17 00:00:00 2001 From: yoon Date: Thu, 13 Feb 2025 14:51:25 +0900 Subject: [PATCH 05/12] grayscaleImg --- public/css/custom.css | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/public/css/custom.css b/public/css/custom.css index 4123ecd..35ed370 100644 --- a/public/css/custom.css +++ b/public/css/custom.css @@ -92,4 +92,9 @@ top: 0px !important; left: 5px !important; text-align: left !important; - } \ No newline at end of file + } + + .grayscaleImg { + filter: grayscale(100%); + } + \ No newline at end of file From f7ca508a9cca330caeb63371bcdd4514b4b8195b Mon Sep 17 00:00:00 2001 From: dyhj625 Date: Thu, 13 Feb 2025 16:25:20 +0900 Subject: [PATCH 06/12] =?UTF-8?q?=ED=9C=B4=EA=B0=80=EA=B0=80=EB=A6=AC?= =?UTF-8?q?=EC=8A=A4=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(); From d71db81856d47e7473a625c97a6db90ea52b6031 Mon Sep 17 00:00:00 2001 From: Dang Date: Fri, 14 Feb 2025 11:02:45 +0900 Subject: [PATCH 07/12] =?UTF-8?q?=EC=9A=A9=EC=96=B4=EC=A7=91=20=EC=B9=B4?= =?UTF-8?q?=ED=85=8C=EA=B3=A0=EB=A6=AC=20=EB=93=B1=EB=A1=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/wordDict/DictWrite.vue | 14 +++++++------- src/views/wordDict/wordDict.vue | 25 +++++++++++++++++++------ 2 files changed, 26 insertions(+), 13 deletions(-) diff --git a/src/components/wordDict/DictWrite.vue b/src/components/wordDict/DictWrite.vue index 985c69d..3f4fc83 100644 --- a/src/components/wordDict/DictWrite.vue +++ b/src/components/wordDict/DictWrite.vue @@ -5,7 +5,7 @@ - props.dataList.map(item => ({ - label: item.CMNCODNAM, - value: item.CMNCODVAL - })) -); +// const formattedDataList = computed(() => +// props.dataList.map(item => ({ +// label: item.CMNCODNAM, +// value: item.CMNCODVAL +// })) +// ); // 카테고리 입력 창 const showInput = ref(false); diff --git a/src/views/wordDict/wordDict.vue b/src/views/wordDict/wordDict.vue index 11cb320..fefb2ee 100644 --- a/src/views/wordDict/wordDict.vue +++ b/src/views/wordDict/wordDict.vue @@ -45,9 +45,9 @@
@@ -69,7 +69,7 @@ import DictCard from '@/components/wordDict/DictCard.vue'; import DictWrite from '@/components/wordDict/DictWrite.vue'; import DictAlphabetFilter from '@/components/wordDict/DictAlphabetFilter.vue'; - import commonApi from '@/common/commonApi' + import commonApi from '@/common/commonApi'; import { useToastStore } from '@s/toastStore'; const { appContext } = getCurrentInstance(); @@ -88,8 +88,12 @@ const total = ref(0); // 카테고리 - const { cateList } = commonApi(); + const { cateList } = commonApi({ + loadCateList: true + }); const selectedCategory = ref(''); + const selectCategory = ref(''); + //선택된 알파벳 const selectedAlphabet = ref(''); @@ -156,15 +160,24 @@ const addCategory = (data) =>{ const lastCategory = cateList.value[cateList.value.length - 1]; const newValue = lastCategory ? parseInt(lastCategory.CMNCODVAL) + 1 : 600101; + console.log('lastCategory',lastCategory) + console.log('newValue',newValue) + axios.post('worddict/insertCategory',{ CMNCODNAM: data }).then(res => { if(res.data.data == '1'){ + console.log('res.data.data',res.data.data) + toastStore.onToast('카테고리가 추가 등록 되었습니다.', 's'); const newCategory = { CMNCODNAM: data, CMNCODVAL: newValue.toString() }; - cateList.value.unshift(newCategory); + console.log('newCategory',newCategory) + + cateList.value.unshift(newCategory.CMNCODNAM); selectCategory.value = newCategory.CMNCODVAL; + console.log(' selectCategory.value', selectCategory.value) + } }) } From 8e438ff9005c7b48836cfd99c8ffac5a2dc9b20d Mon Sep 17 00:00:00 2001 From: khj0414 Date: Fri, 14 Feb 2025 12:16:24 +0900 Subject: [PATCH 08/12] =?UTF-8?q?t=EC=9A=A9=EC=96=B4=EC=A7=91=EC=88=98?= =?UTF-8?q?=EC=A0=95=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/wordDict/wordDict.vue | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/src/views/wordDict/wordDict.vue b/src/views/wordDict/wordDict.vue index fefb2ee..f030567 100644 --- a/src/views/wordDict/wordDict.vue +++ b/src/views/wordDict/wordDict.vue @@ -61,7 +61,7 @@ diff --git a/src/components/button/SaveBtn.vue b/src/components/button/SaveBtn.vue new file mode 100644 index 0000000..7c8068a --- /dev/null +++ b/src/components/button/SaveBtn.vue @@ -0,0 +1,23 @@ + + + diff --git a/src/components/modal/VacationGrantModal.vue b/src/components/modal/VacationGrantModal.vue new file mode 100644 index 0000000..4d66368 --- /dev/null +++ b/src/components/modal/VacationGrantModal.vue @@ -0,0 +1,95 @@ + + + + + diff --git a/src/components/modal/VacationModal.vue b/src/components/modal/VacationModal.vue index 6e90f44..3a183c3 100644 --- a/src/components/modal/VacationModal.vue +++ b/src/components/modal/VacationModal.vue @@ -87,7 +87,7 @@ align-items: center; /* 스크롤 가능한 모달 */ .modal-content { -max-height: 80vh; +max-height: 60vh; overflow-y: auto; padding: 20px; width: 75%; diff --git a/src/components/vacation/ProfileList.vue b/src/components/vacation/ProfileList.vue index 32ffdd5..a0f267e 100644 --- a/src/components/vacation/ProfileList.vue +++ b/src/components/vacation/ProfileList.vue @@ -17,6 +17,9 @@ @error="setDefaultImage" @load="showImage" /> + + {{ remainingVacationData[user.MEMBERSEQ] || 0 }} +
@@ -30,6 +33,10 @@ defineEmits(["profileClick"]); + defineProps({ + remainingVacationData: Object, +}); + const userStore = useUserStore(); const userListStore = useUserListStore(); @@ -53,7 +60,6 @@ // 사용자별 색상 저장 userList.value.forEach(user => { userColors.value[user.MEMBERSEQ] = user.usercolor || "#ccc"; - console.log(userColors.value[user.MEMBERSEQ]) }); nextTick(() => { @@ -109,4 +115,12 @@ diff --git a/src/views/board/BoardList.vue b/src/views/board/BoardList.vue index 59f6e90..a5e4135 100644 --- a/src/views/board/BoardList.vue +++ b/src/views/board/BoardList.vue @@ -55,14 +55,14 @@