From 877a5184158fb4aa371fa2ea2107032543c9aa37 Mon Sep 17 00:00:00 2001 From: sct Date: Tue, 3 Nov 2020 07:54:42 +0000 Subject: [PATCH] feat(frontend): radarr delete modal --- src/components/Settings/RadarrModal.tsx | 61 +++++++++++++++----- src/components/Settings/SettingsServices.tsx | 39 ++++++++++++- 2 files changed, 85 insertions(+), 15 deletions(-) diff --git a/src/components/Settings/RadarrModal.tsx b/src/components/Settings/RadarrModal.tsx index 425e3ce8e..b52db3df6 100644 --- a/src/components/Settings/RadarrModal.tsx +++ b/src/components/Settings/RadarrModal.tsx @@ -129,6 +129,7 @@ const RadarrModal: React.FC = ({ baseUrl: radarr?.baseUrl, activeProfileId: radarr?.activeProfileId, rootFolder: radarr?.activeDirectory, + minimumAvailability: radarr?.minimumAvailability, isDefault: radarr?.isDefault ?? false, is4k: radarr?.is4k ?? false, }} @@ -150,7 +151,7 @@ const RadarrModal: React.FC = ({ activeProfileName: profileName, activeDirectory: values.rootFolder, is4k: values.is4k, - minimumAvailability: 'In Cinema', + minimumAvailability: values.minimumAvailability, isDefault: values.isDefault, }; if (!radarr) { @@ -206,13 +207,13 @@ const RadarrModal: React.FC = ({ okDisabled={!isValidated || isSubmitting || isTesting} onOk={() => handleSubmit()} title={ - !radarr ? 'Create New Radarr Instance' : 'Edit Radarr Instance' + !radarr ? 'Create New Radarr Server' : 'Edit Radarr Server' } >
- {errors.baseUrl && touched.baseUrl && ( -
{errors.baseUrl}
+ {errors.activeProfileId && touched.activeProfileId && ( +
+ {errors.activeProfileId} +
)}
- {errors.baseUrl && touched.baseUrl && ( -
{errors.baseUrl}
+ {errors.rootFolder && touched.rootFolder && ( +
+ {errors.rootFolder} +
+ )} + + +
+ +
+
+ + + + + + +
+ {errors.rootFolder && touched.rootFolder && ( +
+ {errors.rootFolder} +
)}