73 lines
3.3 KiB
PHP
73 lines
3.3 KiB
PHP
@php use App\Helpers\PositionHelper; @endphp
|
|
@extends('layouts.admin_layout')
|
|
@section('content')
|
|
@auth()
|
|
<div class="row">
|
|
<div class="col">
|
|
<h1 class="">Прикрепить файл</h1>
|
|
{{ Form::open(['url' => route('direction_descriptions.store'), 'method' => 'POST', 'files'=>'true', 'class' => 'needs-validation', 'novalidate']) }}
|
|
|
|
<div class="mt-3">
|
|
{{ Form::label('direction_code', 'Направление', ['data-bs-toggle' => "tooltip", 'data-bs-title' => __('tooltips.direction.department_id')]) }}
|
|
<span class="text-danger">*</span>
|
|
</div>
|
|
<div class="mt-1">
|
|
{{ Form::select('direction_code', $directionCodes, null, ['class' => 'form-select', 'data-bs-toggle' => "tooltip", 'data-bs-title' => __('tooltips.direction.department_id'), 'required']) }}
|
|
<div class="invalid-feedback">
|
|
Поле "Направление" обязательно!
|
|
</div>
|
|
</div>
|
|
<div class="text-danger">
|
|
@if ($errors->any())
|
|
{{ $errors->first('direction_code') }}
|
|
@endif
|
|
</div>
|
|
|
|
<div class="mt-3">
|
|
{{ Form::label('file', 'Путь к Файлу', ['data-bs-toggle' => "tooltip", 'data-bs-title' => __('tooltips.direction.department_id')]) }}
|
|
<span class="text-danger">*</span>
|
|
</div>
|
|
<div class="mt-1">
|
|
{{ Form::file('file', ['class' => 'form-control', 'data-bs-toggle' => "tooltip", 'data-bs-title' => __('tooltips.direction.department_id'), 'required']) }}
|
|
<div class="invalid-feedback">
|
|
Поле "Путь к документу" обязательно!
|
|
</div>
|
|
</div>
|
|
<div class="text-danger">
|
|
@if ($errors->any())
|
|
{{ $errors->first('file') }}
|
|
@endif
|
|
</div>
|
|
<div class="mt-3">
|
|
{{ Form::label('file_name', 'Имя файла') }}
|
|
</div>
|
|
<div class="mt-1">
|
|
{{ Form::text('file_name', '', ['class' => 'form-control']) }}
|
|
</div>
|
|
<div>
|
|
@if ($errors->any())
|
|
{{ $errors->first('name') }}
|
|
@endif
|
|
</div>
|
|
|
|
<div class="mt-3">
|
|
{{ Form::label('position', 'Позиция') }}
|
|
</div>
|
|
<div class="mt-1">
|
|
{{ Form::text('position', PositionHelper::directionDescription(), ['class' => 'form-control']) }}
|
|
</div>
|
|
<div>
|
|
@if ($errors->any())
|
|
{{ $errors->first('position') }}
|
|
@endif
|
|
</div>
|
|
|
|
<div class="mt-4">
|
|
{{ Form::submit('Загрузить файл', ['class' => 'btn btn-primary'])}}
|
|
</div>
|
|
{{Form::close()}}
|
|
</div>
|
|
</div>
|
|
@endauth
|
|
@endsection
|