Updates to login home

This commit is contained in:
Deon George
2018-08-09 09:33:51 +10:00
parent b9cf666581
commit ca402df525
12 changed files with 166 additions and 39 deletions

View File

@@ -11,23 +11,24 @@
<div class="box-body">
@if ($user->all_accounts()->count())
<table class="table table-bordered table-striped table-hover" id="clients" style="width: 100%;">
<table class="table table-bordered table-striped table-hover" id="accounts" style="width: 100%;">
<thead>
<tr>
<th>ID</th>
<th>Profile</th>
<th>Name</th>
<th>Active</th>
<th>Services</th>
</tr>
</thead>
<tfoot>
<tr>
<th>Count {{ $user->all_accounts()->count() }}</th>
<th colspan="2">&nbsp;</th>
<th colspan="3">&nbsp;</th>
</tr>
</tfoot>
</table>
@else
<p>No Clients Active</p>
<p>No Accounts Active</p>
@endif
</div>
</div>
@@ -45,23 +46,25 @@
</style>
<script type="text/javascript">
$(document).ready(function() {
$('#clients').DataTable( {
$('#accounts').DataTable( {
responsive: true,
ajax: {
url: "/api/r/accounts"
},
columns: [
{ data: "id" },
{ data: "switch_url" },
{ data: "company" },
{ data: "active_display" }
{ data: "active_display" },
{ data: "services_count_html" }
],
language: {
emptyTable: "No Active Clients"
},
order: [1, 'asc']
order: [1, 'asc'],
pageLength: 25
});
$('#clients tbody').on('click','tr', function () {
$('#accounts tbody').on('click','tr', function () {
$(this).toggleClass('selected');
});
});