@php $editId = (int) request('edit'); $row = $editId ? $testimonials->firstWhere('id', $editId) : null; $open = $row || request()->has('new') || $errors->any(); $live = $testimonials->where('published', true)->count(); @endphp
Only publish real feedback. Add a testimonial only when the learner has agreed to be quoted by name. Do not invent or edit quotes. Published testimonials appear on the home page, at most three at a time, in the order below.
@if($open)
@csrf

{{ $row ? 'Edit testimonial' : 'New testimonial' }}

Cancel
The learner's own words, as they gave them.
@error('quote')
{{ $message }}
@enderror
Optional. Square JPG, PNG or WebP up to 2 MB{{ $row?->photo_path ? '. Choose a file to replace the current photo.' : '.' }}
@error('photo')
{{ $message }}
@enderror
@endif

Testimonials

{{ $testimonials->count() }} total · {{ $live }} published
@unless($open) New testimonial@endunless
@if($testimonials->isEmpty()) Add a testimonial @else
@foreach($testimonials as $t) @php $course = $courses->firstWhere('id', $t->course_id); @endphp @endforeach
LearnerQuoteCourseOrderStatusActions
{{ $t->name }}{{ collect([$t->role, $t->company])->filter()->implode(' · ') ?: 'No job title' }} {{ \Illuminate\Support\Str::limit($t->quote, 110) }} {{ $course?->title ?: '—' }} {{ $t->sort_order }}
@csrf
@csrf @method('DELETE')
@endif