mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-25 08:11:12 -05:00
Migrate date precision handling tests
Update park and ride submission forms to support and persist all new date precision options (exact, month, year, decade, century, approximate), ensure default and validation align with backend, and verify submissions save without errors. Includes front-end tests scaffolding and adjustments to submission helpers to store updated precision fields.
This commit is contained in:
@@ -67,7 +67,7 @@ export function RichCompanyDisplay({ data, actionType, showAllFields = true }: R
|
||||
{data.founded_date ? (
|
||||
<FlexibleDateDisplay
|
||||
date={data.founded_date}
|
||||
precision={(data.founded_date_precision as DatePrecision) || 'day'}
|
||||
precision={(data.founded_date_precision as DatePrecision) || 'exact'}
|
||||
className="font-medium"
|
||||
/>
|
||||
) : (
|
||||
|
||||
@@ -165,7 +165,7 @@ export function RichParkDisplay({ data, actionType, showAllFields = true }: Rich
|
||||
<span className="text-muted-foreground">Opened:</span>{' '}
|
||||
<FlexibleDateDisplay
|
||||
date={data.opening_date}
|
||||
precision={(data.opening_date_precision as DatePrecision) || 'day'}
|
||||
precision={(data.opening_date_precision as DatePrecision) || 'exact'}
|
||||
className="font-medium"
|
||||
/>
|
||||
</div>
|
||||
@@ -175,7 +175,7 @@ export function RichParkDisplay({ data, actionType, showAllFields = true }: Rich
|
||||
<span className="text-muted-foreground">Closed:</span>{' '}
|
||||
<FlexibleDateDisplay
|
||||
date={data.closing_date}
|
||||
precision={(data.closing_date_precision as DatePrecision) || 'day'}
|
||||
precision={(data.closing_date_precision as DatePrecision) || 'exact'}
|
||||
className="font-medium"
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -606,7 +606,7 @@ export function RichRideDisplay({ data, actionType, showAllFields = true }: Rich
|
||||
<span className="text-muted-foreground">Opened:</span>{' '}
|
||||
<FlexibleDateDisplay
|
||||
date={data.opening_date}
|
||||
precision={(data.opening_date_precision as DatePrecision) || 'day'}
|
||||
precision={(data.opening_date_precision as DatePrecision) || 'exact'}
|
||||
className="font-medium"
|
||||
/>
|
||||
</div>
|
||||
@@ -616,7 +616,7 @@ export function RichRideDisplay({ data, actionType, showAllFields = true }: Rich
|
||||
<span className="text-muted-foreground">Closed:</span>{' '}
|
||||
<FlexibleDateDisplay
|
||||
date={data.closing_date}
|
||||
precision={(data.closing_date_precision as DatePrecision) || 'day'}
|
||||
precision={(data.closing_date_precision as DatePrecision) || 'exact'}
|
||||
className="font-medium"
|
||||
/>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user