forked from aslan/applicant-site
70 lines
3.2 KiB
PHP
70 lines
3.2 KiB
PHP
@extends('layouts.admin_layout')
|
|
@section('content')
|
|
<div class="container">
|
|
<h2>Направления</h2>
|
|
<br>
|
|
<div class="d-grid gap-2 d-md-flex justify-content-between">
|
|
<a href="{{ route('directions.create') }}" class="btn btn-primary">Создать Направление</a>
|
|
<a href="{{ route('export_excel') }}" class="btn btn-info">Импорт xls</a>
|
|
</div>
|
|
<br>
|
|
<br>
|
|
<div class="row">
|
|
<div class="col-3">
|
|
{{Form::open(['route' => 'directions.index', 'method' => 'GET'])}}
|
|
{{Form::text('filter[name]', $filter['name'] ?? null, ['placeholder' => 'Введите название направления', 'class' => 'form-control'])}}
|
|
</div>
|
|
<div class="col">
|
|
{{Form::submit('Найти', ['class' => 'btn btn-primary'])}}
|
|
{{Form::close()}}
|
|
</div>
|
|
</div>
|
|
<table class="table">
|
|
<thead class="border-b-2 border-solid border-black text-left" style="text-align: left">
|
|
<tr>
|
|
|
|
<th scope="col">Позиция</th>
|
|
<th scope="col">Название</th>
|
|
<th scope="col">Описание</th>
|
|
<th scope="col">URL</th>
|
|
<th scope="col">Кафедра</th>
|
|
<th scope="col">Уровень образования</th>
|
|
<th scope="col">действия</th>
|
|
<th scope="col"></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach($directions as $direction)
|
|
<tr class="">
|
|
<th scope="row">{{ $direction->position }}</th>
|
|
<td><a href="{{ route('directions.show', $direction) }}">{{ $direction->name }}</a>
|
|
<br>
|
|
<p @style(['font-size: 0.7em', 'color: grey'])>
|
|
@foreach($direction->directionProfiles as $directionProfile)
|
|
{{ $directionProfile->name }} <br>
|
|
@endforeach
|
|
</p>
|
|
</td>
|
|
<td>{{ Str::words($direction->description, 10, '...') }}</td>
|
|
<td>{{ $direction->slug }}</td>
|
|
<td>{{ $direction->department->name }}</td>
|
|
<td>{{ $direction->educationLevel->name }}</td>
|
|
<td>
|
|
<a href="{{ route("directions.edit", $direction) }}"
|
|
class="btn btn-secondary">редактировать</a>
|
|
<a rel="nofollow" data-method="post"
|
|
href="{{ route('directions.duplication', $direction->id) }}"
|
|
class="btn btn-warning">Дублировать</a>
|
|
<a rel="nofollow" data-method="delete" data-confirm="Вы действительно хотите удалить?"
|
|
href="{{ route('directions.destroy', $direction) }}"
|
|
class="btn btn-danger">удалить</a>
|
|
</td>
|
|
</tr>
|
|
@endforeach
|
|
</tbody>
|
|
</table>
|
|
<br>
|
|
<br>
|
|
</div>
|
|
@endsection
|