Fixed statistics config updated text

This commit is contained in:
Juan Gilsanz Polo 2024-02-29 14:49:30 +01:00
parent 0821fd4e0e
commit 9de9b0afec
3 changed files with 8 additions and 4 deletions

View file

@ -754,6 +754,8 @@
"statisticsSettingsDescription": "Configure data collection for statistics", "statisticsSettingsDescription": "Configure data collection for statistics",
"loadingStatisticsSettings": "Loading statistics settings...", "loadingStatisticsSettings": "Loading statistics settings...",
"statisticsSettingsLoadError": "An error occured when loading statistics settings.", "statisticsSettingsLoadError": "An error occured when loading statistics settings.",
"statisticsConfigUpdated": "Statistics settings updated successfully",
"statisticsConfigNotUpdated": "Statistics settings couldn't be updated",
"customTimeInHours": "Custom time (in hours)", "customTimeInHours": "Custom time (in hours)",
"invalidTime": "Invalid time", "invalidTime": "Invalid time",
"removeDomain": "Remove domain", "removeDomain": "Remove domain",

View file

@ -754,6 +754,8 @@
"statisticsSettingsDescription": "Configura la recolección de datos para estadísticas", "statisticsSettingsDescription": "Configura la recolección de datos para estadísticas",
"loadingStatisticsSettings": "Cargando ajustes de estadísticas...", "loadingStatisticsSettings": "Cargando ajustes de estadísticas...",
"statisticsSettingsLoadError": "Ocurrió un error al cargar los ajustes de estadísticas.", "statisticsSettingsLoadError": "Ocurrió un error al cargar los ajustes de estadísticas.",
"statisticsConfigNotUpdated": "La configuración de estadísticas no pudo ser actualizada.",
"statisticsConfigUpdated": "Configuración de estadísticas actualizada correctamente.",
"customTimeInHours": "Tiempo personalizado (en horas)", "customTimeInHours": "Tiempo personalizado (en horas)",
"invalidTime": "Tiempo no válido", "invalidTime": "Tiempo no válido",
"removeDomain": "Eliminar dominio", "removeDomain": "Eliminar dominio",

View file

@ -145,19 +145,19 @@ class _StatisticsSettingsState extends State<StatisticsSettings> {
processModal.close(); processModal.close();
if (!mounted) return; if (!context.mounted) return;
if (result.successful == true) { if (result.successful == true) {
showSnacbkar( showSnacbkar(
appConfigProvider: appConfigProvider, appConfigProvider: appConfigProvider,
label: AppLocalizations.of(context)!.logsConfigUpdated, label: AppLocalizations.of(context)!.statisticsConfigUpdated,
color: Colors.green color: Colors.green
); );
} }
else { else {
showSnacbkar( showSnacbkar(
appConfigProvider: appConfigProvider, appConfigProvider: appConfigProvider,
label: AppLocalizations.of(context)!.logsConfigNotUpdated, label: AppLocalizations.of(context)!.statisticsConfigNotUpdated,
color: Colors.red color: Colors.red
); );
} }
@ -209,7 +209,7 @@ class _StatisticsSettingsState extends State<StatisticsSettings> {
if (value != null && value != "custom") { if (value != null && value != "custom") {
_customTimeError = null; _customTimeError = null;
_customTimeController.text = ""; _customTimeController.text = "";
}; }
_retentionTime = value; _retentionTime = value;
}), }),
decoration: InputDecoration( decoration: InputDecoration(