ldc-supportweb/resources/views/bo/pages/sites/show.blade.php
2025-04-17 16:22:23 +02:00

104 lines
4.8 KiB
PHP

@extends('layout.app', ['brParam' => $siteModel])
@section('title', __('Aperçu d\'un :model', ['model' => Str::singular(__('models.classes.sites'))]))
@section('description', __('Aperçu d\'un :model déjà existant', ['model' => Str::singular(__('models.classes.sites'))]))
@section('breadcrumb', request()->route()->getName())
@section('content')
<div class="d-flex justify-content-between flex-wrap flex-md-nowrap align-items-center pb-3">
<div class="d-flex flex-row align-items-start">
<a href="{{ route('bo.sites.index') }}"
class="btn btn-primary text-decoration-none m-0 me-2"
data-bs-toggle="tooltip"
data-bs-placement="top"
title="{{ __('crud.helpers.list_all', ['model' => __('models.classes.sites')]) }}">
<i class="fa-solid fa-arrow-left"></i>
</a>
@include('breadcrumbs.breadcrumb-body', ['brParam' => $siteModel])
</div>
<div class="mb-2 mb-md-0">
<form action="{{ route('bo.sites.destroy', $siteModel->id) }}"
method="POST"
class="confirmDeleteTS">
@csrf
@method('DELETE')
<div class="btn-group" role="group">
<a class="btn btn-primary"
href="{{ route('bo.sites.edit', ['site' => $siteModel->id]) }}"
data-bs-toggle="tooltip"
data-bs-placement="top"
title="{{ __('crud.helpers.update_model', ['model' => Str::singular(__('models.classes.sites'))]) }}">
<i class="fa-solid fa-pencil"></i>
</a>
<button type="submit"
class="btn btn-danger"
data-bs-toggle="tooltip"
data-bs-placement="top"
title="{{ __('crud.helpers.delete_model', ['model' => Str::singular(__('models.classes.sites'))]) }}">
<i class="fa-solid fa-trash"></i>
</button>
</div>
</form>
</div>
</div>
<table class="table table-hover table-borderless">
<tbody>
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ Str::ucfirst(__('validation.attributes.name')) }}</td>
<td class="text-center align-middle">{{ $siteModel->name }}</td>
</tr>
@if ($siteModel->brand)
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ Str::ucfirst(__('validation.attributes.brandname')) }}</td>
<td class="text-center align-middle">{{ $siteModel->brand->name }}</td>
</tr>
@endif
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ Str::ucfirst(__('models.classes.users')) }}</td>
<td class="text-center align-middle">
@foreach ($siteModel->users as $user)
{{ $user->name }}@if (!$loop->last), @endif
@endforeach
</td>
</tr>
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ Str::ucfirst(__('validation.attributes.url_re7')) }}</td>
<td class="text-center align-middle">
@if ($siteModel->url_re7)
<a href="{{ $siteModel->url_re7 }}" target="_blank">{{ $siteModel->url_re7 }}</a>
@else
-
@endif
</td>
</tr>
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ Str::ucfirst(__('validation.attributes.url_prod')) }}</td>
<td class="text-center align-middle">
@if ($siteModel->url_prod)
<a href="{{ $siteModel->url_prod }}" target="_blank">{{ $siteModel->url_prod }}</a>
@else
-
@endif
</td>
</tr>
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ __("Chef de projet") }}</td>
<td class="text-center align-middle">
@if ($siteModel->project_manager_id)
{{ $siteModel->projectManager->name }}
@else
-
@endif
</td>
</tr>
<tr class="list-item border-bottom">
<td class="text-center align-middle">{{ Str::ucfirst(__('validation.attributes.created_at')) }}</td>
<td class="text-center align-middle"><span class="badge bg-info">{{ $siteModel->created_at }}</span></td>
</tr>
<tr class="list-item">
<td class="text-center align-middle">{{ Str::ucfirst(__('validation.attributes.updated_at')) }}</td>
<td class="text-center align-middle"><span class="badge bg-info">{{ $siteModel->updated_at }}</span></td>
</tr>
</tbody>
</table>
@endsection