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

229 lines
13 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@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;
}
.modal-backdrop{
display: 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="/admin">Admin</a></li>
<li class="breadcrumb-item"><a href="/admin/application">Application</a></li>
<li class="breadcrumb-item active" aria-current="page">{{ $application->id }}</li>
</ol>
</nav>
<div class="row">
<div class="col-lg-4">
<div class="card">
<div class="card-body">
@if($application->state == 'applied')
<button class="btn btn-primary mb-4" type="button" data-toggle="modal" data-target="#successModal">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-check2-square" viewBox="0 0 16 16">
<path d="M3 14.5A1.5 1.5 0 0 1 1.5 13V3A1.5 1.5 0 0 1 3 1.5h8a.5.5 0 0 1 0 1H3a.5.5 0 0 0-.5.5v10a.5.5 0 0 0 .5.5h10a.5.5 0 0 0 .5-.5V8a.5.5 0 0 1 1 0v5a1.5 1.5 0 0 1-1.5 1.5H3z"/>
<path d="m8.354 10.354 7-7a.5.5 0 0 0-.708-.708L8 9.293 5.354 6.646a.5.5 0 1 0-.708.708l3 3a.5.5 0 0 0 .708 0z"/>
</svg> &nbsp;
Approve
</button>
<div class="modal fade" id="successModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog modal-primary" role="document">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Fill the form</h4>
<button class="close" type="button" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
</div>
<form class="form-horizontal" action="/admin/approve-application/{{ $application->id }}" method="post">
@csrf
<div class="modal-body">
<div class="card-body">
<input type="hidden" name="id" value="{{ $application->id }}">
<div class="form-group row">
<label class="col-sm-5 col-form-label" for="input-normal">Legalizatnio number</label>
<div class="col-sm-6">
<input name="legalization_number" class="form-control" id="input-normal" type="text" name="input-normal" placeholder="Normal">
</div>
</div>
<div class="form-group row">
<label class="col-sm-5 col-form-label" for="input-normal">Expiration date</label>
<div class="col-sm-6">
<input name="expires_at" class="form-control" id="input-normal" type="date" name="input-normal" placeholder="Normal">
</div>
</div>
</div>
</div>
<div class="modal-footer">
<button class="btn btn-secondary" type="button" data-dismiss="modal">Close</button>
<button class="btn btn-success" type="submit">Save</button>
</div>
</form>
</div>
<!-- /.modal-content-->
</div>
<!-- /.modal-dialog-->
</div>
@else
<button class="btn btn-secondary mb-4" type="button">Approved</button>
@endif
<a href="/admin/create-application-ticket" class="btn btn-success mb-4">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" class="bi bi-ticket-perforated" viewBox="0 0 16 16">
<path d="M4 4.85v.9h1v-.9H4Zm7 0v.9h1v-.9h-1Zm-7 1.8v.9h1v-.9H4Zm7 0v.9h1v-.9h-1Zm-7 1.8v.9h1v-.9H4Zm7 0v.9h1v-.9h-1Zm-7 1.8v.9h1v-.9H4Zm7 0v.9h1v-.9h-1Z"/>
<path d="M1.5 3A1.5 1.5 0 0 0 0 4.5V6a.5.5 0 0 0 .5.5 1.5 1.5 0 1 1 0 3 .5.5 0 0 0-.5.5v1.5A1.5 1.5 0 0 0 1.5 13h13a1.5 1.5 0 0 0 1.5-1.5V10a.5.5 0 0 0-.5-.5 1.5 1.5 0 0 1 0-3A.5.5 0 0 0 16 6V4.5A1.5 1.5 0 0 0 14.5 3h-13ZM1 4.5a.5.5 0 0 1 .5-.5h13a.5.5 0 0 1 .5.5v1.05a2.5 2.5 0 0 0 0 4.9v1.05a.5.5 0 0 1-.5.5h-13a.5.5 0 0 1-.5-.5v-1.05a2.5 2.5 0 0 0 0-4.9V4.5Z"/>
</svg> &nbsp;
Create ticket
</a>
@if ($application->account->type == 'business')
<div class="form-group">
<label for="company"><small>Profile type</small></label>
<h6><strong>Entreprenuer</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Country</small></label>
<h6><strong>{{ $application->account->country->name ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Name</small></label>
<h6><strong>{{ $application->account->profile->name ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Surname</small></label>
<h6><strong>{{ $application->account->profile->surname ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Patronomic</small></label>
<h6><strong>{{ $application->account->profile->patronomic_name ?? null }}</strong></h6>
</div>
@if (isset($application->account->profile->date_of_birth))
<div class="form-group">
<label for="company"><small>Date of birth</small></label>
<h6><strong>{{ Carbon\Carbon::parse($application->account->profile->date_of_birth)->format('d.m.Y') }}</strong></h6>
</div>
@endif
<div class="form-group">
<label for="company"><small>Birthplace</small></label>
<h6><strong>{{ $application->account->profile->birth_place ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Registration address</small></label>
<h6><strong>{{ $application->account->profile->registration_address ?? null }}</strong></h6>
</div>
@else
<div class="form-group">
<label for="company"><small>Profile type</small></label>
<h6><strong>Company</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Name</small></label>
<h6><strong>{{ $application->account->profile->name ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Short name</small></label>
<h6><strong>{{ $application->account->profile->short_name ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Registration number</small></label>
<h6><strong>{{ $application->account->profile->registration_number ?? null }}</strong></h6>
</div>
@if (isset($application->account->profile->registration_date))
<div class="form-group">
<label for="company"><small>Registration date</small></label>
<h6><strong>{{ Carbon\Carbon::parse($application->account->profile->registration_date)->format('d.m.Y') }}</strong></h6>
</div>
@endif
<div class="form-group">
<label for="company"><small>Registration agency</small></label>
<h6><strong>{{ $application->account->profile->state_registration_agency ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Registration place</small></label>
<h6><strong>{{ $application->account->profile->registration_place ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Registration address</small></label>
<h6><strong>{{ $application->account->profile->registration_address ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Fond capital</small></label>
<h6><strong>{{ $application->account->profile->fond_capital ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Management types</small></label>
<h6><strong>{{ $application->account->profile->management_types ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Signers</small></label>
<h6><strong>{{ $application->account->profile->signers ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Share holders</small></label>
<h6><strong>{{ $application->account->profile->share_holders ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Organizational form</small></label>
<h6><strong>{{ $application->account->profile->organizational_form ?? null }}</strong></h6>
</div>
<div class="form-group">
<label for="company"><small>Is agent?</small></label>
<h6><strong>{{ $application->account->profile->is_agent ?? false }}</strong></h6>
</div>
@endif
</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="#attachments" 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;
Attachments
<span class="badge badge-pill badge-secondary">{{ count($application->attachments) }}</span>
</a>
</li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="attachments" role="tabpanel">
<table class="table table-responsive-sm table-striped mb-0">
<thead class="thead-light">
<tr>
<th>Name</th>
<th>Size (Kb)</th>
<th>Type</th>
</tr>
</thead>
<tbody>
@foreach ($application->attachments as $attachment)
@if ($attachment->file)
<tr>
<td>
<a class="nav-link" href="/storage/{{ $attachment->file }}" target="_blank">
{{ $attachment->name }}
</a>
</td>
<td>
{{ $attachment->size }} Kb
</td>
<td>
{{ $application->type }}
</td>
</tr>
@endif
@endforeach
</tbody>
</table>
</div>
</div>
</div>
</div>
@endsection