applicant-site/resources/views/admin/catalog/direction/cost/index.blade.php

46 lines
2.1 KiB
PHP

@extends('layouts.admin_layout')
@section('content')
<div class="container">
<h2>Стоимость</h2>
<br>
<a href="{{ route('costs.create') }}" class="btn btn-primary">Создать Стоимость</a>
<br>
<br>
<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">направление</th>
<th scope="col">Стоимость</th>
<th scope="col">действия</th>
<th scope="col"></th>
</tr>
</thead>
<tbody>
@foreach($costs as $cost)
<tr class="">
<td>{{ $cost->position }}</td>
<td>{{ Str::words($cost->description, 10, '...') }}</td>
<td><a href="{{ route('education_forms.show', $cost->educationForm) }}">{{ $cost->educationForm->name }}</a></td>
<td><a href="{{ route('directions.show', $cost->direction) }}">{{ $cost->direction->name }}</a></td>
<td>{{ $cost->cost }}</td>
<td>
<a href="{{ route("costs.show", $cost) }}"
class="btn btn-info">посмотреть</a>
<a href="{{ route("costs.edit", $cost) }}"
class="btn btn-secondary">редактировать</a>
<a rel="nofollow" data-method="delete" data-confirm="Вы действительно хотите удалить?"
href="{{ route('costs.destroy', $cost) }}"
class="btn btn-danger">удалить</a>
</td>
</tr>
@endforeach
</tbody>
</table>
<br>
<br>
</div>
@endsection