data: {
name: d.name,
source: d.source,
- // Don't downgrade an onboarded employee back to a candidate via an edit.
- type,
- status: existing.status === "EMPLOYEE" ? existing.status : status,
+ // type/status are left untouched — ex-hand / employee designation is owned
+ // by the office (admin crew record + sign-off), never by a candidate edit.
appliedRankId: d.appliedRankId || null,
currentRankId: d.currentRankId || null,
experienceMonths: d.experienceMonths,
diff --git a/App/app/(portal)/crewing/candidates/candidate-form.tsx b/App/app/(portal)/crewing/candidates/candidate-form.tsx
index ed71b1e..f5bac50 100644
--- a/App/app/(portal)/crewing/candidates/candidate-form.tsx
+++ b/App/app/(portal)/crewing/candidates/candidate-form.tsx
@@ -5,7 +5,7 @@ import { useRouter } from "next/navigation";
import type { CandidateSource } from "@prisma/client";
import { AdminDialog } from "@/components/ui/admin-dialog";
import { addCandidate, updateCandidate } from "./actions";
-import { SOURCE_OPTIONS, SOURCE_LABEL } from "./candidate-ui";
+import { FORM_SOURCE_OPTIONS, SOURCE_LABEL } from "./candidate-ui";
const INPUT =
"w-full rounded-lg border border-neutral-300 px-3 py-2 text-sm focus:border-primary-500 focus:outline-none focus:ring-2 focus:ring-primary-500/20";
@@ -46,7 +46,7 @@ function CandidateFields({
@@ -64,7 +64,7 @@ function CandidateFields({
-
+