2018-04-21 19:18:00 +02:00
|
|
|
@extends('layout.default')
|
|
|
|
|
2019-05-01 20:19:18 +02:00
|
|
|
@section('title', $__t('API keys'))
|
2018-04-21 19:18:00 +02:00
|
|
|
@section('activeNav', '')
|
|
|
|
@section('viewJsName', 'manageapikeys')
|
|
|
|
|
2020-09-06 10:00:49 +02:00
|
|
|
@push('pageScripts')
|
|
|
|
<script src="{{ $U('/node_modules/qrcode-generator/qrcode.js?v=', true) }}{{ $version }}"></script>
|
|
|
|
@endpush
|
|
|
|
|
2020-01-28 19:27:18 +01:00
|
|
|
@push('pageStyles')
|
2020-08-31 20:32:50 +02:00
|
|
|
<link href="{{ $U('/node_modules/animate.css/animate.min.css?v=', true) }}{{ $version }}"
|
|
|
|
rel="stylesheet">
|
2018-04-21 19:18:00 +02:00
|
|
|
@endpush
|
|
|
|
|
|
|
|
@section('content')
|
2018-07-10 20:37:13 +02:00
|
|
|
<div class="row">
|
|
|
|
<div class="col">
|
2020-10-31 18:37:10 +01:00
|
|
|
<div class="title-related-links">
|
|
|
|
<h2 class="title">@yield('title')</h2>
|
|
|
|
<div class="related-links">
|
|
|
|
<a class="btn btn-primary responsive-button"
|
|
|
|
href="{{ $U('/manageapikeys/new') }}">
|
|
|
|
{{ $__t('Add') }}
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-04-19 08:51:02 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
2020-10-31 18:37:10 +01:00
|
|
|
|
|
|
|
<hr class="my-2 py-1">
|
|
|
|
|
2020-04-19 08:51:02 -04:00
|
|
|
<div class="row">
|
2018-07-11 19:43:05 +02:00
|
|
|
<div class="col-xs-12 col-md-6 col-xl-3">
|
2020-10-31 18:37:10 +01:00
|
|
|
<div class="input-group">
|
2020-04-19 08:51:02 -04:00
|
|
|
<div class="input-group-prepend">
|
2020-08-31 20:32:50 +02:00
|
|
|
<span class="input-group-text"><i class="fas fa-search"></i></span>
|
2020-04-19 08:51:02 -04:00
|
|
|
</div>
|
2020-08-31 20:32:50 +02:00
|
|
|
<input type="text"
|
|
|
|
id="search"
|
|
|
|
class="form-control"
|
|
|
|
placeholder="{{ $__t('Search') }}">
|
2020-04-19 08:51:02 -04:00
|
|
|
</div>
|
2018-07-09 19:27:22 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2018-07-10 20:37:13 +02:00
|
|
|
<div class="row">
|
|
|
|
<div class="col">
|
2020-08-31 20:32:50 +02:00
|
|
|
<table id="apikeys-table"
|
|
|
|
class="table table-sm table-striped dt-responsive">
|
2018-07-10 20:37:13 +02:00
|
|
|
<thead>
|
|
|
|
<tr>
|
2019-03-09 10:49:26 +01:00
|
|
|
<th class="border-right"></th>
|
2019-05-01 20:19:18 +02:00
|
|
|
<th>{{ $__t('API key') }}</th>
|
|
|
|
<th>{{ $__t('User') }}</th>
|
|
|
|
<th>{{ $__t('Expires') }}</th>
|
|
|
|
<th>{{ $__t('Last used') }}</th>
|
|
|
|
<th>{{ $__t('Created') }}</th>
|
|
|
|
<th>{{ $__t('Key type') }}</th>
|
2018-07-10 20:37:13 +02:00
|
|
|
</tr>
|
|
|
|
</thead>
|
2019-01-05 20:06:35 +01:00
|
|
|
<tbody class="d-none">
|
2018-07-10 20:37:13 +02:00
|
|
|
@foreach($apiKeys as $apiKey)
|
|
|
|
<tr id="apiKeyRow_{{ $apiKey->id }}">
|
2019-03-09 10:49:26 +01:00
|
|
|
<td class="fit-content border-right">
|
2020-08-31 20:32:50 +02:00
|
|
|
<a class="btn btn-danger btn-sm apikey-delete-button"
|
|
|
|
href="#"
|
|
|
|
data-apikey-id="{{ $apiKey->id }}"
|
|
|
|
data-apikey-apikey="{{ $apiKey->api_key }}">
|
2018-07-11 19:43:05 +02:00
|
|
|
<i class="fas fa-trash"></i>
|
2018-07-10 20:37:13 +02:00
|
|
|
</a>
|
2020-09-06 10:00:49 +02:00
|
|
|
<a class="btn btn-info btn-sm apikey-show-qr-button"
|
|
|
|
href="#"
|
|
|
|
data-apikey-key="{{ $apiKey->api_key }}"
|
|
|
|
data-apikey-type="{{ $apiKey->key_type }}">
|
|
|
|
<i class="fas fa-qrcode"></i>
|
|
|
|
</a>
|
2018-07-10 20:37:13 +02:00
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
{{ $apiKey->api_key }}
|
|
|
|
</td>
|
2018-07-25 19:28:15 +02:00
|
|
|
<td>
|
|
|
|
{{ GetUserDisplayName(FindObjectInArrayByPropertyValue($users, 'id', $apiKey->user_id)) }}
|
|
|
|
</td>
|
2018-07-10 20:37:13 +02:00
|
|
|
<td>
|
|
|
|
{{ $apiKey->expires }}
|
2020-08-31 20:32:50 +02:00
|
|
|
<time class="timeago timeago-contextual"
|
|
|
|
datetime="{{ $apiKey->expires }}"></time>
|
2018-07-10 20:37:13 +02:00
|
|
|
</td>
|
|
|
|
<td>
|
2019-05-01 20:19:18 +02:00
|
|
|
@if(empty($apiKey->last_used)){{ $__t('never') }}@else{{ $apiKey->last_used }}@endif
|
2020-08-31 20:32:50 +02:00
|
|
|
<time class="timeago timeago-contextual"
|
|
|
|
datetime="{{ $apiKey->last_used }}"></time>
|
2018-07-10 20:37:13 +02:00
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
{{ $apiKey->row_created_timestamp }}
|
2020-08-31 20:32:50 +02:00
|
|
|
<time class="timeago timeago-contextual"
|
|
|
|
datetime="{{ $apiKey->row_created_timestamp }}"></time>
|
2018-07-10 20:37:13 +02:00
|
|
|
</td>
|
2019-03-04 17:44:48 +01:00
|
|
|
<td>
|
|
|
|
{{ $apiKey->key_type }}
|
|
|
|
</td>
|
2018-07-10 20:37:13 +02:00
|
|
|
</tr>
|
|
|
|
@endforeach
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
2018-04-21 19:18:00 +02:00
|
|
|
</div>
|
|
|
|
@stop
|