diff --git a/packages/api/src/controllers/admin/manage/Units.ts b/packages/api/src/controllers/admin/manage/Units.ts index 52519764e..3d59969d1 100644 --- a/packages/api/src/controllers/admin/manage/Units.ts +++ b/packages/api/src/controllers/admin/manage/Units.ts @@ -145,7 +145,9 @@ export class ManageUnitsController { departmentId: data.department, divisionId: data.division, rankId: data.rank || null, - suspended: data.suspended, + suspended: data.suspended ?? false, + callsign2: data.callsign2, + callsign: data.callsign, }, }); diff --git a/packages/client/src/pages/admin/manage/units/[id].tsx b/packages/client/src/pages/admin/manage/units/[id].tsx index 519bcc279..2d880beab 100644 --- a/packages/client/src/pages/admin/manage/units/[id].tsx +++ b/packages/client/src/pages/admin/manage/units/[id].tsx @@ -19,6 +19,8 @@ import type { OfficerLog } from "@snailycad/types"; import { Toggle } from "components/form/Toggle"; import { Title } from "components/shared/Title"; import { OfficerLogsTable } from "components/leo/logs/OfficerLogsTable"; +import { FormRow } from "components/form/FormRow"; +import { Input } from "components/form/inputs/Input"; type Unit = (FullOfficer & { logs: OfficerLog[] }) | FullDeputy; @@ -63,8 +65,10 @@ export default function SupervisorPanelPage({ unit }: Props) { division: "divisionId" in unit ? unit.divisionId : "", divisions: divisions.map((v) => ({ value: v.id, label: v.value.value })) ?? [], callsign: unit.callsign, + callsign2: unit.callsign2, rank: unit.rankId, suspended: unit.suspended, + badgeNumber: unit.badgeNumber ?? "", }; return ( @@ -76,7 +80,7 @@ export default function SupervisorPanelPage({ unit }: Props) {