EntityFormOptions

提供对表窗体的所有信息的访问权限。

适用于

模型驱动应用

属性

createFromEntity

指定基于映射列值提供默认值的记录。 查找对象具有以下属性: idname和 entityType。

类型: LookupValue

entityId

要为其显示窗体的表记录的唯一 ID。

类型:string

entityName

要为其显示窗体的表的逻辑名称。

类型:string

formId

要显示的窗体实例的 ID。

类型:string

身高

要显示的窗体窗口的高度(以像素为单位)。

类型:number

openInNewWindow(打开新窗口)

是否在新窗口中显示窗体。

类型:boolean

使用QuickCreateForm

是否打开快速创建窗体。 默认值为 false。

类型:boolean

width

要显示的表单窗口的宽度(以像素为单位)。

类型:boolean

窗口位置

指定屏幕上的窗口位置。

类型:number

该值 windowPosition 是具有以下可能值的数字:

价值 Position
1 居中
2 边

Example

private onRowClick(event: Event): void {
    let rowRecordId = (event.currentTarget as HTMLTableRowElement).getAttribute(
      RowRecordId
    );
    if (rowRecordId) {
      let entityreference = this.contextObj.parameters.simpleTableGrid.records[
        rowRecordId
      ].getNamedReference();
      let entityFormOptions = {
        entityName: entityreference.entityType!,
        entityId: entityreference.id
      };
      this.contextObj.navigation.openForm(entityFormOptions);
    }
  }

Power Apps 组件框架 API 参考
Power Apps 组件框架概述