 <div class="wrapper wrapper-content animated fadeInRight">
	<div class="row">
		<div class="col-lg-12">
			<div class="ibox float-e-margins">
				<div class="ibox-title">
					<h5 id="sub_title"></h5>
					<div class="ibox-tools">
					</div>
				</div>
				<div class="ibox-content">
					<div class="table-responsive ">
						<table id="privilegeDataTable" class="table table-striped table-bordered table-hover" style="width:100%;" >
							<thead>
								<tr>
									<th>Description</th>
									<th>Akses</th>
								</tr>
							</thead>
						</table>
					</div>
				</div>
			</div>
		</div>
	</div>
</div>
<script>
	$(document).ready(function(){
		   $('#privilegeDataTable').DataTable({
			  'processing': true,
			  'serverSide': true,
			  'serverMethod': 'post',
			  'ajax': {
				  'url': site_url+"settings/privilege/listPage/",
					'data': function ( d ) {
					}
			  },
			"columnDefs": [
				{
				"render": function (data, type, row) {
					var res = '';
					if(row['idOperatorType']!=1)
					{
						res = 
						'<div class="btn-group">'+
							'<button data-toggle="dropdown" class="btn btn-default btn-xs dropdown-toggle">Action <span class="caret"></span></button>'+
							'<ul class="dropdown-menu">'+
								'<li><a href="'+site_url+'settings/privilege/input/'+row['idOperatorType']+'">Edit</a></li>'+
								'<li class="divider"></li>'+
								'<li><a href="#">Delete</a></li>'+
							'</ul>'+
						'</div>';
					}else{
						res = 'Full Akses';
					}
					return res;
				},
				"targets": 1,
				"orderable": false
				},
			],
			'columns': [
			 { data: 'description' },
			 { defaultContent: '' },
			],
			initComplete: function () {
			},
		   });
	});
	
	function refreshDataTable()
	{
		$('#privilegeDataTable').DataTable().ajax.reload( null, false );
	}
</script>