106 lines
3.3 KiB
PHP
106 lines
3.3 KiB
PHP
@extends('layout.app')
|
|
|
|
|
|
|
|
@section('content')
|
|
<div id="planning" class="container container-xxl vueComponent">
|
|
<div class="row mb-3 sticky-top bg-white">
|
|
<div class="col-2">
|
|
<h1><a href="{{ route('schedule.index') }}">{{__('Planning') }}</a></h1>
|
|
</div>
|
|
<div class="col pt-2">
|
|
<h4 class="d-inline me-3">Légende</h4>
|
|
<div class="d-inline">
|
|
@foreach(CellType::toArray() as $type)
|
|
<span style="background-color: {{ $type->value }}; border: 1px solid black;">{{ $type->label }}</span>
|
|
@endforeach
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<schedule-component
|
|
browse-date='@json($date)'
|
|
db-schedules='@json($arSchedules)'
|
|
db-activities='@json(ActivityType::toArray())'
|
|
db-models='@json(CellModel::toArray())'
|
|
db-users='@json($users)'
|
|
weeks='@json($weekCells)'
|
|
v-bind:show-weekends='false'></schedule-component>
|
|
</div>
|
|
@endsection
|
|
|
|
@push('scriptsConstants')
|
|
<script>
|
|
window._routes = {
|
|
"schedule.index": "{{ route('schedule.index') }}",
|
|
|
|
"ticket.show": "{{ route('ticket.show', 'TICKET') }}",
|
|
"projects.show": "{{ route('projects.show', 'PROJECT') }}",
|
|
"sites.show": "{{ route('sites.show', 'SITE') }}",
|
|
"ticket.index": "{{ route('ticket.index') }}",
|
|
"projects.index": "{{ route('projects.index') }}",
|
|
"sites.index": "{{ route('sites.index') }}",
|
|
"planning.setCellContent": "{{ route('planning.setCellContent') }}",
|
|
"planning.eraseCellContent": "{{ route('planning.eraseCellContent') }}"
|
|
};
|
|
</script>
|
|
@endpush
|
|
|
|
@push('customCss')
|
|
<style>
|
|
{{--
|
|
.grid-1week {
|
|
display: grid;
|
|
grid-template-columns: 2fr repeat(5, 1fr);
|
|
grid-auto-rows: minmax(50px, auto);
|
|
}
|
|
.grid-2week {
|
|
display: grid;
|
|
grid-template-columns: 2fr repeat(10, 1fr);
|
|
grid-auto-rows: minmax(50px, auto);
|
|
align-items: center;
|
|
}
|
|
.grid-week div {
|
|
border-width:0 1px 1px 0;
|
|
border-style: solid;
|
|
border-color: var(--bs-cyan);
|
|
display: flex;
|
|
justify-content: center;
|
|
align-self: stretch;
|
|
align-items: center;
|
|
}
|
|
.grid-week div.Sat, .grid-week div.Sun {
|
|
//width: 0px;
|
|
}
|
|
.empty {
|
|
grid-column: auto;
|
|
grid-row: auto /span 2;
|
|
}
|
|
.week {
|
|
grid-column: auto /span 5;
|
|
grid-row: auto;
|
|
}
|
|
.name {
|
|
grid-column: auto;
|
|
grid-row: auto /span 4;
|
|
}
|
|
--}}
|
|
.support {
|
|
background-color: {{CellType::support()->value}} !important;
|
|
}
|
|
.rnd {
|
|
background-color: {{CellType::rnd()->value}} !important;
|
|
}
|
|
.dev {
|
|
background-color: {{CellType::dev()->value}} !important;
|
|
}
|
|
.projects {
|
|
background-color: {{CellType::projects()->value}} !important;
|
|
}
|
|
.management {
|
|
background-color: {{CellType::management()->value}} !important;
|
|
}
|
|
.absence, .Sat, .Sun {
|
|
background-color: {{CellType::absence()->value}} !important;
|
|
}
|
|
</style>
|
|
@endpush
|