From 3a9688c510ca1d18221454a8cf7e2bbbb665dcd3 Mon Sep 17 00:00:00 2001 From: Nico Stapelbroek Date: Sat, 13 Jan 2018 16:01:58 +0100 Subject: [PATCH] Change navigation flow from incidents to incident updates page Clicking on the incident title will now navigate to the incident updates page rather than editing the incident. To prevent confusion I've also removed the "update" button from the incidents overview page and added the incident name to the page title of the incident updates page. --- resources/lang/en/dashboard.php | 2 +- resources/views/dashboard/incidents/index.blade.php | 3 +-- resources/views/dashboard/incidents/updates/index.blade.php | 4 ++-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/resources/lang/en/dashboard.php b/resources/lang/en/dashboard.php index ec84ef4a..3fde4675 100644 --- a/resources/lang/en/dashboard.php +++ b/resources/lang/en/dashboard.php @@ -22,7 +22,7 @@ return [ 'incident-create-template' => 'Create Template', 'incident-templates' => 'Incident Templates', 'updates' => [ - 'title' => 'Incident updates', + 'title' => 'Incident updates for :incident', 'count' => '{0} Zero Updates|[1] One Update|[2] Two Updates|[3,Inf] Several Updates', ], 'add' => [ diff --git a/resources/views/dashboard/incidents/index.blade.php b/resources/views/dashboard/incidents/index.blade.php index 70a7bb81..c11bdab9 100644 --- a/resources/views/dashboard/incidents/index.blade.php +++ b/resources/views/dashboard/incidents/index.blade.php @@ -22,14 +22,13 @@ @foreach($incidents as $incident)
- {{ $incident->name }} {{ trans_choice('dashboard.incidents.updates.count', $incident->updates()->count()) }} + {{ $incident->name }} {{ trans_choice('dashboard.incidents.updates.count', $incident->updates()->count()) }} @if($incident->message)

{{ Str::words($incident->message, 5) }}

@endif
diff --git a/resources/views/dashboard/incidents/updates/index.blade.php b/resources/views/dashboard/incidents/updates/index.blade.php index 392dd759..b7f8d6fb 100644 --- a/resources/views/dashboard/incidents/updates/index.blade.php +++ b/resources/views/dashboard/incidents/updates/index.blade.php @@ -6,9 +6,9 @@
- {{ trans('dashboard.incidents.updates.title') }} + {{ trans('dashboard.incidents.updates.title', ['incident' => Str::words($incident->name, 5)]) }} - + {{ trans('dashboard.incidents.update.title') }}