« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/data
diff options
context:
space:
mode:
Diffstat (limited to 'src/data')
-rw-r--r--src/data/things/group.js4
-rw-r--r--src/data/yaml.js2
2 files changed, 6 insertions, 0 deletions
diff --git a/src/data/things/group.js b/src/data/things/group.js
index 26fe9a55..111d6715 100644
--- a/src/data/things/group.js
+++ b/src/data/things/group.js
@@ -17,6 +17,8 @@ export class Group extends Thing {
 
     urls: Thing.common.urls(),
 
+    featuredAlbumsByRef: Thing.common.referenceList(Album),
+
     // Update only
 
     albumData: Thing.common.wikiData(Album),
@@ -24,6 +26,8 @@ export class Group extends Thing {
 
     // Expose only
 
+    featuredAlbums: Thing.common.dynamicThingsFromReferenceList('featuredAlbumsByRef', 'albumData', find.album),
+
     descriptionShort: {
       flags: {expose: true},
 
diff --git a/src/data/yaml.js b/src/data/yaml.js
index f967cee3..a5a0e798 100644
--- a/src/data/yaml.js
+++ b/src/data/yaml.js
@@ -356,6 +356,8 @@ export const processGroupDocument = makeProcessDocument(T.Group, {
     directory: 'Directory',
     description: 'Description',
     urls: 'URLs',
+
+    featuredAlbumsByRef: 'Featured Albums',
   },
 });