Base solution for your next web application
Open Closed

How to create master child entry form #997


User avatar
0
mabood created

Hello, I am trying to create one master child entry form in asp.net zero MPA. I don’t want to save master data first and child data one by one. All data should be saved at once in one form.I have attached sample form design to this post I don’t know how to pass the values of form to service abp.services.app. In all my forms I have used $form.serializeFormToObject for passing data to create function but in case of master and child I don’t know how to pass table of items to create function. Can any one help me in this problem? public class Invoice { public virtual date InvoiceDate { get; set; } public virtual string InvoiceNumber { get; set; } public virtual ICollection<Item> Items { get; set; } } public class Item { [ForeignKey("InvoiceId")] public virtual Invoice invoice { get; set; } public virtual int InvoiceId { get; set; } public virtual string Type { get; set; } public virtual int Qty{ get; set; } public virtual int Amount { get; set; } }


1 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    After serializing form, you need to manually handle to child data.

    This post might give you an idea. <a class="postlink" href="http://stackoverflow.com/questions/4034103/serialize-inputs-in-table-rows-jquery">http://stackoverflow.com/questions/4034 ... ows-jquery</a>