fix bug no entity label for dachboard state

This commit is contained in:
ArtemDzhereleiko 2021-08-18 14:47:35 +03:00
parent 327607e86d
commit f0db16acca

View File

@ -149,7 +149,8 @@ export class EntitiesHierarchyWidgetComponent extends PageComponent implements O
entityType: EntityType.DEVICE,
id: '123'
},
name: 'TEST DEV1'
name: 'TEST DEV1',
label: ''
},
data: {},
level: 2
@ -289,7 +290,7 @@ export class EntitiesHierarchyWidgetComponent extends PageComponent implements O
const descriptors = this.ctx.actionsApi.getActionDescriptors('nodeSelected');
if (descriptors.length) {
const entity = selectedNode.data.nodeCtx.entity;
this.ctx.actionsApi.handleWidgetAction(event, descriptors[0], entity.id, entity.name, { nodeCtx: selectedNode.data.nodeCtx });
this.ctx.actionsApi.handleWidgetAction(event, descriptors[0], entity.id, entity.name,{ nodeCtx: selectedNode.data.nodeCtx }, entity.label);
}
}
}