From 428994ce73dc5581891ca34dcd2c99c81d8395e8 Mon Sep 17 00:00:00 2001 From: CamilleLegeron Date: Tue, 30 Apr 2024 13:33:17 +0200 Subject: [PATCH] fix: getWidgetType before translate label --- app/client/models/entities/ViewSectionRec.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/client/models/entities/ViewSectionRec.ts b/app/client/models/entities/ViewSectionRec.ts index 2eeca6a7..3f100ddb 100644 --- a/app/client/models/entities/ViewSectionRec.ts +++ b/app/client/models/entities/ViewSectionRec.ts @@ -20,7 +20,7 @@ import {BEHAVIOR} from 'app/client/models/entities/ColumnRec'; import * as modelUtil from 'app/client/models/modelUtil'; import {removeRule, RuleOwner} from 'app/client/models/RuleOwner'; import {LinkConfig} from 'app/client/ui/selectBy'; -import {getWidgetTypesLabelTranslation} from "app/client/ui/widgetTypesMap"; +import {getWidgetTypes, getWidgetTypesLabelTranslation} from "app/client/ui/widgetTypesMap"; import {FilterColValues} from "app/common/ActiveDocAPI"; import {AccessLevel, ICustomWidget} from 'app/common/CustomWidget'; import {UserAction} from 'app/common/DocActions'; @@ -461,7 +461,7 @@ export function createViewSectionRec(this: ViewSectionRec, docModel: DocModel): // All concatenated separated by space. this.defaultWidgetTitle = this.autoDispose(ko.pureComputed(() => { const widgetTypeDesc = this.parentKey() !== 'record' - ? `${getWidgetTypesLabelTranslation(this.parentKey.peek() as any)}` + ? `${getWidgetTypesLabelTranslation(getWidgetTypes(this.parentKey.peek() as any))}` : ''; const table = this.table(); return [