Update color, add refetch after edit students

This commit is contained in:
adam-skowronek 2023-01-09 20:11:08 +01:00
parent 59c3026602
commit d286e93755
2 changed files with 4 additions and 3 deletions

View File

@ -13,7 +13,7 @@ const Coordinator = () => {
{ name: 'Harmonogram', path: '/coordinator/schedule' },
{ name: 'Dostępność', path: '/coordinator/supervisors_availability' },
]}
color="bg-violet-400"
color="bg-[#9ae9cc]"
/>
<div className="m-10">
<Outlet />

View File

@ -25,7 +25,7 @@ const Group = () => {
const [yearGroupId] = useLocalStorageState('yearGroupId')
const [studentOptions, setStudentOptions] = useState<SelectValue[]>([])
const { isLoading: areStudentsLoading } = useQuery(
const { isLoading: areStudentsLoading, refetch: refetchStudents } = useQuery(
'students',
() => getStudents({ year_group_id: Number(yearGroupId), per_page: 1000 }),
{
@ -51,6 +51,7 @@ const Group = () => {
{
onSuccess: () => {
refetch()
refetchStudents()
},
},
)