From 43809487a7b541381393afdd452220302fa8145b Mon Sep 17 00:00:00 2001 From: Dobromir Popov Date: Fri, 21 Jun 2024 16:46:34 +0300 Subject: [PATCH] fix migration casing, UI improvements --- components/survey/SurveyForm.tsx | 7 +++++-- prisma/migrations/20240621124135_/migration.sql | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/components/survey/SurveyForm.tsx b/components/survey/SurveyForm.tsx index 389ebda..6d9e040 100644 --- a/components/survey/SurveyForm.tsx +++ b/components/survey/SurveyForm.tsx @@ -213,13 +213,16 @@ const SurveyForm: React.FC = ({ existingItem }) => { - handleDateChange('publicFrom', newDate)} value={dayjs(item?.publicFrom)} /> + handleDateChange('publicFrom', newDate)} + value={item && item.publicFrom ? dayjs(item.publicFrom) : null} />
- handleDateChange('publicUntil', newDate)} value={dayjs(item?.publicUntil)} /> + handleDateChange('publicUntil', newDate)} + value={item && item.publicUntil ? dayjs(item.publicUntil) : null} + />