-
Notifications
You must be signed in to change notification settings - Fork 1.1k
feat: 알림 목록 페이지 구현 (Notification Page) #90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
parksinhae
wants to merge
14
commits into
callicoder:master
from
eunhye-ahn:frontend/notification-page
Open
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
74c13ef
db 연결
eunhye-ahn fb6753a
그룹 생성
eunhye-ahn 591b045
내 그룹 목록 조회 api
eunhye-ahn 44be651
입장코드로 그룹 참여 api
eunhye-ahn 1d9dfc6
그룹 상세 조회 api
eunhye-ahn 4841b43
그룹 내 투표 목록 조회 api
eunhye-ahn f51663d
그룹투표생성 + 목록 조회 api
eunhye-ahn fc15eff
그룹 투표 상세조회 api
eunhye-ahn 264d1c4
Merge conflict resolved
eunhye-ahn b59c69c
Resolve merge conflicts in controller and service
eunhye-ahn ea0b292
투표참여 api
eunhye-ahn 25835ef
댓글 생성+조회+삭제 api
eunhye-ahn a01b8b5
알림 전체 목록 페이지 추가
parksinhae 9999d20
불필요한 캐시 파일 Git 추적 제거 및 .gitignore 추가
parksinhae File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
83 changes: 76 additions & 7 deletions
polling-app-client/package-lock.json
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
polling-app-client/src/notification/NotificationPage.jsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| import React, { useEffect, useState } from 'react'; | ||
| import { List, Card, Spin, message } from 'antd'; | ||
| import axios from 'axios'; | ||
|
|
||
| const NotificationPage = () => { | ||
| const [notifications, setNotifications] = useState([]); | ||
| const [loading, setLoading] = useState(true); | ||
|
|
||
| useEffect(() => { | ||
| // �鿣�� �˸� API ȣ�� | ||
| axios.get('/api/notifications') | ||
| // ���� API ��η� ���� �ʿ� | ||
| .then(response => { | ||
| setNotifications(response.data); | ||
| setLoading(false); | ||
| }) | ||
| .catch(error => { | ||
| message.error('�˸��� �ҷ����� �� �����߽��Θ�.'); | ||
| setLoading(false); | ||
| }); | ||
| }, []); | ||
|
|
||
| if (loading) return <Spin tip="�ε� ��..." />; | ||
|
|
||
| return ( | ||
| <div style={{ padding: 20 }}> | ||
| <h2>�˸� ���</h2> | ||
| <List | ||
| grid={{ gutter: 16, column: 1 }} | ||
| dataSource={notifications} | ||
| renderItem={item => ( | ||
| <List.Item> | ||
| <Card title={item.title}> | ||
| {item.message} | ||
| </Card> | ||
| </List.Item> | ||
| )} | ||
| /> | ||
| </div> | ||
| ); | ||
| }; | ||
|
|
||
| export default NotificationPage; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.