From 6302fe72634c62c03413fefa70e9d358bd8de67d Mon Sep 17 00:00:00 2001 From: Stefan Roellin Date: Thu, 2 Nov 2023 19:26:00 +0100 Subject: [PATCH] Fix chart periods of sitemaps "3M" for three months is an invalid chart period for a sitemap. Replace it with "4M" for four months, which is missing. Signed-off-by: Stefan Roellin --- .../web/src/components/pagedesigner/sitemap/widget-details.vue | 2 +- .../web/src/pages/settings/pages/sitemap/sitemap-edit.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bundles/org.openhab.ui/web/src/components/pagedesigner/sitemap/widget-details.vue b/bundles/org.openhab.ui/web/src/components/pagedesigner/sitemap/widget-details.vue index 134e831c23..9bae258b01 100644 --- a/bundles/org.openhab.ui/web/src/components/pagedesigner/sitemap/widget-details.vue +++ b/bundles/org.openhab.ui/web/src/components/pagedesigner/sitemap/widget-details.vue @@ -109,7 +109,7 @@ export default { { key: '2W', value: '2 Weeks' }, { key: 'M', value: 'Month' }, { key: '2M', value: '2 Months' }, - { key: '3M', value: '3 Months' }, + { key: '4M', value: '4 Months' }, { key: 'Y', value: 'Year' } ], inputHintDefs: [ diff --git a/bundles/org.openhab.ui/web/src/pages/settings/pages/sitemap/sitemap-edit.vue b/bundles/org.openhab.ui/web/src/pages/settings/pages/sitemap/sitemap-edit.vue index 4b06ac0085..bd691eda49 100644 --- a/bundles/org.openhab.ui/web/src/pages/settings/pages/sitemap/sitemap-edit.vue +++ b/bundles/org.openhab.ui/web/src/pages/settings/pages/sitemap/sitemap-edit.vue @@ -427,7 +427,7 @@ export default { } }) widgetList.filter(widget => widget.component === 'Chart').forEach(widget => { - if (!(widget.config && widget.config.period && ['h', '4h', '8h', '12h', 'D', '2D', '3D', 'W', '2W', 'M', '2M', '3M', 'Y'].includes(widget.config.period))) { + if (!(widget.config && widget.config.period && ['h', '4h', '8h', '12h', 'D', '2D', '3D', 'W', '2W', 'M', '2M', '4M', 'Y'].includes(widget.config.period))) { let label = widget.config && widget.config.label ? widget.config.label : 'without label' validationWarnings.push(widget.component + ' widget ' + label + ', invalid period configured: ' + widget.config.period) }