This is my js code :
$(document).ready(function () {
var table = $('#users-data-table').DataTable({
stateSave : true,
processing : true,
serverSide: true,
ajax: {
url: '@(Url.Action("GetFilterUsers", "Users", new { area = "Admin" }))',
type: "GET"
},
columns: [
{ "data": "Name", "orderable" : false },
{ "data": "DateCreated", "orderable": false },
{ "data": "TotalBroadcasts", "orderable": false },
{ "data": "TotalViews", "orderable": false },
{ "data": "City", "orderable": false }
{ "data": "Country", "orderable": false }
]
});
});
HTML:
<div class="dataTable_wrapper">
<table class="table table-striped table-bordered table-hover" id="users-data-table">
<thead>
<th>Name</th>
<th>DateCreated</th>
<th>Total broadcasts</th>
<th>Viewers</th>
<th>Location</th>
</thead>
</table>
</div>
I want to display "City", and "Country" in one column, and I want to display additional tag in every row with them (for example:<i class="fa fa-flag"></i>).How can I do this?
{"data: ["City", "Country"], "orderable": false}