Skip to content

Commit

Permalink
feat: 전체 참여자 관리 : 참여자 이름 정렬 (#830)
Browse files Browse the repository at this point in the history
* feat: 전체 참여자 관리 이름을 ㄱ-ㅎ,a-z 순으로 정렬하기

* chore: 정렬하는 위치를 useEventMember에서 useRequestGetReports로 변경
  • Loading branch information
soi-ha authored Nov 20, 2024
1 parent d693a5b commit 5c79b7a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion client/src/hooks/queries/report/useRequestGetReports.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ const useRequestGetReports = ({...props}: WithErrorHandlingStrategy | null = {})
queryFn: () => requestGetReports({eventId, ...props}),
});

const sortedMemberNameReports = data?.reports.sort((a, b) => a.memberName.localeCompare(b.memberName));

return {
reports: data?.reports ?? [],
reports: sortedMemberNameReports ?? [],
...rest,
};
};
Expand Down

0 comments on commit 5c79b7a

Please sign in to comment.