ctrlpanel/themes/default/views/admin/users/index.blade.php

109 lines
4.1 KiB
PHP
Raw Normal View History

2021-06-05 09:26:32 +00:00
@extends('layouts.main')
@section('content')
<!-- CONTENT HEADER -->
<section class="content-header">
<div class="container-fluid">
<div class="row mb-2">
<div class="col-sm-6">
2021-12-13 09:12:32 +00:00
<h1>{{__('Users')}}</h1>
2021-06-05 09:26:32 +00:00
</div>
<div class="col-sm-6">
<ol class="breadcrumb float-sm-right">
2021-12-13 09:12:32 +00:00
<li class="breadcrumb-item"><a href="{{route('home')}}">{{__('Dashboard')}}</a></li>
<li class="breadcrumb-item"><a class="text-muted" href="{{route('admin.users.index')}}">{{__('Users')}}</a></li>
2021-06-05 09:26:32 +00:00
</ol>
</div>
</div>
</div>
</section>
<!-- END CONTENT HEADER -->
<!-- MAIN CONTENT -->
<section class="content">
<div class="container-fluid">
<div class="card">
<div class="card-header">
<div class="d-flex justify-content-between">
2021-12-13 09:12:32 +00:00
<h5 class="card-title"><i class="fas fa-users mr-2"></i>{{__('Users')}}</h5>
2021-08-04 20:01:50 +00:00
<a href="{{route('admin.users.notifications')}}" class="btn btn-sm btn-primary"><i
2021-12-13 09:12:32 +00:00
class="fas fa-paper-plane mr-1"></i>{{__('Notify')}}</a>
2021-06-05 09:26:32 +00:00
</div>
</div>
<div class="card-body table-responsive">
<table id="datatable" class="table table-striped">
<thead>
<tr>
<th>discordId</th>
<th>ip</th>
<th>pterodactyl_id</th>
2021-12-13 09:12:32 +00:00
<th>{{__('Avatar')}}</th>
<th>{{__('Name')}}</th>
<th>{{__('Role')}}</th>
<th>{{__('Email')}}</th>
<th>{{CREDITS_DISPLAY_NAME}}</th>
2021-12-13 09:12:32 +00:00
<th>{{__('Servers')}}</th>
2022-06-02 14:11:24 +00:00
<th>{{__("Referrals")}}</th>
2021-12-13 09:12:32 +00:00
<th>{{__('Verified')}}</th>
<th>{{__('Last seen')}}</th>
2021-06-05 09:26:32 +00:00
<th></th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</div>
</div>
<!-- END CUSTOM CONTENT -->
</section>
<!-- END CONTENT -->
<script>
function submitResult() {
2021-12-14 14:47:17 +00:00
return confirm("{{__('Are you sure you wish to delete?')}}") !== false;
2021-06-05 09:26:32 +00:00
}
document.addEventListener("DOMContentLoaded", function () {
$('#datatable').DataTable({
2021-12-13 21:39:40 +00:00
language: {
2022-08-17 08:33:44 +00:00
url: '//cdn.datatables.net/plug-ins/1.11.3/i18n/{{config("SETTINGS::LOCALE:DATATABLES")}}.json'
2021-12-13 21:39:40 +00:00
},
2021-06-05 09:26:32 +00:00
processing: true,
2022-08-14 18:42:52 +00:00
serverSide: false, //increases loading times too much? change back to "true" if it does
2021-06-05 09:26:32 +00:00
stateSave: true,
ajax: "{{route('admin.users.datatable')}}",
2022-06-17 12:35:01 +00:00
order: [[ 11, "asc" ]],
2021-06-05 09:26:32 +00:00
columns: [
{data: 'discordId', visible: false, name: 'discordUser.id'},
{data: 'pterodactyl_id', visible: false},
{data: 'ip', visible: false},
{data: 'avatar' , sortable : false},
{data: 'name'},
{data: 'role'},
{data: 'email', name: 'users.email'},
{data: 'credits' , name : 'users.credits'},
{data: 'servers'},
2022-06-02 14:11:24 +00:00
{data: 'referrals'},
2021-06-05 09:26:32 +00:00
{data: 'verified' , sortable : false},
{data: 'last_seen', type: 'num', render: {_: 'display', sort: 'raw'}},
2021-06-05 09:26:32 +00:00
{data: 'actions' , sortable : false},
],
fnDrawCallback: function( oSettings ) {
$('[data-toggle="popover"]').popover();
}
});
});
</script>
@endsection