Skip to content

Commit a513fb0

Browse files
Merge pull request #696 from FitzwilliamMuseum/hotfix/exhibition-files
Introduce new related_documents field to directus for exhibition file…
2 parents 52d53d0 + d140ba6 commit a513fb0

File tree

2 files changed

+9
-13
lines changed

2 files changed

+9
-13
lines changed

resources/views/exhibitions/templates/details-2024.blade.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,9 @@
1717
<x-exhibition-cta :exhibition="$exhibition"></x-exhibition-cta>
1818

1919
@include('support.components.components-repeater', ['page' => $exhibition])
20-
{{-- {{ dd($exhibition) }} --}}
2120

22-
@if (!empty($exhibition['exhibition_files']))
23-
@include('includes.elements.exhibitions.files')
21+
@if (!empty($exhibition['related_documents']))
22+
@include('includes.elements.exhibitions.files', ['source' => $exhibition['related_documents']])
2423
@endif
2524

2625
@if($reposition_curators == false && (!empty($exhibition['associated_curators']) || !empty($exhibition['external_curators'])))
Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,8 @@
1-
@if (!empty($page_template))
2-
@if (!empty($exhibition['exhibition_files']))
3-
<x-exhibition-files :files="$exhibition['exhibition_files']"></x-exhibition-files>
4-
@endif
5-
@else
6-
@section('exhibitions-files')
7-
@if (!empty($exhibition['exhibition_files']))
8-
<x-exhibition-files :files="$exhibition['exhibition_files']"></x-exhibition-files>
9-
@endif
10-
@endsection
1+
@if(!isset($source))
2+
@php
3+
$source = $exhibition['exhibition_files']
4+
@endphp
5+
@endif
6+
@if(!empty($source))
7+
<x-exhibition-files :files="$source"></x-exhibition-files>
118
@endif

0 commit comments

Comments
 (0)