Commit 8fb82d98 authored by Viral Solani's avatar Viral Solani

- resolve datatable error

parent 2de3c975
......@@ -36,7 +36,7 @@ class RoleTableController extends Controller
->escapeColumns(['name', 'sort'])
->addColumn('permissions', function ($role) {
if ($role->all) {
return '<span class="label label-success">'.trans('labels.general.all').'</span>';
return '<span class="label label-success">' . trans('labels.general.all') . '</span>';
}
return $role->permission_name;
......
......@@ -27,7 +27,6 @@ class ManageRoleRequest extends Request
public function rules()
{
return [
//
];
}
}
......@@ -68,6 +68,12 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#permissions-table').dataTable({
processing: true,
serverSide: true,
......
......@@ -70,12 +70,19 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#roles-table').dataTable({
processing: true,
serverSide: true,
ajax: {
url: '{{ route("admin.access.role.get") }}',
type: 'post'
type: 'post',
},
columns: [
{data: 'name', name: '{{config('access.roles_table')}}.name'},
......
......@@ -65,6 +65,11 @@
{{ Html::script(mix('js/dataTable.js')) }}
<script>
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
$(function() {
var dataTable = $('#blogcategories-table').dataTable({
processing: true,
......
......@@ -68,6 +68,12 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#blogs-table').dataTable({
processing: true,
serverSide: true,
......
......@@ -66,6 +66,12 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#blogtags-table').dataTable({
processing: true,
serverSide: true,
......
......@@ -70,6 +70,12 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#faqs-table').dataTable({
processing: true,
serverSide: true,
......
......@@ -67,6 +67,13 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#menus-table').dataTable({
processing: true,
serverSide: true,
......
......@@ -66,6 +66,12 @@
<script>
$(function() {
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
}
});
var dataTable = $('#pages-table').dataTable({
processing: true,
serverSide: true,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment