@extends('layout')


@section('content')

<div class="page-header page-header-default">
	<div class="breadcrumb-line">
		<ul class="breadcrumb">
			<li><a href="#"><i class="icon-home2 position-left"></i> User</a></li>
			<li class="active">Setting Role</li>
		</ul>
	</div>
</div>

<div class="content">
	<div class="panel panel-flat">
		<div class="panel-heading">
			<h5 class="panel-title">Setting Role</h5>
			<div class="heading-elements">
				<ul class="icons-list">
		      		<li><a data-action="collapse"></a></li>
		      	</ul>
	       	</div>
	    </div>
	    <div class="panel-body">    
	    <table class="table datatable-basic table-striped table_role">
	    	<thead>
				<tr>
					<th width="4%">No</th>
					<th>Nama Group</th>
					<th class="text-center" width="15%">Aksi</th>
				</tr>	
			</thead>
			<tbody>

			</tbody>
	    </table>
	    </div>
	</div>
</div>



<script type="text/javascript">
	var tb;

	$(document).ready(function(){
		tb = $(".table_role").DataTable({
			processing: true,
	        serverSide: true,
	        ajax: '{{ url('role/tampil') }}',
	        columns: [
	            {data: 'rownum', name: 'rownum', orderable: false, searchable: false, render : function(data, type, full, meta){
			  		return meta.row+1;
			  	}},
	            {data: 'nama_group', name: 'tg.nama_group'},
	            {data: 'aksi', name: 'aksi', orderable: false, searchable: false}
	        ],
		});

	})	

</script>


@endsection