mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-22 00:31:13 -05:00
Fix RideModelForm manufacturer_id bug
This commit is contained in:
@@ -45,7 +45,7 @@ type RideModelFormData = z.infer<typeof rideModelSchema>;
|
|||||||
interface RideModelFormProps {
|
interface RideModelFormProps {
|
||||||
manufacturerName: string;
|
manufacturerName: string;
|
||||||
manufacturerId?: string;
|
manufacturerId?: string;
|
||||||
onSubmit: (data: RideModelFormData & { _technical_specifications?: TechnicalSpecification[] }) => void;
|
onSubmit: (data: RideModelFormData & { manufacturer_id?: string; _technical_specifications?: TechnicalSpecification[] }) => void;
|
||||||
onCancel: () => void;
|
onCancel: () => void;
|
||||||
initialData?: Partial<RideModelFormData & {
|
initialData?: Partial<RideModelFormData & {
|
||||||
id?: string;
|
id?: string;
|
||||||
@@ -106,6 +106,7 @@ export function RideModelForm({
|
|||||||
// Include relational technical specs with extended type
|
// Include relational technical specs with extended type
|
||||||
onSubmit({
|
onSubmit({
|
||||||
...data,
|
...data,
|
||||||
|
manufacturer_id: manufacturerId,
|
||||||
_technical_specifications: technicalSpecs
|
_technical_specifications: technicalSpecs
|
||||||
});
|
});
|
||||||
} catch (error: unknown) {
|
} catch (error: unknown) {
|
||||||
|
|||||||
Reference in New Issue
Block a user