From a80479a163af15c3ba23d29dad4e9aa45df1b4da Mon Sep 17 00:00:00 2001 From: Sumin Hwang <163857590+tnals0924@users.noreply.github.com> Date: Sun, 18 May 2025 15:08:44 +0900 Subject: [PATCH 01/16] =?UTF-8?q?chore:=20prod=20=ED=99=98=EA=B2=BD=20?= =?UTF-8?q?=EB=B8=8C=EB=9E=9C=EC=B9=98=20main=EC=9C=BC=EB=A1=9C=20?= =?UTF-8?q?=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/autoSync.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/autoSync.yml b/.github/workflows/autoSync.yml index 9e0f29b..5cf9763 100644 --- a/.github/workflows/autoSync.yml +++ b/.github/workflows/autoSync.yml @@ -2,7 +2,7 @@ name: Synchronize to forked repo on: push: branches: - - develop + - main jobs: sync: @@ -10,12 +10,12 @@ jobs: runs-on: ubuntu-latest steps: - - name: Checkout develop + - name: Checkout main uses: actions/checkout@v4 with: token: ${{ secrets.AUTO_SYNC_TOKEN }} fetch-depth: 0 - ref: develop + ref: main - name: Add remote-url run: | @@ -25,7 +25,7 @@ jobs: - name: Push changes to forked-repo run: | - git push -f forked-repo develop + git push -f forked-repo main - name: Clean up run: | From 4688e4589ce8d3a9a7e4c1d1275bca51d7c748a7 Mon Sep 17 00:00:00 2001 From: Sumin Hwang <163857590+tnals0924@users.noreply.github.com> Date: Wed, 21 May 2025 16:39:35 +0900 Subject: [PATCH 02/16] =?UTF-8?q?chore:=20=EB=B0=B0=ED=8F=AC=20=EB=B2=84?= =?UTF-8?q?=EC=A0=84=20auto=20sync=20actions=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/autoSync-develop.yml | 32 +++++++++++++++++++ .../{autoSync.yml => autoSync-main.yml} | 2 +- 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/autoSync-develop.yml rename .github/workflows/{autoSync.yml => autoSync-main.yml} (94%) diff --git a/.github/workflows/autoSync-develop.yml b/.github/workflows/autoSync-develop.yml new file mode 100644 index 0000000..1df8e65 --- /dev/null +++ b/.github/workflows/autoSync-develop.yml @@ -0,0 +1,32 @@ +name: (Develop) Synchronize to forked repo +on: + push: + branches: + - develop + +jobs: + sync: + name: Sync forked repo + runs-on: ubuntu-latest + + steps: + - name: Checkout develop + uses: actions/checkout@v4 + with: + token: ${{ secrets.DEV_AUTO_SYNC_TOKEN }} + fetch-depth: 0 + ref: develop + + - name: Add remote-url + run: | + git remote add forked-repo https://hyeonjin6530:${{ secrets.DEV_AUTO_SYNC_TOKEN }}@github.com/hyeonjin6530/billilge-frontend + git config user.name hyeonjin6530 + git config user.email ${{ secrets.DEV_EMAIL }} + + - name: Push changes to forked-repo + run: | + git push -f forked-repo develop + + - name: Clean up + run: | + git remote remove forked-repo diff --git a/.github/workflows/autoSync.yml b/.github/workflows/autoSync-main.yml similarity index 94% rename from .github/workflows/autoSync.yml rename to .github/workflows/autoSync-main.yml index 5cf9763..f5f1a89 100644 --- a/.github/workflows/autoSync.yml +++ b/.github/workflows/autoSync-main.yml @@ -1,4 +1,4 @@ -name: Synchronize to forked repo +name: (Main) Synchronize to forked repo on: push: branches: From 04a8bf18bfafdf3db7d993727df00bb9f65903fa Mon Sep 17 00:00:00 2001 From: Sinji Date: Wed, 21 May 2025 16:53:21 +0900 Subject: [PATCH 03/16] =?UTF-8?q?refactor:=20=EB=8C=80=EC=8B=9C=EB=B3=B4?= =?UTF-8?q?=EB=93=9C=20=ED=8E=98=EC=9D=B4=EC=A7=80=20=EB=82=B4=20=EC=8B=A0?= =?UTF-8?q?=EC=B2=AD=20=EC=8B=9C=EA=B0=84=20->=20=EB=8C=80=EC=97=AC=20?= =?UTF-8?q?=EC=8B=9C=EA=B0=84=EC=9C=BC=EB=A1=9C=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mobile/admin/dashboard/_components/DashboardItem.tsx | 6 +++--- src/app/mobile/admin/dashboard/page.tsx | 2 +- src/types/dashboardType.ts | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx b/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx index ef74f0f..4a9c8cf 100644 --- a/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx +++ b/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx @@ -9,7 +9,7 @@ export default function DashboardItem({ renterName, studentId, status, - applicatedAt, + rentAt, rentedCount, handleApproveBtnClick, handleCancelBtnClick, @@ -29,7 +29,7 @@ export default function DashboardItem({ handleCancelBtnClick(); }; - const applicatedTime = convertTime(applicatedAt); + const applicatedTime = convertTime(rentAt); return (
@@ -59,7 +59,7 @@ export default function DashboardItem({
-
신청 시간
+
대여 시간
{applicatedTime.formattedDate} {applicatedTime.formattedTime}
diff --git a/src/app/mobile/admin/dashboard/page.tsx b/src/app/mobile/admin/dashboard/page.tsx index 69fc4cc..8afcfe7 100644 --- a/src/app/mobile/admin/dashboard/page.tsx +++ b/src/app/mobile/admin/dashboard/page.tsx @@ -139,7 +139,7 @@ export default function Dashboard() { renterName={item.renterName} studentId={item.studentId} status={item.status} - applicatedAt={item.applicatedAt} + rentAt={item.rentAt} rentedCount={item.rentedCount} handleApproveBtnClick={() => { if (item.rentalHistoryId !== undefined) { diff --git a/src/types/dashboardType.ts b/src/types/dashboardType.ts index 8598a26..5afa7f5 100644 --- a/src/types/dashboardType.ts +++ b/src/types/dashboardType.ts @@ -5,7 +5,7 @@ export interface DashboardProps { renterName: string; studentId: string; status: string; - applicatedAt: string; + rentAt: string; rentedCount: number; handleApproveBtnClick: () => void; handleCancelBtnClick: () => void; From 037c46c643ac6649d6a7f79088a6695592496c6b Mon Sep 17 00:00:00 2001 From: Sinji Date: Sun, 25 May 2025 22:56:07 +0900 Subject: [PATCH 04/16] =?UTF-8?q?fix:=20=EB=8C=80=EC=8B=9C=EB=B3=B4?= =?UTF-8?q?=EB=93=9C=20=EC=8B=9C=EA=B0=84=20=EC=B4=88=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/mobile/admin/dashboard/_components/DashboardItem.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx b/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx index 4a9c8cf..a80f549 100644 --- a/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx +++ b/src/app/mobile/admin/dashboard/_components/DashboardItem.tsx @@ -61,7 +61,8 @@ export default function DashboardItem({
대여 시간
- {applicatedTime.formattedDate} {applicatedTime.formattedTime} + {applicatedTime.formattedDate}{' '} + {applicatedTime.formattedTime.split(':').slice(0, 2).join(':')}
From a04303a409acebc5933fa8ff7762a62c7bb06f9a Mon Sep 17 00:00:00 2001 From: Sinji Date: Mon, 26 May 2025 00:05:16 +0900 Subject: [PATCH 05/16] =?UTF-8?q?feat:=20=EC=82=AC=EC=9A=A9=EC=9E=90=20?= =?UTF-8?q?=EC=95=8C=EB=A6=BC=20=EB=AA=A8=EB=91=90=20=EC=9D=BD=EC=9D=8C?= =?UTF-8?q?=EC=9C=BC=EB=A1=9C=20=ED=91=9C=EC=8B=9C=20=EB=B2=84=ED=8A=BC=20?= =?UTF-8?q?=EC=83=9D=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/mobile/notification/page.tsx | 51 ++++++++++++++++++---------- src/services/notification.ts | 18 ++++++++-- 2 files changed, 50 insertions(+), 19 deletions(-) diff --git a/src/app/mobile/notification/page.tsx b/src/app/mobile/notification/page.tsx index 9430976..5ebe2d3 100644 --- a/src/app/mobile/notification/page.tsx +++ b/src/app/mobile/notification/page.tsx @@ -5,7 +5,8 @@ import { useRouter } from 'next/navigation'; import MobileLayout from '@/components/mobile/layout'; import { userNotificationGet, - readNotificationPost, + readNotificationPatch, + readNotificationAllPatch, } from '@/services/notification'; import NotificationItem from '@/components/mobile/NotificationItem'; import Header from '@/components/mobile/Header'; @@ -39,10 +40,13 @@ export default function Notification() { fetchNotifications(); }, []); - // TODO : 로그인 여부 확인 후 로그인 안 했으면 로그인 화면으로 보내기 - const handleReadNotification = async (notificationId: number) => { - await readNotificationPost(notificationId); + await readNotificationPatch(notificationId); + }; + + const handleClickAllNotification = async () => { + await readNotificationAllPatch(); + window.location.reload(); }; return ( @@ -53,19 +57,32 @@ export default function Notification() { 현재 알림이 없습니다. ) : ( - notificationDetail.map((item) => ( - - item.notificationId && handleReadNotification(item.notificationId) - } - /> - )) +
+
+ +
+ + {notificationDetail.map((item) => ( + + item.notificationId && + handleReadNotification(item.notificationId) + } + /> + ))} +
)} ); diff --git a/src/services/notification.ts b/src/services/notification.ts index 5770f96..2778aeb 100644 --- a/src/services/notification.ts +++ b/src/services/notification.ts @@ -18,7 +18,7 @@ const adminNotificationGet = async () => { } }; -const readNotificationPost = async (notificationId: number) => { +const readNotificationPatch = async (notificationId: number) => { try { const response = await PrivateAxiosInstance.patch( `notifications/${notificationId}`, @@ -29,4 +29,18 @@ const readNotificationPost = async (notificationId: number) => { } }; -export { adminNotificationGet, userNotificationGet, readNotificationPost }; +const readNotificationAllPatch = async () => { + try { + const response = await PrivateAxiosInstance.patch('notifications/all'); + return response.data; + } catch (error) { + return []; + } +}; + +export { + adminNotificationGet, + readNotificationAllPatch, + readNotificationPatch, + userNotificationGet, +}; From d757680e769bfdacb4c609ef94f77840f068e854 Mon Sep 17 00:00:00 2001 From: Sinji Date: Mon, 26 May 2025 00:08:06 +0900 Subject: [PATCH 06/16] =?UTF-8?q?fix:=20=EB=84=A4=EC=9D=B4=EB=B0=8D=20?= =?UTF-8?q?=EB=B3=80=EA=B2=BD=EC=9C=BC=EB=A1=9C=20=EC=9D=B8=ED=95=9C=20?= =?UTF-8?q?=EC=96=B4=EB=93=9C=EB=AF=BC=20=EC=95=8C=EB=A6=BC=20=EC=98=A4?= =?UTF-8?q?=EB=A5=98=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/mobile/admin/notification/page.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app/mobile/admin/notification/page.tsx b/src/app/mobile/admin/notification/page.tsx index d46a9f4..61084ab 100644 --- a/src/app/mobile/admin/notification/page.tsx +++ b/src/app/mobile/admin/notification/page.tsx @@ -8,7 +8,7 @@ import { elapsedTime } from '@/utils/elapsedTime'; import { NotificationProps } from '@/types/notificationType'; import { adminNotificationGet, - readNotificationPost, + readNotificationPatch, } from '@/services/notification'; type AdminNotificationType = NotificationProps; @@ -28,7 +28,7 @@ export default function Notification() { }, []); const handleReadNotification = async (notificationId: number) => { - await readNotificationPost(notificationId); + await readNotificationPatch(notificationId); }; return ( From a84927c07aaccc5d7fb21e230a47457f131ad07f Mon Sep 17 00:00:00 2001 From: hyeonjin6530 Date: Sat, 31 May 2025 19:29:14 +0900 Subject: [PATCH 07/16] =?UTF-8?q?refactor:=20=EB=AA=A8=EB=B0=94=EC=9D=BC?= =?UTF-8?q?=20=EB=A0=88=EC=9D=B4=EC=95=84=EC=9B=83=20=EC=BB=B4=ED=8F=AC?= =?UTF-8?q?=EB=84=8C=ED=8A=B8=20->=20=ED=8E=98=EC=9D=B4=EC=A7=80=20?= =?UTF-8?q?=EB=A0=88=EC=9D=B4=EC=95=84=EC=9B=83=EC=9C=BC=EB=A1=9C=20?= =?UTF-8?q?=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/mobile/admin/dashboard/page.tsx | 5 ++- src/app/mobile/admin/notification/page.tsx | 5 ++- src/app/mobile/history/page.tsx | 5 ++- src/app/mobile/layout.tsx | 42 ++++++++++++++++++++++ src/app/mobile/main/page.tsx | 5 ++- src/app/mobile/notification/page.tsx | 5 ++- src/app/mobile/privacy-policy/page.tsx | 5 ++- src/components/mobile/layout/index.tsx | 31 ---------------- 8 files changed, 54 insertions(+), 49 deletions(-) create mode 100644 src/app/mobile/layout.tsx delete mode 100644 src/components/mobile/layout/index.tsx diff --git a/src/app/mobile/admin/dashboard/page.tsx b/src/app/mobile/admin/dashboard/page.tsx index 8afcfe7..42b229d 100644 --- a/src/app/mobile/admin/dashboard/page.tsx +++ b/src/app/mobile/admin/dashboard/page.tsx @@ -1,7 +1,6 @@ 'use client'; import { useState, useEffect } from 'react'; -import MobileLayout from '@/components/mobile/layout'; import Header from '@/components/mobile/Header'; import Dropdown from '@/components/mobile/Dropdown'; import useDropdown from '@/hooks/useDropdown'; @@ -104,7 +103,7 @@ export default function Dashboard() { }; return ( - +
@@ -171,6 +170,6 @@ export default function Dashboard() { hideDropdown={hideDropdown} positionClasses="top-[80px] right-5" /> - +
); } diff --git a/src/app/mobile/admin/notification/page.tsx b/src/app/mobile/admin/notification/page.tsx index 61084ab..3c8f229 100644 --- a/src/app/mobile/admin/notification/page.tsx +++ b/src/app/mobile/admin/notification/page.tsx @@ -1,7 +1,6 @@ 'use client'; import { useEffect, useState } from 'react'; -import MobileLayout from '@/components/mobile/layout'; import NotificationItem from '@/components/mobile/NotificationItem'; import Header from '@/components/mobile/Header'; import { elapsedTime } from '@/utils/elapsedTime'; @@ -32,7 +31,7 @@ export default function Notification() { }; return ( - +
{notificationDetail?.length === 0 ? (
@@ -53,6 +52,6 @@ export default function Notification() { /> )) )} - +
); } diff --git a/src/app/mobile/history/page.tsx b/src/app/mobile/history/page.tsx index b884577..1d9ce7c 100644 --- a/src/app/mobile/history/page.tsx +++ b/src/app/mobile/history/page.tsx @@ -1,7 +1,6 @@ 'use client'; import { useEffect, useState, useMemo } from 'react'; -import MobileLayout from '@/components/mobile/layout'; import Header from '@/components/mobile/Header'; import ReturnItem from '@/app/mobile/history/_components/ReturnItem'; import RentalItem from '@/app/mobile/history/_components/RentalItem'; @@ -194,7 +193,7 @@ export default function UserRentalList() { ); return ( - +
{/* 반납이 필요한 물품 */} @@ -287,6 +286,6 @@ export default function UserRentalList() {
© wink
-
+ ); } diff --git a/src/app/mobile/layout.tsx b/src/app/mobile/layout.tsx new file mode 100644 index 0000000..a26f7be --- /dev/null +++ b/src/app/mobile/layout.tsx @@ -0,0 +1,42 @@ +'use client'; + +import useAuthRedirect from '@/hooks/useAuthRedirect'; +import React, { useEffect } from 'react'; +import { usePathname } from 'next/navigation'; + +export default function MobileLayout({ + children, +}: { + children: React.ReactNode; +}) { + const pathname = usePathname(); + + // 제외할 경로 목록 + const excludedRoutes = ['/mobile/sign-in', '/mobile/sign-up']; + + const isExcluded = excludedRoutes.includes(pathname); + + useAuthRedirect(); + + useEffect(() => { + if (!isExcluded) { + const originalBgColor = document.body.style.backgroundColor; + document.body.style.backgroundColor = '#F3F4F6'; + + return () => { + document.body.style.backgroundColor = originalBgColor; + }; + } + }, [isExcluded]); + + if (isExcluded) { + // 레이아웃 없이 children만 렌더링 + return children; + } + + return ( +
+
{children}
+
+ ); +} diff --git a/src/app/mobile/main/page.tsx b/src/app/mobile/main/page.tsx index 2a1897f..a752d80 100644 --- a/src/app/mobile/main/page.tsx +++ b/src/app/mobile/main/page.tsx @@ -1,7 +1,6 @@ 'use client'; import { useEffect, useState } from 'react'; -import MobileLayout from '@/components/mobile/layout'; import MainHeader from '@/app/mobile/main/_components/MainHeader'; import Carousel from '@/app/mobile/main/_components/Carousel'; import WelfareItem from '@/app/mobile/main/_components/WelfareItem'; @@ -77,7 +76,7 @@ export default function MobileMain() { }; return ( - +
@@ -129,6 +128,6 @@ export default function MobileMain() { onCloseAction={() => setIsBottomSheetOpen(false)} item={selectedItem} /> - +
); } diff --git a/src/app/mobile/notification/page.tsx b/src/app/mobile/notification/page.tsx index 5ebe2d3..a1a0e8f 100644 --- a/src/app/mobile/notification/page.tsx +++ b/src/app/mobile/notification/page.tsx @@ -2,7 +2,6 @@ import { useState, useEffect } from 'react'; import { useRouter } from 'next/navigation'; -import MobileLayout from '@/components/mobile/layout'; import { userNotificationGet, readNotificationPatch, @@ -50,7 +49,7 @@ export default function Notification() { }; return ( - +
{notificationDetail?.length === 0 ? (
@@ -84,6 +83,6 @@ export default function Notification() { ))}
)} - +
); } diff --git a/src/app/mobile/privacy-policy/page.tsx b/src/app/mobile/privacy-policy/page.tsx index 4b80c03..60772dc 100644 --- a/src/app/mobile/privacy-policy/page.tsx +++ b/src/app/mobile/privacy-policy/page.tsx @@ -1,12 +1,11 @@ 'use client'; -import MobileLayout from '@/components/mobile/layout'; import Header from '@/components/mobile/Header'; import privacyPolicy from './privacyPolicyData'; export default function UserRentalList() { return ( - +
{/* 반납이 필요한 물품 */} @@ -42,6 +41,6 @@ export default function UserRentalList() {
© wink
- +
); } diff --git a/src/components/mobile/layout/index.tsx b/src/components/mobile/layout/index.tsx deleted file mode 100644 index 2fe616b..0000000 --- a/src/components/mobile/layout/index.tsx +++ /dev/null @@ -1,31 +0,0 @@ -'use client'; - -import useAuthRedirect from '@/hooks/useAuthRedirect'; -import React, { useEffect } from 'react'; - -interface MobileLayoutProps { - children: React.ReactNode; -} - -export default function MobileLayout({ children }: MobileLayoutProps) { - useAuthRedirect(); - - useEffect(() => { - // 기존 body 배경색 저장 - const originalBgColor = document.body.style.backgroundColor; - - // MobileLayout이 마운트될 때 배경색 적용(모바일에서만 적용하기 위함) - document.body.style.backgroundColor = '#F3F4F6'; - - return () => { - // MobileLayout이 언마운트될 때 원래 배경색 복구 - document.body.style.backgroundColor = originalBgColor; - }; - }, []); - - return ( -
-
{children}
-
- ); -} From e5fd59bd563084d4c8304f8db2239c7093861cda Mon Sep 17 00:00:00 2001 From: hyeonjin6530 Date: Sat, 31 May 2025 19:31:04 +0900 Subject: [PATCH 08/16] =?UTF-8?q?style:=20padding=20bottom=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 --- src/app/mobile/main/page.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/mobile/main/page.tsx b/src/app/mobile/main/page.tsx index a752d80..ca7bf29 100644 --- a/src/app/mobile/main/page.tsx +++ b/src/app/mobile/main/page.tsx @@ -78,7 +78,7 @@ export default function MobileMain() { return (
-
+
From 834bb4f8e393316d882d53452ed4c44c54c3df94 Mon Sep 17 00:00:00 2001 From: hyeonjin6530 Date: Sat, 31 May 2025 19:44:33 +0900 Subject: [PATCH 09/16] =?UTF-8?q?feat:=20=EC=82=AC=EC=9D=B4=EB=93=9C?= =?UTF-8?q?=EB=A9=94=EB=89=B4=EC=97=90=20=EA=B4=80=EB=A6=AC=EC=9E=90=20?= =?UTF-8?q?=ED=99=88=ED=8E=98=EC=9D=B4=EC=A7=80=EB=A1=9C=20=EC=9D=B4?= =?UTF-8?q?=EB=8F=99=ED=95=98=EB=8A=94=20=ED=95=AD=EB=AA=A9=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 --- .../assets/icons/side-menu/admin-homepage.svg | 120 ++++++++++++++++++ src/components/mobile/SidebarMenu/index.tsx | 7 + 2 files changed, 127 insertions(+) create mode 100644 public/assets/icons/side-menu/admin-homepage.svg diff --git a/public/assets/icons/side-menu/admin-homepage.svg b/public/assets/icons/side-menu/admin-homepage.svg new file mode 100644 index 0000000..beccd3c --- /dev/null +++ b/public/assets/icons/side-menu/admin-homepage.svg @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/components/mobile/SidebarMenu/index.tsx b/src/components/mobile/SidebarMenu/index.tsx index 6a9c60c..6d2ccb5 100644 --- a/src/components/mobile/SidebarMenu/index.tsx +++ b/src/components/mobile/SidebarMenu/index.tsx @@ -8,6 +8,7 @@ import IconAdminDashboard from 'public/assets/icons/side-menu/admin-dashboard.sv import IconAdminAlarm from 'public/assets/icons/side-menu/admin-alarm.svg'; import IconLogout from 'public/assets/icons/side-menu/logout.svg'; import IconPrivacyPolicy from 'public/assets/icons/side-menu/privacy-policy.svg'; +import IconAdminHomepage from 'public/assets/icons/side-menu/admin-homepage.svg'; import { useRouter } from 'next/navigation'; interface SidebarProps { @@ -22,6 +23,7 @@ const menuItems = [ { icon: IconUserAlarm, label: '알림', href: '/mobile/notification' }, ]; +// TODO: 관리자 홈페이지 링크 변경 const adminItems = [ { icon: IconAdminDashboard, @@ -33,6 +35,11 @@ const adminItems = [ label: '관리자 알림', href: '/mobile/admin/notification', }, + { + icon: IconAdminHomepage, + label: '관리자 홈페이지', + href: '/mobile/admin/notification', + }, ]; export default function Sidebar({ From a86e02b8a102502aa1319a078361ff07c57a0ac6 Mon Sep 17 00:00:00 2001 From: hyeonjin6530 Date: Sat, 31 May 2025 19:53:49 +0900 Subject: [PATCH 10/16] =?UTF-8?q?feat:=20=EA=B4=80=EB=A6=AC=EC=9E=90=20?= =?UTF-8?q?=ED=99=88=ED=8E=98=EC=9D=B4=EC=A7=80=20=EB=A7=81=ED=81=AC=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80=20=EB=B0=8F=20=EC=83=88=EC=B0=BD=EC=9C=BC?= =?UTF-8?q?=EB=A1=9C=20=EC=97=B4=EB=A6=AC=EB=8F=84=EB=A1=9D=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/mobile/SidebarMenu/index.tsx | 30 ++++++++++++--------- 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/src/components/mobile/SidebarMenu/index.tsx b/src/components/mobile/SidebarMenu/index.tsx index 6d2ccb5..cb71a16 100644 --- a/src/components/mobile/SidebarMenu/index.tsx +++ b/src/components/mobile/SidebarMenu/index.tsx @@ -38,7 +38,7 @@ const adminItems = [ { icon: IconAdminHomepage, label: '관리자 홈페이지', - href: '/mobile/admin/notification', + href: 'https://www.billilge.site/desktop/login', }, ]; @@ -103,17 +103,23 @@ export default function Sidebar({ {role === 'ADMIN' && ( <>
    - {adminItems.map(({ icon: Icon, label, href }) => ( -
  • - - - {label} - -
  • - ))} + {adminItems.map(({ icon: Icon, label, href }) => { + const isExternal = label === '관리자 홈페이지'; + + return ( +
  • + + + {label} + +
  • + ); + })}
{/* 두 번째 구분선 */} From 8dff80851e981cddf5783daa5896c7fe36a7f820 Mon Sep 17 00:00:00 2001 From: hyeonjin6530 Date: Sun, 1 Jun 2025 01:44:42 +0900 Subject: [PATCH 11/16] =?UTF-8?q?feat:=20=EA=B3=B5=EC=A7=80=EC=82=AC?= =?UTF-8?q?=ED=95=AD=20=ED=8C=9D=EC=97=85=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/mobile/main/page.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/app/mobile/main/page.tsx b/src/app/mobile/main/page.tsx index ca7bf29..2bd834b 100644 --- a/src/app/mobile/main/page.tsx +++ b/src/app/mobile/main/page.tsx @@ -50,7 +50,7 @@ export default function MobileMain() { requestNotificationPermission(); // "다시 보지 않기" 플래그가 없으면 팝업 표시 - if (!localStorage.getItem('popUpDismissed2')) { + if (!localStorage.getItem('popUpDismissed3')) { setShowPopUp(true); } }, []); @@ -112,11 +112,11 @@ export default function MobileMain() { {showPopUp && ( setShowPopUp(false)} onClickOther={() => { - localStorage.setItem('popUpDismissed2', 'true'); + localStorage.setItem('popUpDismissed3', 'true'); setShowPopUp(false); }} /> From 042b4da1e6e175633535309757ff470c2606939f Mon Sep 17 00:00:00 2001 From: hyeonjin6530 Date: Sun, 1 Jun 2025 01:51:54 +0900 Subject: [PATCH 12/16] =?UTF-8?q?feat:=20=ED=95=99=EC=83=9D=ED=9A=8C?= =?UTF-8?q?=EB=B9=84=20=EB=82=A9=EB=B6=80=EC=8B=9C=20=EC=9D=B4=EB=A6=84=20?= =?UTF-8?q?=EC=98=86=EC=97=90=20=EC=B2=B4=ED=81=AC=20=ED=91=9C=EC=8B=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/assets/icons/icon-fee-check.svg | 89 +++++++++++++++++++ .../main/_components/MainHeader/index.tsx | 6 +- src/utils/loginHandler.ts | 14 ++- 3 files changed, 105 insertions(+), 4 deletions(-) create mode 100644 public/assets/icons/icon-fee-check.svg diff --git a/public/assets/icons/icon-fee-check.svg b/public/assets/icons/icon-fee-check.svg new file mode 100644 index 0000000..467d061 --- /dev/null +++ b/public/assets/icons/icon-fee-check.svg @@ -0,0 +1,89 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/app/mobile/main/_components/MainHeader/index.tsx b/src/app/mobile/main/_components/MainHeader/index.tsx index b46936b..6a5006f 100644 --- a/src/app/mobile/main/_components/MainHeader/index.tsx +++ b/src/app/mobile/main/_components/MainHeader/index.tsx @@ -5,6 +5,7 @@ import Sidebar from '@/components/mobile/SidebarMenu/index'; import { useEffect, useState } from 'react'; import IconAlarm from 'public/assets/icons/icon-alarm.svg'; import IconHamburger from 'public/assets/icons/icon-hamburger.svg'; +import IconFeeCheck from 'public/assets/icons/icon-fee-check.svg'; import { getNotificationCount } from '@/apis/notification'; export default function MainHeader() { @@ -15,6 +16,7 @@ export default function MainHeader() { name: string; id: string; role: string; + isFeePaid: boolean; } | null>(null); useEffect(() => { @@ -40,8 +42,8 @@ export default function MainHeader() { return ( <>
-
- {user?.name}님 +
+ {user?.name}님{user?.isFeePaid ? : null}