Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
W
WebFront
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
websystem
WebFront
Commits
00dc9115
Commit
00dc9115
authored
7 months ago
by
석찬 윤
Browse files
Options
Downloads
Plain Diff
Merge branch 'feat/
#14
' into 'main'
[
#14
] FCM 토큰 포함 로그인 로직 수정 See merge request
!25
parents
9d7d28b6
7a711862
No related branches found
No related tags found
1 merge request
!25
[#14] FCM 토큰 포함 로그인 로직 수정
Pipeline
#10928
failed
7 months ago
Stage: build
Stage: deploy
Changes
3
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/App.js
+2
-0
2 additions, 0 deletions
src/App.js
src/api/auth.js
+10
-1
10 additions, 1 deletion
src/api/auth.js
src/pages/NotFoundPage.jsx
+28
-0
28 additions, 0 deletions
src/pages/NotFoundPage.jsx
with
40 additions
and
1 deletion
src/App.js
+
2
−
0
View file @
00dc9115
...
...
@@ -11,6 +11,7 @@ import Footer from "./components/layout/Footer";
import
BodyLayout
from
"
./components/layout/BodyLayout
"
;
import
HeaderLogoBar
from
"
./components/layout/HeaderLogoBar
"
;
import
SchedulePage
from
"
./pages/SchedulePage
"
;
import
NotFoundPage
from
"
./pages/NotFoundPage
"
;
const
App
=
()
=>
{
return
(
...
...
@@ -29,6 +30,7 @@ const App = () => {
/
>
<
Route
path
=
"
/mypage
"
element
=
{
<
MyPage
/>
}
/
>
<
Route
path
=
"
/login
"
element
=
{
<
LoginPage
/>
}
/
>
<
Route
path
=
"
*
"
element
=
{
<
NotFoundPage
/>
}
/
>
<
/Routes
>
<
/BodyLayout
>
<
Footer
/>
...
...
This diff is collapsed.
Click to expand it.
src/api/auth.js
+
10
−
1
View file @
00dc9115
...
...
@@ -5,7 +5,16 @@
* @returns {string} 로그인 엔드포인트 URL
*/
export
const
getLoginUrl
=
()
=>
{
return
`
${
process
.
env
.
REACT_APP_BASE_URL
}
/api/auth/login`
;
const
baseUrl
=
process
.
env
.
REACT_APP_BASE_URL
;
const
fcmToken
=
localStorage
.
getItem
(
"
fcmToken
"
);
// fcmToken이 있을 경우 파라미터에 추가
const
params
=
new
URLSearchParams
();
if
(
fcmToken
)
{
params
.
append
(
"
fcmToken
"
,
fcmToken
);
}
return
`
${
baseUrl
}
/api/auth/login?
${
params
.
toString
()}
`
;
};
/**
...
...
This diff is collapsed.
Click to expand it.
src/pages/NotFoundPage.jsx
0 → 100644
+
28
−
0
View file @
00dc9115
import
React
from
"
react
"
;
import
{
useNavigate
}
from
"
react-router-dom
"
;
import
Button
from
"
../components/Button
"
;
// 기존 디자인 시스템의 버튼 컴포넌트
const
NotFoundPage
=
()
=>
{
const
navigate
=
useNavigate
();
const
handleGoHome
=
()
=>
{
navigate
(
"
/
"
);
};
return
(
<
div
className
=
"flex flex-col items-center justify-center min-h-screen text-center bg-gray-50"
>
<
h1
className
=
"text-6xl font-bold text-primary-500"
>
404
</
h1
>
<
p
className
=
"mt-4 text-lg text-gray-700"
>
페이지를 찾을 수 없습니다. 잘못된 URL을 입력했거나 페이지가 삭제되었을
수 있습니다.
</
p
>
<
div
className
=
"mt-6"
>
<
Button
size
=
"lg"
theme
=
"indigo"
onClick
=
{
handleGoHome
}
>
홈으로 이동
</
Button
>
</
div
>
</
div
>
);
};
export
default
NotFoundPage
;
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment