From 631272101d929958275ffa4605e7e4fadbbdda7a Mon Sep 17 00:00:00 2001 From: vchikalkin Date: Tue, 28 Mar 2023 18:42:24 +0300 Subject: [PATCH] stores: fix Loading status --- apps/web/stores/calculation/statuses/index.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/apps/web/stores/calculation/statuses/index.ts b/apps/web/stores/calculation/statuses/index.ts index b03400e..084897b 100644 --- a/apps/web/stores/calculation/statuses/index.ts +++ b/apps/web/stores/calculation/statuses/index.ts @@ -21,9 +21,13 @@ export default class StatusStore { }; public getStatus(elementName: ElementsActions | ElementsValues) { - if (this.root.$process.has('Unlimited')) return 'Default'; + const status = this.overrided[elementName] || this.statuses[elementName]; - return this.overrided[elementName] || this.statuses[elementName]; + if (this.root.$process.has('Unlimited') && status === 'Disabled') { + return 'Default'; + } + + return status; } public setStatus = (elementName: ElementsActions | ElementsValues, status: Status) => {