public partial class TaxInfoTaxFiled { public System.Guid TaxInfoTaxFieldID { get; set; } public Nullable<System.Guid> TaxInfoID { get; set; } public Nullable<System.Guid> TaxFieldID { get; set; } public Nullable<System.Guid> FieldTypeID { get; set; } public string FieldValue { get; set; } } public partial class TaxField { public System.Guid TaxFieldID { get; set; } public string DisplayName { get; set; } public string PrintName { get; set; } }
public string TinNo { get; set; } public string CstNo { get; set; } public string ExciseRegNo { get; set; } public string PanNo { get; set; } public string ServiceTaxNo { get; set; } public string CinNo { get; set; } public List<TaxField> TaxField { get; set; } public List<TaxInfoTaxFiled> TaxInfoTaxFiled { get; set; } }
ArrayList Alist = new ArrayList(); { Alist.Add("FD713788-B5AE-49FF-8B2C-F311B9CB0CC4"); Alist.Add("64B512E7-46AE-4989-A049-A446118099C4"); Alist.Add("376D45C8-659D-4ACE-B249-CFBF4F231915"); Alist.Add("59A2449A-C5C6-45B5-AA00-F535D83AD48B"); Alist.Add("03ADA903-D09A-4F53-8B67-7347A08EDAB1"); Alist.Add("2F405521-06A0-427C-B9A3-56B8931CFC57"); } ArrayList objValue=new ArrayList(); { objValue.Add(viewmodel.TinNo); objValue.Add(viewmodel.CstNo); objValue.Add(viewmodel.PanNo); objValue.Add(viewmodel.CinNo); objValue.Add(viewmodel.ExciseRegNo); objValue.Add(viewmodel.ServiceTaxNo); } foreach (var tax in viewmodel.TaxInfoTaxFiled) { foreach (var i in Alist) { tax.FieldTypeID = Guid.Parse(i.ToString()); } foreach (var j in objValue) { tax.FieldValue = j.ToString(); } db.TaxInfoTaxFiled.Add(tax); }
<div class="editor-label"> @Html.LabelFor(model => model.TinNo) </div> <div class="editor-field"> @Html.EditorFor(model => model.TinNo) @Html.ValidationMessageFor(model => model.TinNo) </div> <div class="editor-label"> @Html.LabelFor(model => model.CstNo) </div> <div class="editor-field"> @Html.EditorFor(model => model.CstNo) @Html.ValidationMessageFor(model => model.CstNo) </div> <div class="editor-label"> @Html.LabelFor(model => model.ExciseRegNo) </d <div class="editor-label"> @Html.LabelFor(model => model.PanNo) </div> <div class="editor-field"> @Html.EditorFor(model => model.PanNo) @Html.ValidationMessageFor(model => model.PanNo) </div> <div class="editor-label"> @Html.LabelFor(model => model.ServiceTaxNo) </div> <div class="editor-field"> @Html.EditorFor(model => model.ServiceTaxNo) @Html.ValidationMessageFor(model => model.ServiceTaxNo) </div> <div class="editor-label"> @Html.LabelFor(model => model.CinNo) </div> <div class="editor-field"> @Html.EditorFor(model => model.CinNo) @Html.ValidationMessageFor(model => model.CinNo) </div> <p> <input type="submit" value="Create" /> </p>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)