Added Rein costumes models

This commit is contained in:
DrMint 2023-02-18 09:26:55 +01:00
parent b9cf26021a
commit 74ce2e6236
8 changed files with 113 additions and 1 deletions

View File

@ -0,0 +1,35 @@
{
"kind": "collectionType",
"collectionName": "rein_costumes",
"info": {
"singularName": "rein-costume",
"pluralName": "rein-costumes",
"displayName": "⬜ Re[in] Costumes",
"description": ""
},
"options": {
"draftAndPublish": false
},
"attributes": {
"slug": {
"type": "string",
"required": true,
"unique": true,
"regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
},
"thumbnail": {
"type": "media",
"multiple": true,
"required": false,
"allowedTypes": [
"images"
]
},
"translations": {
"displayName": "Rein Costumes",
"type": "component",
"repeatable": true,
"component": "translations.rein-costumes"
}
}
}

View File

@ -0,0 +1,9 @@
'use strict';
/**
* rein-costume controller
*/
const { createCoreController } = require('@strapi/strapi').factories;
module.exports = createCoreController('api::rein-costume.rein-costume');

View File

@ -0,0 +1,9 @@
'use strict';
/**
* rein-costume router
*/
const { createCoreRouter } = require('@strapi/strapi').factories;
module.exports = createCoreRouter('api::rein-costume.rein-costume');

View File

@ -0,0 +1,9 @@
'use strict';
/**
* rein-costume service
*/
const { createCoreService } = require('@strapi/strapi').factories;
module.exports = createCoreService('api::rein-costume.rein-costume');

View File

@ -23,6 +23,18 @@
"required": true, "required": true,
"unique": true, "unique": true,
"regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$" "regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
},
"subgroups": {
"type": "relation",
"relation": "oneToMany",
"target": "api::weapon-story-group.weapon-story-group",
"mappedBy": "subgroup_of"
},
"subgroup_of": {
"type": "relation",
"relation": "manyToOne",
"target": "api::weapon-story-group.weapon-story-group",
"inversedBy": "subgroups"
} }
} }
} }

View File

@ -20,7 +20,7 @@
}, },
"slug": { "slug": {
"type": "string", "type": "string",
"required": false, "required": true,
"unique": true, "unique": true,
"regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$" "regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
}, },

View File

@ -543,6 +543,21 @@
}, },
"variant_of_x": { "variant_of_x": {
"type": "string" "type": "string"
},
"dark_mode_extension_warning": {
"type": "text"
},
"weapon": {
"type": "string"
},
"weapons_description": {
"type": "string"
},
"story_x": {
"type": "string"
},
"level_x": {
"type": "string"
} }
} }
} }

View File

@ -0,0 +1,23 @@
{
"collectionName": "components_translations_rein_costumes",
"info": {
"displayName": "Rein Costumes",
"description": ""
},
"options": {},
"attributes": {
"language": {
"type": "relation",
"relation": "oneToOne",
"target": "api::language.language"
},
"name": {
"type": "string",
"required": true
},
"description": {
"type": "text",
"required": true
}
}
}