@extends('layouts.app') @section('title', 'Training') @section('title-flex')
@if($activity->type == "STATUS") @if(($activity->new_data == -2 || $activity->new_data == -4) && isset($activity->comment)) Status changed from {{ \App\Http\Controllers\TrainingController::$statuses[$activity->old_data]["text"] }} to {{ \App\Http\Controllers\TrainingController::$statuses[$activity->new_data]["text"] }} with reason {{ $activity->comment }} @else Status changed from {{ \App\Http\Controllers\TrainingController::$statuses[$activity->old_data]["text"] }} to {{ \App\Http\Controllers\TrainingController::$statuses[$activity->new_data]["text"] }} @endif @elseif($activity->type == "TYPE") Training type changed from {{ \App\Http\Controllers\TrainingController::$types[$activity->old_data]["text"] }} to {{ \App\Http\Controllers\TrainingController::$types[$activity->new_data]["text"] }} @elseif($activity->type == "MENTOR") @if($activity->new_data) {{ \App\Models\User::find($activity->new_data)->name }} assigned as mentor @elseif($activity->old_data) {{ \App\Models\User::find($activity->old_data)->name }} removed as mentor @endif @elseif($activity->type == "PAUSE") @if($activity->new_data) Training paused @else Training unpaused @endif @elseif($activity->type == "ENDORSEMENT") @if(\App\Models\Endorsement::find($activity->new_data) !== null) @empty($activity->comment) {{ str(\App\Models\Endorsement::find($activity->new_data)->type)->lower()->ucfirst() }} endorsement granted, valid to @isset(\App\Models\Endorsement::find($activity->new_data)->valid_to) {{ \App\Models\Endorsement::find($activity->new_data)->valid_to->toEuropeanDateTime() }} @else Forever @endisset @else {{ str(\App\Models\Endorsement::find($activity->new_data)->type)->lower()->ucfirst() }} endorsement granted, valid to @isset(\App\Models\Endorsement::find($activity->new_data)->valid_to) {{ \App\Models\Endorsement::find($activity->new_data)->valid_to->toEuropeanDateTime() }} @else Forever @endisset for positions: @foreach(explode(',', $activity->comment) as $p) {{ $p }} @endforeach @endempty @endif @elseif($activity->type == "COMMENT") {!! nl2br($activity->comment) !!} @if($activity->created_at != $activity->updated_at) (edited) @endif @endif
Training created
Letter of motivation
@if(empty($training->motivation))Not provided / relevant
@else{{ $training->motivation }}
@endifAreas to improve
No confirmation history
@elseInterest sent | Confirmation Deadline | Interest confirmed |
---|---|---|
{{ $interest->created_at->toEuropeanDate() }} | {{ $interest->deadline->toEuropeanDate() }} | @if($interest->confirmed_at) {{ $interest->confirmed_at->toEuropeanDate() }} @elseif($interest->expired) @if($interest->expired == 1) Invalidated @else Not confirmed @endif @else Awaiting confirmation @endif |