Added more types for library item + thumbs for content
This commit is contained in:
parent
db7d5ff083
commit
1b2422bd9b
|
@ -57,6 +57,13 @@
|
|||
"type": "component",
|
||||
"repeatable": true,
|
||||
"component": "sets.audio-set"
|
||||
},
|
||||
"thumbnail": {
|
||||
"allowedTypes": [
|
||||
"images"
|
||||
],
|
||||
"type": "media",
|
||||
"multiple": false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -74,7 +74,9 @@
|
|||
"metadata.books",
|
||||
"metadata.video",
|
||||
"metadata.game",
|
||||
"metadata.audio"
|
||||
"metadata.audio",
|
||||
"metadata.merch",
|
||||
"metadata.other"
|
||||
],
|
||||
"max": 1
|
||||
},
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
"kind": "collectionType",
|
||||
"collectionName": "merch_items",
|
||||
"info": {
|
||||
"singularName": "merch-item",
|
||||
"pluralName": "merch-items",
|
||||
"displayName": "Merch Items"
|
||||
},
|
||||
"options": {
|
||||
"draftAndPublish": false
|
||||
},
|
||||
"attributes": {
|
||||
"slug": {
|
||||
"type": "string",
|
||||
"required": true,
|
||||
"unique": true,
|
||||
"regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
'use strict';
|
||||
|
||||
/**
|
||||
* merch-item controller
|
||||
*/
|
||||
|
||||
const { createCoreController } = require('@strapi/strapi').factories;
|
||||
|
||||
module.exports = createCoreController('api::merch-item.merch-item');
|
|
@ -0,0 +1,9 @@
|
|||
'use strict';
|
||||
|
||||
/**
|
||||
* merch-item router.
|
||||
*/
|
||||
|
||||
const { createCoreRouter } = require('@strapi/strapi').factories;
|
||||
|
||||
module.exports = createCoreRouter('api::merch-item.merch-item');
|
|
@ -0,0 +1,9 @@
|
|||
'use strict';
|
||||
|
||||
/**
|
||||
* merch-item service.
|
||||
*/
|
||||
|
||||
const { createCoreService } = require('@strapi/strapi').factories;
|
||||
|
||||
module.exports = createCoreService('api::merch-item.merch-item');
|
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
"kind": "collectionType",
|
||||
"collectionName": "other_subtypes",
|
||||
"info": {
|
||||
"singularName": "other-subtype",
|
||||
"pluralName": "other-subtypes",
|
||||
"displayName": "Other Subtypes",
|
||||
"description": ""
|
||||
},
|
||||
"options": {
|
||||
"draftAndPublish": false
|
||||
},
|
||||
"attributes": {
|
||||
"slug": {
|
||||
"type": "string",
|
||||
"required": true,
|
||||
"unique": true,
|
||||
"regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
'use strict';
|
||||
|
||||
/**
|
||||
* other-subtype controller
|
||||
*/
|
||||
|
||||
const { createCoreController } = require('@strapi/strapi').factories;
|
||||
|
||||
module.exports = createCoreController('api::other-subtype.other-subtype');
|
|
@ -0,0 +1,9 @@
|
|||
'use strict';
|
||||
|
||||
/**
|
||||
* other-subtype router.
|
||||
*/
|
||||
|
||||
const { createCoreRouter } = require('@strapi/strapi').factories;
|
||||
|
||||
module.exports = createCoreRouter('api::other-subtype.other-subtype');
|
|
@ -0,0 +1,9 @@
|
|||
'use strict';
|
||||
|
||||
/**
|
||||
* other-subtype service.
|
||||
*/
|
||||
|
||||
const { createCoreService } = require('@strapi/strapi').factories;
|
||||
|
||||
module.exports = createCoreService('api::other-subtype.other-subtype');
|
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
"collectionName": "components_metadata_merches",
|
||||
"info": {
|
||||
"displayName": "Merch",
|
||||
"icon": "gift"
|
||||
},
|
||||
"options": {},
|
||||
"attributes": {
|
||||
"merch_item": {
|
||||
"type": "relation",
|
||||
"relation": "oneToOne",
|
||||
"target": "api::merch-item.merch-item"
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"collectionName": "components_metadata_others",
|
||||
"info": {
|
||||
"displayName": "Other",
|
||||
"icon": "apple-alt",
|
||||
"description": ""
|
||||
},
|
||||
"options": {},
|
||||
"attributes": {
|
||||
"subtype": {
|
||||
"type": "relation",
|
||||
"relation": "oneToOne",
|
||||
"target": "api::other-subtype.other-subtype"
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue