Skip to content

Commit

Permalink
Merge branch 'main' into others/토너먼트-브라켓-및-스와이퍼-로딩-컴포넌트-적용-#1203
Browse files Browse the repository at this point in the history
  • Loading branch information
Clearsu authored Jan 4, 2024
2 parents 745930d + 20e97ed commit 5fe846c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 24 deletions.
4 changes: 0 additions & 4 deletions components/admin/tournament/TournamentEdit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -98,10 +98,6 @@ export default function TournamentEdit({

const postHandler = async () => {
try {
console.log('startTime : ', tournamentEditInfo.startTime);
console.log('endTime : ', tournamentEditInfo.endTime);
console.log('startTime Date : ', new Date(tournamentEditInfo.startTime));
console.log('endTime Date : ', new Date(tournamentEditInfo.endTime));
await instanceInManage.post(`/tournaments`, {
title: tournamentEditInfo.title,
contents: tournamentEditInfo.contents,
Expand Down
28 changes: 15 additions & 13 deletions components/modal/admin/AdminFeedbackCheckModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,21 @@ export default function AdminFeedbackCheck({
await instanceInManage.patch(`/feedback/${id}`, {
isSolved: isSolved,
});
await instanceInManage.post(`/notifications`, {
intraId,
message: isSolved
? '피드백을 검토중입니다.'
: '피드백이 반영되었습니다.',
// sendMail: isSend, todo: 슬랙으로 보내는 것으로 변경
});
setSnackBar({
toastName: 'noti user',
severity: 'success',
message: `알림이 성공적으로 전송되었습니다!`,
clicked: true,
});
if (isSend) {
await instanceInManage.post(`/notifications`, {
intraId,
message: isSolved
? '피드백을 검토중입니다.'
: '피드백이 반영되었습니다.',
// sendMail: isSend, todo: 슬랙으로 보내는 것으로 변경
});
setSnackBar({
toastName: 'noti user',
severity: 'success',
message: `알림이 성공적으로 전송되었습니다!`,
clicked: true,
});
}
setModal({ modalName: null });
} catch (e) {
console.error('SW03');
Expand Down
2 changes: 1 addition & 1 deletion components/rank/RankList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export default function RankList({ season }: RankListProps) {
const makePath = (): string => {
const modeQuery = Mode === 'RANK' ? 'ranks/single' : 'exp';
const seasonQuery = Mode === 'RANK' ? `&season=${season}` : '';
return `pingpong/${modeQuery}?page=${page}&size=20${seasonQuery}`;
return `pingpong/v2/${modeQuery}?page=${page}&size=20${seasonQuery}`;
};

useRankList({
Expand Down
7 changes: 1 addition & 6 deletions hooks/tournament/useTournamentEditInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,7 @@ function useTournamentEditInfo() {
// change
const inputChangeHandler = (event: React.ChangeEvent<HTMLInputElement>) => {
const { name, value } = event.target;
if (name === 'startTime' || name === 'endTime') {
setTournamentEditInfo((prev) => ({
...prev,
[name]: value.slice(0, -2) + '00',
}));
} else setTournamentEditInfo((prev) => ({ ...prev, [name]: value }));
setTournamentEditInfo((prev) => ({ ...prev, [name]: value }));
};

const selectChangeHandler = (event: React.ChangeEvent<HTMLSelectElement>) => {
Expand Down

0 comments on commit 5fe846c

Please sign in to comment.