title: Ajax call is not binding all model properties
body: <p>I am going to create table using jquery on the basis of selection in dropdownlist..When I select any option in dropdown the blank table will be generated on the screen..But when i insert values in blank table and press submit then in action I got model but that model consist only properties in the table which I have added from Ajax..But it ignores value of dropdownlist which I have selected first..If I remove that ajax success code then it gives model with proper values but I wont get values in Table created by ajax success....</p>
  
  <p>Here is my ajax code:</p>
  
  <pre><code> $("#Award").change(function () {
          var selectdAward = $("#Award").val();
          $('#criteriaTable').empty();
          var ServiceUrl = "/Nomination/CriteriasForAward?awardId=" + selectdAward;
  
          $.ajax({
              type: 'post',
              url: ServiceUrl,
              contentType: "application/json; charset=utf-8",
              error: function (xhr, err) {
                  alert(xhr.responseText)
              },
              success: function (data) {
                  $('#criteriaTable').append('&lt;tr&gt;&lt;th&gt;Id&lt;/th&gt;&lt;th&gt;Criteria-Description&lt;/th&gt;&lt;th&gt;Comment&lt;/th&gt;&lt;/tr&gt;');
  
                  for (var key in data) {
                      $('#criteriaTable tr:last')
                          .after('&lt;tr&gt;&lt;td&gt;&lt;label&gt;' + data[key].Id + '&lt;/label&gt;&lt;/td&gt;' 
                          + '&lt;td&gt;&lt;label&gt;' + data[key].Title + '&lt;/label&gt;&lt;/td&gt;'
                          + '&lt;td&gt;&lt;input type="text" name=Model.Comments[' + key + '].Comment&gt;&lt;/td&gt;'
                          + '&lt;td&gt;&lt;input type="hidden" name=Model.Comments[' + key + '].Id value=' + data[key].Id + '&gt;&lt;/td&gt;&lt;/tr&gt;');
                  }
              }
          });
      });
  </code></pre>
  
  <p>This is my ViewModel:</p>
  
  <pre><code> public class NominationViewModel
      {
          public int AwardId { get; set; }
          public int ManagerId { get; set; }
          public int UserId { get; set; }
          public int ProjectID { get; set; }
          public string SelectResourcesBy { get; set; }  //from project or from department
          public IList&lt;CriteriaCommentViewModel&gt; Comments { get; set; }
  
          public NominationViewModel()
          {
              Comments = new List&lt;CriteriaCommentViewModel&gt;();   
          }
  
      }
  </code></pre>
  
  <p>This is navigational property class in view model:</p>
  
  <pre><code> public class CriteriaCommentViewModel
      {
          public int Id { get; set; }
          public string Comment { get; set; }
      }
  </code></pre>
  
  <p>This is the view:</p>
  
  <pre><code>@using (Html.BeginForm())
  {
      @Html.AntiForgeryToken()
  
      &lt;div class="form-horizontal"&gt;
          &lt;hr /&gt;
          @Html.ValidationSummary(true, "", new { @class = "text-danger" })
          &lt;div class="form-group"&gt;
              @Html.Label("Nomination Category", htmlAttributes: new { @class = "control-label col-md-4" })
  
              &lt;div class="col-md-8"&gt;
                  @Html.DropDownListFor(model =&gt; model.AwardId, @ViewBag.Awards as SelectList, "Select", new { htmlAttributes = new { @class = "form-control" }, id = "Award" })
                  @Html.ValidationMessageFor(model =&gt; model.AwardId, "", new { @class = "text-danger" })
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="form-group"&gt;
              @Html.Label("Resource From", htmlAttributes: new { @class = "control-label col-md-4" })
              &lt;div class="col-md-8"&gt;
                  &lt;label&gt; @Html.RadioButtonFor(model =&gt; model.SelectResourcesBy, "Project", new { htmlAttributes = new { @class = "form-control" } })Project&lt;/label&gt;
                  &lt;label&gt; @Html.RadioButtonFor(model =&gt; model.SelectResourcesBy, "Department", new { htmlAttributes = new { @class = "form-control" } })Department&lt;/label&gt;
                  @Html.ValidationMessageFor(model =&gt; model.UserId, "", new { @class = "text-danger" })
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="form-group"&gt;
              @Html.Label("Project", htmlAttributes: new { @class = "control-label col-md-4" })
              &lt;div class="col-md-8"&gt;
                  @Html.DropDownListFor(model =&gt; model.ProjectID, @ViewBag.ProjectsUnderCurrentUser as SelectList, "Select", new { htmlAttributes = new { @class = "form-control" }, id = "SelectedProject" })
                  @Html.ValidationMessageFor(model =&gt; model.ManagerId, "", new { @class = "text-danger" })
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="form-group"&gt;
              @Html.Label("Resource Name", htmlAttributes: new { @class = "control-label col-md-4" })
              &lt;div class="col-md-8"&gt;
                  @Html.DropDownListFor(model =&gt; model.UserId, @ViewBag.Resources as SelectList, "Select", new { htmlAttributes = new { @class = "form-control" }, id = "Resources" })
                  @Html.ValidationMessageFor(model =&gt; model.UserId, "", new { @class = "text-danger" })
              &lt;/div&gt;
          &lt;/div&gt;
          &lt;br /&gt;
          &lt;br /&gt;
          &lt;hr /&gt;
  
          &lt;div class="form-group"&gt;
              @Html.Label("Criteria", htmlAttributes: new { @class = "control-label col-md-2" })
              &lt;br /&gt;
              &lt;div class="form-group"&gt;
                  &lt;div id="Criterias"&gt;
                      &lt;table border="1" id="criteriaTable"&gt;&lt;/table&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
          &lt;/div&gt;
          &lt;div class="form-group"&gt;
              &lt;div class="col-md-offset-2 col-md-10"&gt;
                  &lt;input type="button" value="Save Draft" class="btn btn-default" /&gt;
                  &lt;input type="submit" value="Submit" class="btn btn-default" /&gt;
                  &lt;input type="button" value="Cancel" class="btn btn-default" /&gt;
              &lt;/div&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  }
  
  &lt;div&gt;
      @Html.ActionLink("Back to List", "Index")
  &lt;/div&gt;
  </code></pre>
  
  <p>And this is the controller action on which i m posting values:</p>
  
  <pre><code>  [HttpPost]
          public ActionResult AddNomination(NominationViewModel model)
          {
              return RedirectToAction("Dashboard", "Dashboard");
          }
  </code></pre>
  
  <p>Please suggest the way to solve this problem..Thanks in advance</p>