Add gallery page
This commit is contained in:
parent
39466006da
commit
f0f2633919
2 changed files with 35 additions and 0 deletions
15
site/controllers/gallery.php
Normal file
15
site/controllers/gallery.php
Normal file
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
return function ($pages, $page) {
|
||||
|
||||
// Get exhibition page object
|
||||
$exhibitionsPage = $pages->template('exhibitions')->first();
|
||||
|
||||
// Get artworks files section content
|
||||
$artworks = $page->files()->template("artwork")->sortBy('sort');
|
||||
|
||||
return [
|
||||
'exhibitionsPage' => $exhibitionsPage,
|
||||
'artworks' => $artworks
|
||||
];
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue