</ng-container>
<ng-container *ngSwitchCase="'readonly-list'">
- <ng-container *ngIf="field.linkedValues">
+ <ng-container *ngIf="field.linkedValues && field.linkedValues[0]?.label">
<span>{{field.linkedValues[0].label}}</span>
</ng-container>
</ng-container>
|| this.idl.getClassSelector(class_) || idField;
return list.map(item => {
- return {id: item[idField](), label: item[selector]()};
+ if (item !== undefined)
+ return {id: item[idField](), label: item[selector]()};
});
}
this.pcrud[this.mode]([recToSave]).toPromise().then(
result => {
this.recordSaved.emit(result);
- this.fmEditForm.form.markAsPristine();
+ if (this.fmEditForm) {
+ this.fmEditForm.form.markAsPristine();
+ }
this.successStr.current().then(msg => this.toast.success(msg));
if (this.isDialog()) { this.record = undefined; this.close(result); }
},