birzha-legalizasia/resources/views/admin/preview.blade.php

131 lines
6.5 KiB
PHP

@extends(backpack_view('blank'))
@section('content')
<style>
.btn.focus, .btn:focus, .dataTables_wrapper .dataTables_paginate .focus.paginate_button, .dataTables_wrapper .dataTables_paginate .paginate_button:focus{
box-shadow: none;
}
</style>
<nav aria-label="breadcrumb" class="d-none d-lg-block">
<ol class="breadcrumb m-0 mb-3">
<li class="breadcrumb-item"><a href="#">{{ trans('app.last_updates.admin') }}</a></li>
<li class="breadcrumb-item"><a href="{{backpack_url('account')}}">{{ trans('app.ticket.account') }}</a></li>
<li class="breadcrumb-item active" aria-current="page">{{ $account->id }}</li>
</ol>
</nav>
<div class="row">
<div class="col-lg-4">
<div class="card">
<div class="card-body">
@include('admin.account.'.$account->type)
</div>
</div>
</div>
<div class="col-md-8 mb-4">
<ul class="nav nav-tabs" role="tablist">
<li class="nav-item">
<a class="nav-link active" data-toggle="tab" href="#applications" role="tab" aria-controls="applications" aria-selected="true">
<svg style="width: 18px" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-6 h-6">
<path stroke-linecap="round" stroke-linejoin="round" d="M19.5 14.25v-2.625a3.375 3.375 0 00-3.375-3.375h-1.5A1.125 1.125 0 0113.5 7.125v-1.5a3.375 3.375 0 00-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 00-9-9z" />
</svg>&nbsp;
{{ trans('app.application.list_title') }}
<span class="badge badge-pill badge-secondary">{{ count($account->applications) }}</span>
</a>
</li>
<li class="nav-item">
<a class="nav-link" data-toggle="tab" href="#users" role="tab" aria-controls="users" aria-selected="false">
<svg style="width: 18px" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-6 h-6">
<path stroke-linecap="round" stroke-linejoin="round" d="M15 19.128a9.38 9.38 0 002.625.372 9.337 9.337 0 004.121-.952 4.125 4.125 0 00-7.533-2.493M15 19.128v-.003c0-1.113-.285-2.16-.786-3.07M15 19.128v.106A12.318 12.318 0 018.624 21c-2.331 0-4.512-.645-6.374-1.766l-.001-.109a6.375 6.375 0 0111.964-3.07M12 6.375a3.375 3.375 0 11-6.75 0 3.375 3.375 0 016.75 0zm8.25 2.25a2.625 2.625 0 11-5.25 0 2.625 2.625 0 015.25 0z" />
</svg>&nbsp;
{{ trans('app.user.users') }}
<span class="badge badge-pill badge-secondary">{{ count($account->clients) }}</span>
</a>
</li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="applications" role="tabpanel">
<table class="table table-responsive-sm table-striped mb-0">
<thead class="thead-light">
<tr>
<th>{{ trans('app.ticket.status') }}</th>
<th>{{ trans('app.last_updates.state') }}</th>
<th>{{ trans('app.application.created_at') }}</th>
<th>{{ trans('app.last_updates.actions') }}</th>
</tr>
</thead>
<tbody>
@foreach ($account->applications as $application)
<tr>
<td>
<div>
@if($application->status)
<div>{{ trans('app.last_updates.closed') }}</div>
@else
<div>{{ trans('app.last_updates.open') }}</div>
@endif
</div>
</td>
<td>
{{ $application->state }}
</td>
<td>
<div class="small text-muted"></div><strong>{{ trans('app.company.registration_date') }}: {{ Carbon\Carbon::parse($application->created_at)->format('M d Y') }}</strong>
</td>
<td>
<a class="nav-link p-0" href="{{backpack_url('preview-application')}}/{{ $application->id }}">
<svg style="width: 20px" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-6 h-6">
<path stroke-linecap="round" stroke-linejoin="round" d="M13.5 6H5.25A2.25 2.25 0 003 8.25v10.5A2.25 2.25 0 005.25 21h10.5A2.25 2.25 0 0018 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25" />
</svg>
</a>
</td>
</tr>
@endforeach
</tbody>
</table>
</div>
<div class="tab-pane" id="users" role="tabpanel">
<div class="mb-3">
<a href="{{backpack_url('create-account-client')}}/{{ $account->id }}" class="btn btn-primary">
{{ trans('app.last_updates.add_new_user') }}
</a>
</div>
<table class="table table-responsive-sm table-striped mb-0">
<thead class="thead-light">
<tr>
<th>{{ trans('app.last_updates.fullname') }}</th>
<th>{{ trans('app.client.email') }}</th>
<th>{{ trans('app.company.registration_date') }}</th>
</tr>
</thead>
<tbody>
@foreach ($account->clients as $client)
<tr>
<td>
<a class="nav-link" href="{{backpack_url('client')}}/{{ $client->id }}/edit">
{{ $client->lastname }} {{ $client->firstname }}
</a>
</td>
<td>
{{ $client->email }}
</td>
<td>
<div class="small text-muted"></div><strong>{{ trans('app.company.registration_date') }}: {{ Carbon\Carbon::parse($client->created_at)->format('M d Y') }}</strong>
</td>
</tr>
@endforeach
</tbody>
</table>
</div>
</div>
</div>
</div>
@endsection