title: How to specify data type for datatable colums?
body: <p>This is my razor. Everything working fine. I just want one thing. 
  1. I have date type column I want to defined it's data type as datetime so that shorting work properly. I have added below code that shows my full implementation.      </p>
  
  <pre><code>&lt;table class="table table-striped table-bordered table-hover" id="grid"&gt;
    &lt;thead&gt;
      &lt;tr&gt;
        &lt;th&gt;@Html.DisplayName("Order No")&lt;/th&gt;
        &lt;th&gt;@Html.DisplayName("Customer")&lt;/th&gt;
        &lt;th&gt;@Html.DisplayName("Dealer")&lt;/th&gt;
        &lt;th&gt;@Html.DisplayName("Status")&lt;/th&gt;
        &lt;th&gt;@Html.DisplayName("Date")&lt;/th&gt;
        &lt;th&gt;&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/thead&gt;
    &lt;tbody&gt;
      @foreach (ServiceRequestBycountry service in Model)
       {
         &lt;tr&gt;
           &lt;td&gt;.....&lt;/td&gt;
           &lt;td&gt;.....&lt;/td&gt;
           &lt;td&gt;.....&lt;/td&gt;
           &lt;td&gt;.....&lt;/td&gt;
           &lt;td&gt;
             @if (service.CreatedOnUtc != null){
                DateTime servicedate = Convert.ToDateTime(service.CreatedOnUtc);
                @servicedate.ToLocalDate().ToString("dd-MMM-yyyy");
             }
           &lt;/td&gt;
           &lt;td&gt;.....&lt;/td&gt;
         &lt;/tr&gt;
       }
      &lt;/tbody&gt;
    &lt;/table&gt;
  
  
  @section scripts{
      &lt;script type="text/javascript"&gt;
          $(function () {
              var table = $('#grid').DataTable({
                  'aoColumnDefs': [{
                      'bSortable': false,
                      'aTargets': -1
                  }],
                  "order": [[4, "desc"]]
              });
          });
      &lt;/script&gt;
  }
  </code></pre>
  
  <blockquote>
    <p>I have also added the <a href="https://jsfiddle.net/Lcf7j3wj/1/" rel="nofollow">JsFidder</a></p>
  </blockquote>