Skip to content

Commit

Permalink
tested
Browse files Browse the repository at this point in the history
  • Loading branch information
SKairinos committed Sep 24, 2024
1 parent 90a5ff1 commit 39a0abb
Show file tree
Hide file tree
Showing 4 changed files with 192 additions and 197 deletions.
2 changes: 1 addition & 1 deletion src/components/form/ClassAutocompleteField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const ClassAutocompleteField: FC<ClassAutocompleteFieldProps> = ({
}) => (
<ApiAutocompleteField
useLazyListQuery={useLazyListClassesQuery}
searchKey="name"
searchKey="id_or_name"
filterOptions={{ _id }}
getOptionLabel={({ name, id, teacher }) =>
`${name} (${id}), ${teacher.user.first_name} ${teacher.user.last_name}`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const NewClassSections: FC<
</>
))

const _TransferStudentsClass: FC<
const _TransferStudents: FC<
TransferStudentsState & {
classId: Class["id"]
classPath: string
Expand All @@ -55,13 +55,7 @@ const _TransferStudentsClass: FC<
<Typography align="center" variant="h4">
Move students from class {klass.name} ({klass.id})
</Typography>
<Link
className="back-to"
to={classPath}
// marginBottom={
// newClassName === undefined ? undefined : "0px !important"
// }
>
<Link className="back-to" to={classPath}>
Class
</Link>
</pages.Section>
Expand Down Expand Up @@ -107,7 +101,7 @@ const TransferStudents: FC<TransferStudentsProps> = () => {
return !state || !state.studentUsers || !state.studentUsers.length ? (
<Navigate to={classPath} replace />
) : (
<_TransferStudentsClass
<_TransferStudents
classId={classId}
classPath={classPath}
studentUsers={state.studentUsers}
Expand Down
1 change: 1 addition & 0 deletions vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export default defineConfig({
},
server: {
open: true,
host: true,
},
test: {
globals: true,
Expand Down
Loading

0 comments on commit 39a0abb

Please sign in to comment.