Skip to content

Commit

Permalink
fix(EntityTable): add feature need to build the edition form
Browse files Browse the repository at this point in the history
  • Loading branch information
alecarn committed Oct 12, 2023
1 parent 064a0d2 commit 1ff1c04
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/app/pages/portal/portal.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@ import {
EntityRecord,
EntityService,
EntityStore,
EntityTableComponent,
EntityTablePaginatorOptions,
Tool, // getEntityTitle,
Tool,
Toolbox,
Widget,
Workspace,
Expand Down Expand Up @@ -182,6 +183,9 @@ export class PortalComponent implements OnInit, OnDestroy {
@ViewChild('searchBar', { read: ElementRef, static: true })
searchBar: ElementRef;

@ViewChild(EntityTableComponent, { static: false })
entityTable: EntityTableComponent;

get map(): IgoMap {
return this.mapState.map;
}
Expand Down Expand Up @@ -569,6 +573,11 @@ export class PortalComponent implements OnInit, OnDestroy {
}

addFeature(workspace: EditionWorkspace) {
if (!this.entityTable) {
return;
}
this.entityTable.enableEdition();

let feature = {
type: 'Feature',
properties: {}
Expand Down

0 comments on commit 1ff1c04

Please sign in to comment.