Skip to content

Commit 8913a7c

Browse files
authored
Merge pull request #456 from FitzwilliamMuseum/issue455
Flatten curatorial departments this closes #455 Solr update applied - delete all original entries, then run php artisan tinker to update with new data Staff reassigned to collections and research division
2 parents 9abc170 + 9635376 commit 8913a7c

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

app/Http/Controllers/departmentsController.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,10 @@ public function index(): View
3737
public function details(string $slug): View|Response
3838
{
3939
$departments = Departments::find($slug);
40-
$staff = StaffProfiles::findByDepartment($departments['data'][0]['id']);
4140
if (empty($departments['data'])) {
4241
return response()->view('errors.404', [], 404);
42+
} else {
43+
$staff = StaffProfiles::findByDepartment($departments['data'][0]['id']);
4344
}
4445
return view('departments.details', compact('departments', 'staff'));
4546
}

config/missing-page-redirector.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -472,7 +472,14 @@
472472
# feeds
473473
'/news/feed/' => '/feeds/news/',
474474
# podcasts
475-
'/conversations/podcasts/episode' => '/conversations/podcasts/'
475+
'/conversations/podcasts/episode' => '/conversations/podcasts/',
476+
# Department changes July 2022
477+
'about-us/departments/antiquities' => '/about-us/departments/collections-and-research',
478+
'about-us/departments/applied-arts' => '/about-us/departments/collections-and-research',
479+
'about-us/departments/coins-and-medals' => '/about-us/departments/collections-and-research',
480+
'about-us/departments/manuscripts-and-printed-books' => '/about-us/departments/collections-and-research',
481+
'about-us/departments/paintings-drawings-and-prints' => '/about-us/departments/collections-and-research',
482+
'about-us/departments/research' => '/about-us/departments/collections-and-research',
476483
],
477484

478485
];

0 commit comments

Comments
 (0)