</eg-combobox-entry>
</eg-combobox>
</form>
-{{field}}
-<eg-grid #grid [dataSource]="gridSource"
+{{field | json}}
+<eg-grid #authoritiesGrid [dataSource]="gridSource"
persistKey="cat.authorities.manage">
<eg-grid-column path="record.id" label="ID" i18n-label [index]="true" [hidden]="true"></eg-grid-column>
<eg-grid-column path="sort_value" label="Sort value" i18n-label></eg-grid-column>
+import { GridComponent } from '@eg/share/grid/grid.component';
import {FormGroup, FormControl} from '@angular/forms';
import {PcrudService} from '@eg/core/pcrud.service';
-import {Component} from '@angular/core';
+import {Component, ViewChild} from '@angular/core';
import {GridDataSource} from '@eg/share/grid/grid';
import {Pager} from '@eg/share/util/pager';
import { IdlObject } from '@eg/core/idl.service';
+import { of } from 'rxjs';
@Component({
templateUrl: './manage.component.html',
gridSource: GridDataSource;
search: FormGroup;
authorityFields: IdlObject[] = [];
+ @ViewChild('authoritiesGrid') authoritiesGrid: GridComponent;
constructor(
private pcrud: PcrudService
field: new FormControl()
});
+ this.field.valueChanges.subscribe(
+ () => this.authoritiesGrid.reload()
+ );
+
this.pcrud.search('acsaf', {'main_entry': null})
.subscribe((field) => this.authorityFields.push(field));
ash: ['record']
}
});
+ } else {
+ return of();
}
};
}