From caa25ccf93a764f6bdcc1a833098a38f152c5c0f Mon Sep 17 00:00:00 2001 From: Donkie Date: Sun, 14 May 2023 20:06:44 +0200 Subject: [PATCH] Client: Better datetime field support --- client/src/pages/filaments/edit.tsx | 2 +- client/src/pages/filaments/list.tsx | 4 +++- client/src/pages/filaments/show.tsx | 2 +- client/src/pages/spools/create.tsx | 4 ++-- client/src/pages/spools/edit.tsx | 6 +++--- client/src/pages/spools/list.tsx | 8 ++++++-- client/src/pages/spools/show.tsx | 6 +++--- client/src/pages/vendors/edit.tsx | 2 +- client/src/pages/vendors/list.tsx | 4 +++- client/src/pages/vendors/show.tsx | 2 +- 10 files changed, 24 insertions(+), 16 deletions(-) diff --git a/client/src/pages/filaments/edit.tsx b/client/src/pages/filaments/edit.tsx index a6e0bfe..d328457 100644 --- a/client/src/pages/filaments/edit.tsx +++ b/client/src/pages/filaments/edit.tsx @@ -44,7 +44,7 @@ export const FilamentEdit: React.FC = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { } + render={(value) => ( + + )} /> = () => { Id Registered - + Name Vendor diff --git a/client/src/pages/spools/create.tsx b/client/src/pages/spools/create.tsx index 7fd7e2b..5d3208b 100644 --- a/client/src/pages/spools/create.tsx +++ b/client/src/pages/spools/create.tsx @@ -28,7 +28,7 @@ export const SpoolCreate: React.FC = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { } + render={(value) => ( + + )} /> } + render={(value) => ( + + )} /> diff --git a/client/src/pages/spools/show.tsx b/client/src/pages/spools/show.tsx index c6bbd63..d589982 100644 --- a/client/src/pages/spools/show.tsx +++ b/client/src/pages/spools/show.tsx @@ -16,11 +16,11 @@ export const SpoolShow: React.FC = () => { Id Registered - + First Used - + Last Used - + Filament {/* {filamentIsLoading ? ( <>Loading... diff --git a/client/src/pages/vendors/edit.tsx b/client/src/pages/vendors/edit.tsx index 3378fc8..3229e6d 100644 --- a/client/src/pages/vendors/edit.tsx +++ b/client/src/pages/vendors/edit.tsx @@ -34,7 +34,7 @@ export const VendorEdit: React.FC = () => { value: value ? dayjs(value) : undefined, })} > - + = () => { } + render={(value) => ( + + )} /> = () => { Id Registered - + Name Comment