title: JQGrid is not loading data in MVC 5?
body: <p>I am using jqgrid  and table is working correctly. But no data is loading and it continuesly displaying "loading...". It worked correctly but i maybe due to some reason it is not working now. </p>
  
  <pre><code>public JsonResult GetDetails()
          {
              Database1Entities db = new Database1Entities();
  
  
              var jsondata = new
              {
                  total = 1,
                  page = 1,
                  records = db.Employees.ToList().Count.ToString(),
                  rows = db.Employees.Select(a =&gt; new {
                  a.Id,a.Name,a.Designation,a.Address,a.Salary
                  })
              };
  
              return Json(jsondata, JsonRequestBehavior.AllowGet);
          }
  </code></pre>
  
  <p>JQGrid function is below:</p>
  
  <pre><code>$(document).ready(function () {
      $("#Grid").jqGrid({
          url: '/Home/GetDetails',
          datatype: 'json',
          myType: 'GET',
          colNames: ['id','Name', 'Designation', 'Address', 'Salary'],
          colModel: [
  
              { key: false, name: 'Id', index: 'Id',  },
              { key: false, name: 'Name', index: 'Name', editable: true },
              { key: false, name: 'Designation', index: 'Designation', editable: true },
              { key: false, name: 'Address', index: 'Address', editable: true },
              { key: false, name: 'Salary', index: 'Salary', editable: true }
  
          ],
          jsonReader: {
              root: 'rows',
              page: 'page',
              total: 'total',
              records: 'records',
              id: '0',
              repeatitems: false
          },
          pager: $('#pager'),
          rowNum: 10,
          rowList: [10, 20, 30],
          width: 600,
          viewrecords: true,
          multiselect: true,
          sortname: 'Id',
          sortorder: "desc",
          caption: 'Employee Records',
          loadonce: true,
  
      }).navGrid('#pager', { edit: true, add: true, del: true },
      {
          zIndex: 100,
          url: '/Home/Edit',
          closeOnEscape: true,
          closeAfterEdit: true,
          recreateForm: true,
          afterComplete: function (response) {
              if (response.responseText)
              {
                  alert(response.responseText);
              }
          }
      },
      {
          zIndex: 10,
          url: '/Home/Add',
          closeOnEscape: true,
          closeAfterEdit: true,
          recreateForm: true,
          afterComplete: function (response) {
              if (response.responseText) {
                  alert(response.responseText);
              }
          }
      },
      {
          zIndex: 100,
          url: '/Home/Delete',
          closeOnEscape: true,
          closeAfterEdit: true,
          recreateForm: true,
          afterComplete: function (response) {
              if (response.responseText) {
                  alert(response.responseText);
              }
          }
      }
  
      );
  
  });
  </code></pre>
  
  <p>If i add something, it works and data is inserted into database but the main problem is not data is shown in JQGrid. What is the problem?</p>