Pass Values from master to Editor and then Editor Dialog #5429
Replies: 1 comment 2 replies
-
namespace younamespace {
@Serenity.Decorators.registerClass()
export class xxxEditor extends Common.GridEditorBase<xxxRow> {
//add property in editor
OrderID: number;
....
protected initDialog(dialog: EmployeePropertyDialog) {
super.initDialog(dialog);
dialog.OrderID = this.OrderID;
}
}
}
// also add property in editor dialog.
namespace yournamespace {
@Serenity.Decorators.registerClass()
export class xxxDialog extends Common.GridEditorDialog<xxxRow> {
//add property in editor
OrderID: number;
protected form = new xxxForm(this.idPrefix);
........
}
}
// and finally in master entity dialog pass value at afterLoadEntity event like this
afterLoadEntity() {
super.afterLoadEntity();
this.form.xxx.OrderID = value goes here
} |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
reach2rv
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
Can someone suggest how we can pass master entity values to child => child dialog, My setup is as below
Master Entity
Child Entity
Child Entity
Thanks
Beta Was this translation helpful? Give feedback.
All reactions