Skip to content

Commit

Permalink
Merge pull request #102 from Kusitms-29th-ASAP/fix/#96
Browse files Browse the repository at this point in the history
fix(#96): 오늘의 알림장 수정
  • Loading branch information
uiop5809 authored May 23, 2024
2 parents 40f71a6 + f855387 commit df95ab5
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/components/school/notification/TodayNotification.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,9 @@ const TodayNotification = () => {
useEffect(() => {
Axios.get(`/api/v1/classrooms/announcements`)
.then((response) => {
const { teacherName, writeDate, announcements } = response.data;
setTeacher(teacherName);
setToday(writeDate);
setLastNotiData(announcements);
console.log(response.data);
const data = response.data;
setTeacher(data.teacherName);
setLastNotiData(data.announcements);
})
.catch(() => {});
}, []);
Expand All @@ -43,7 +41,7 @@ const TodayNotification = () => {
<TodayTitle>오늘의 알림장</TodayTitle>
{notiData[0] !== null ? (
<Notification
day={notiData[0].writeDate}
day={"2024-05-25"}
teacher={teacher}
notifications={notiData[0]}
isToday={true}
Expand Down

0 comments on commit df95ab5

Please sign in to comment.