100% open-source IoT Platform - Integrate your devices, add intelligence, build custom apps
Java asset-managementbuildingdashboarddataplatformdevice-managementedge-computingenergyenergy-managementenergy-monitorfleet-managementfleet-telematicsiotiot-applicationiot-platformmodbusmqttmqtt-brokerota-updaterules-enginesmartcity
Minor UI updates to logging (#2262)
Martin Peeters34cc7994f5c5
diff --git a/ui/component/or-asset-tree/src/index.ts b/ui/component/or-asset-tree/src/index.tsindex d68a65527..b4b7efa67 100644--- a/ui/component/or-asset-tree/src/index.ts+++ b/ui/component/or-asset-tree/src/index.ts@@ -621,7 +621,7 @@ export class OrAssetTree extends subscribe(manager)(LitElement) {}if (!this._nodes) {- this._loadAssets().catch(console.warn);+ this._loadAssets().catch(ex => console.log(ex.message));return true;}@@ -731,7 +731,7 @@ export class OrAssetTree extends subscribe(manager)(LitElement) {} else {const cache: Asset[] = [];OrAssetTree._forEachNodeRecursive(this._nodes ?? [], n => n.asset && cache.push(n.asset));- await this._loadAssets(node.asset?.id, 0, cache).catch(e => console.warn(e));+ await this._loadAssets(node.asset?.id, 0, cache).catch(ex => console.log(ex.message));}} else {@@ -1827,7 +1827,7 @@ export class OrAssetTree extends subscribe(manager)(LitElement) {public onEventsConnect() {this._connected = true;- this._loadAssets().catch(console.warn);+ this._loadAssets().catch(ex => console.log(ex.message));}public onEventsDisconnect() {diff --git a/ui/component/or-chart/src/index.ts b/ui/component/or-chart/src/index.tsindex 274b3ad21..dff72f27b 100644--- a/ui/component/or-chart/src/index.ts+++ b/ui/component/or-chart/src/index.ts@@ -1312,10 +1312,11 @@ export class OrChart extends translate(i18next)(LitElement) {this._zoomChanged = false;} catch (ex) {- console.error(ex);if((ex as Error)?.message === "canceled") {+ console.debug("Cancelled chart data request. (probably because another request is taking place)");return; // If request has been canceled (using AbortController); return, and prevent _loading is set to false.}+ console.warn(ex);this._loading = false;this._zoomChanged = false;