Add Detail record in Master Detail form

In a generated Master-Detail Hierarchy form, when I click on the "Add" button of a detail record, it pops up a dialog with the generated Add Detail entity form. In that detail form, it asks me to select the foreign key / master entity.

How can I edit the detail form so that it picks up the Master's ID and includes it on submit?

Hidden text field with value= ${detailentity.parentID} and somehow populate the value on form submit?

Thank you in advance.

referencing

Hi @woody2,

I'm unable to reproduce this using the latest version of Radzen and our Sample database Orders -> OrderDetails:

OrderId was passed automatically to Add Order Detail page:

Thank you. I deleted the auto-generated child entity pages and regenerated from Master Detail Hierarchy template and the code you showed above was generated.