From e4455e94e562edfc1213de23e2f10cd4ff752d3e Mon Sep 17 00:00:00 2001 From: dyhj625 Date: Tue, 11 Feb 2025 16:18:05 +0900 Subject: [PATCH 1/4] =?UTF-8?q?=ED=9C=B4=EA=B0=80=20=EC=82=AC=EC=9B=90?= =?UTF-8?q?=EB=A6=AC=EC=8A=A4=ED=8A=B8=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/vacation/ProfileList.vue | 103 +++++++++++++++------- src/views/vacation/VacationManagement.vue | 14 ++- 2 files changed, 74 insertions(+), 43 deletions(-) diff --git a/src/components/vacation/ProfileList.vue b/src/components/vacation/ProfileList.vue index 32e7ce0..b7947a9 100644 --- a/src/components/vacation/ProfileList.vue +++ b/src/components/vacation/ProfileList.vue @@ -12,7 +12,7 @@ @click="toggleDisable(index)" data-bs-toggle="tooltip" data-popup="tooltip-custom" - data-bs-placement="top" + data-bs-placement="bottom" :aria-label="user.MEMBERSEQ" :data-bs-original-title="getTooltipTitle(user)" > @@ -41,11 +41,10 @@ const emit = defineEmits(); const userStore = useUserStore(); const userList = ref([]); - const userListContainer = ref(null); // 프로필 목록 컨테이너 참조 + const userListContainer = ref(null); const baseUrl = $api.defaults.baseURL.replace(/api\/$/, ""); - const defaultProfile = "/img/icons/icon.png"; // 기본 이미지 경로 + const defaultProfile = "/img/icons/icon.png"; - // ✅ 사용자 목록 호출 onMounted(async () => { await userStore.fetchUserList(); userList.value = userStore.userList; @@ -57,77 +56,78 @@ }); }); - // ✅ 프로필 이미지 경로 반환 const getUserProfileImage = (profilePath) => { return profilePath && profilePath.trim() ? `${baseUrl}upload/img/profile/${profilePath}` : defaultProfile; }; - // ✅ 이미지 로딩 오류 처리 const setDefaultImage = (event) => { event.target.src = defaultProfile; }; - // ✅ 이미지 로드 후 깜빡임 방지 const showImage = (event) => { event.target.style.visibility = "visible"; }; - // ✅ 툴팁 타이틀 설정 const getTooltipTitle = (user) => { return user.MEMBERSEQ === userList.value.MEMBERSEQ ? "나" : user.MEMBERNAM; }; - // ✅ 좌우 스크롤 이동 기능 추가 (한 줄씩 이동) + const scrollAmount = 9 * 100; + const scrollLeft = () => { - userListContainer.value.scrollBy({ left: -userListContainer.value.clientWidth, behavior: "smooth" }); + userListContainer.value.scrollBy({ left: -scrollAmount, behavior: "smooth" }); }; const scrollRight = () => { - userListContainer.value.scrollBy({ left: userListContainer.value.clientWidth, behavior: "smooth" }); + userListContainer.value.scrollBy({ left: scrollAmount, behavior: "smooth" }); }; diff --git a/src/views/vacation/VacationManagement.vue b/src/views/vacation/VacationManagement.vue index 47cc56c..f267dc0 100644 --- a/src/views/vacation/VacationManagement.vue +++ b/src/views/vacation/VacationManagement.vue @@ -5,23 +5,19 @@
+
+
- - - - - -
From cfa46c0a6d3f074ca3d58e4fef71e47ed50837c6 Mon Sep 17 00:00:00 2001 From: nevermoregb Date: Thu, 13 Feb 2025 11:54:38 +0900 Subject: [PATCH 2/4] =?UTF-8?q?=EA=B0=9C=EB=B0=9C=EC=9A=A9=EB=8F=84?= =?UTF-8?q?=EC=9D=98=20=EC=BF=A0=ED=82=A4=20=EC=84=B8=ED=8C=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.dev | 5 +++++ src/common/axios-interceptor.js | 17 ++++++++-------- src/components/user/LoginForm.vue | 32 +++++++++++++++---------------- 3 files changed, 29 insertions(+), 25 deletions(-) create mode 100644 .env.dev diff --git a/.env.dev b/.env.dev new file mode 100644 index 0000000..99081c1 --- /dev/null +++ b/.env.dev @@ -0,0 +1,5 @@ +VITE_DOMAIN = http://localhost:5173/ +# VITE_LOGIN_URL = http://localhost:10325/ms/ +# VITE_FILE_URL = http://localhost:10325/ms/ +# VITE_API_URL = http://localhost:10325/api/ +VITE_API_URL = http://localhost:10325/test/ \ No newline at end of file diff --git a/src/common/axios-interceptor.js b/src/common/axios-interceptor.js index 05f3abd..a6ae5a1 100644 --- a/src/common/axios-interceptor.js +++ b/src/common/axios-interceptor.js @@ -1,12 +1,12 @@ -import axios from "axios"; +import axios from 'axios'; import { useRoute } from 'vue-router'; import { useToastStore } from '@s/toastStore'; const $api = axios.create({ baseURL: 'http://localhost:10325/api/', timeout: 300000, - withCredentials : true -}) + withCredentials: true, +}); /** * Default Content-Type : json @@ -14,7 +14,6 @@ const $api = axios.create({ */ $api.interceptors.request.use( function (config) { - let contentType = 'application/json'; if (config.isFormData) contentType = 'multipart/form-data'; @@ -23,21 +22,21 @@ $api.interceptors.request.use( config.headers['X-Requested-With'] = 'XMLHttpRequest'; return config; - }, function (error) { + }, + function (error) { // 요청 오류가 있는 작업 수행 return Promise.reject(error); - } + }, ); // 응답 인터셉터 추가하기 $api.interceptors.response.use( - function (response) { // 2xx 범위의 응답 처리 return response; }, function (error) { - const toastStore = useToastStore() + const toastStore = useToastStore(); const currentPage = error.config.headers['X-Page-Route']; // 오류 응답 처리 if (error.response) { @@ -70,7 +69,7 @@ $api.interceptors.response.use( } return Promise.reject(error); - } + }, ); export default $api; diff --git a/src/components/user/LoginForm.vue b/src/components/user/LoginForm.vue index 55b1e4a..48a3c77 100644 --- a/src/components/user/LoginForm.vue +++ b/src/components/user/LoginForm.vue @@ -1,14 +1,7 @@