fix: staff edit error and column order on appointment page

This commit is contained in:
ff
2026-04-12 12:13:57 -04:00
parent 1eac0c313c
commit 805fb3964a
3 changed files with 4 additions and 5 deletions

View File

@@ -3,7 +3,7 @@ import React, { useState, useEffect } from "react";
interface StaffFormProps {
initialData?: Partial<Staff>;
onSubmit: (data: Omit<Staff, "id">) => void;
onSubmit: (data: Omit<Staff, "id" | "userId" | "createdAt">) => void;
onCancel: () => void;
isLoading?: boolean;
}
@@ -18,7 +18,6 @@ export function StaffForm({
const [email, setEmail] = useState("");
const [role, setRole] = useState("Staff");
const [phone, setPhone] = useState("");
const [userId, setUserId] = useState<number | undefined>(undefined);
const [hasTypedRole, setHasTypedRole] = useState(false);
@@ -44,7 +43,6 @@ export function StaffForm({
email: email.trim() || undefined,
role: role.trim(),
phone: phone.trim() || undefined,
userId: userId || 0,
});
};