From 865f3481679232788afd366ff03af2d9d8a4ec63 Mon Sep 17 00:00:00 2001 From: Marliana Lara Date: Mon, 16 Nov 2020 13:01:44 -0500 Subject: [PATCH] Add descriptive helper text when log aggregator toggle is disabled --- .../Logging/LoggingEdit/LoggingEdit.jsx | 21 ++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/awx/ui_next/src/screens/Setting/Logging/LoggingEdit/LoggingEdit.jsx b/awx/ui_next/src/screens/Setting/Logging/LoggingEdit/LoggingEdit.jsx index c59ca0845e..074e6ab318 100644 --- a/awx/ui_next/src/screens/Setting/Logging/LoggingEdit/LoggingEdit.jsx +++ b/awx/ui_next/src/screens/Setting/Logging/LoggingEdit/LoggingEdit.jsx @@ -138,7 +138,26 @@ function LoggingEdit({ i18n }) { + {logging.LOG_AGGREGATOR_ENABLED.help_text} + {!formik.values.LOG_AGGREGATOR_ENABLED && + (!formik.values.LOG_AGGREGATOR_HOST || + !formik.values.LOG_AGGREGATOR_TYPE) && ( + <> +
+
+ {i18n._( + t`Cannot enable log aggregator without providing + logging aggregator host and logging aggregator type.` + )} + + )} + + ), + }} ariaLabel={i18n._(t`Enable external logging`)} disabled={ !formik.values.LOG_AGGREGATOR_ENABLED &&