Feature: 添加Content类型

This commit is contained in:
2025-08-26 07:15:50 +00:00
parent 644c533201
commit 464b5174ca
28 changed files with 1677 additions and 0 deletions

View File

@ -0,0 +1,27 @@
{
"kind": "singleType",
"collectionName": "company_profiles",
"info": {
"singularName": "company-profile",
"pluralName": "company-profiles",
"displayName": "CompanyProfile"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {
"i18n": {
"localized": true
}
},
"attributes": {
"content": {
"type": "richtext",
"pluginOptions": {
"i18n": {
"localized": true
}
}
}
}
}

View File

@ -0,0 +1,7 @@
/**
* company-profile controller
*/
import { factories } from '@strapi/strapi'
export default factories.createCoreController('api::company-profile.company-profile');

View File

@ -0,0 +1,7 @@
/**
* company-profile router
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreRouter('api::company-profile.company-profile');

View File

@ -0,0 +1,7 @@
/**
* company-profile service
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreService('api::company-profile.company-profile');

View File

@ -0,0 +1,27 @@
{
"kind": "singleType",
"collectionName": "contact_infos",
"info": {
"singularName": "contact-info",
"pluralName": "contact-infos",
"displayName": "ContactInfo"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {
"i18n": {
"localized": true
}
},
"attributes": {
"content": {
"type": "richtext",
"pluginOptions": {
"i18n": {
"localized": true
}
}
}
}
}

View File

@ -0,0 +1,7 @@
/**
* contact-info controller
*/
import { factories } from '@strapi/strapi'
export default factories.createCoreController('api::contact-info.contact-info');

View File

@ -0,0 +1,7 @@
/**
* contact-info router
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreRouter('api::contact-info.contact-info');

View File

@ -0,0 +1,7 @@
/**
* contact-info service
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreService('api::contact-info.contact-info');

View File

@ -0,0 +1,28 @@
{
"kind": "collectionType",
"collectionName": "production_types",
"info": {
"singularName": "production-type",
"pluralName": "production-types",
"displayName": "Production Type"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {
"i18n": {
"localized": true
}
},
"attributes": {
"type": {
"type": "string",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"required": true
}
}
}

View File

@ -0,0 +1,7 @@
/**
* production-type controller
*/
import { factories } from '@strapi/strapi'
export default factories.createCoreController('api::production-type.production-type');

View File

@ -0,0 +1,7 @@
/**
* production-type router
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreRouter('api::production-type.production-type');

View File

@ -0,0 +1,7 @@
/**
* production-type service
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreService('api::production-type.production-type');

View File

@ -0,0 +1,108 @@
{
"kind": "collectionType",
"collectionName": "productions",
"info": {
"singularName": "production",
"pluralName": "productions",
"displayName": "Production"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {
"i18n": {
"localized": true
}
},
"attributes": {
"title": {
"type": "string",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"required": true
},
"summary": {
"type": "string",
"pluginOptions": {
"i18n": {
"localized": true
}
}
},
"production_type": {
"type": "relation",
"relation": "oneToOne",
"target": "api::production-type.production-type"
},
"cover": {
"type": "media",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"multiple": false,
"allowedTypes": [
"images"
]
},
"production_images": {
"type": "media",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"multiple": true,
"allowedTypes": [
"images"
]
},
"production_details": {
"type": "richtext",
"pluginOptions": {
"i18n": {
"localized": true
}
}
},
"production_specs": {
"type": "dynamiczone",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"components": [
"production.spec-group"
]
},
"documents": {
"type": "media",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"multiple": true,
"allowedTypes": [
"images",
"files",
"videos",
"audios"
]
},
"show_in_production_list": {
"type": "boolean",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"default": true
}
}
}

View File

@ -0,0 +1,7 @@
/**
* production controller
*/
import { factories } from '@strapi/strapi'
export default factories.createCoreController('api::production.production');

View File

@ -0,0 +1,7 @@
/**
* production router
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreRouter('api::production.production');

View File

@ -0,0 +1,7 @@
/**
* production service
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreService('api::production.production');

View File

@ -0,0 +1,28 @@
{
"kind": "collectionType",
"collectionName": "solution_types",
"info": {
"singularName": "solution-type",
"pluralName": "solution-types",
"displayName": "Solution Type"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {
"i18n": {
"localized": true
}
},
"attributes": {
"type": {
"type": "string",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"required": true
}
}
}

View File

@ -0,0 +1,7 @@
/**
* solution-type controller
*/
import { factories } from '@strapi/strapi'
export default factories.createCoreController('api::solution-type.solution-type');

View File

@ -0,0 +1,7 @@
/**
* solution-type router
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreRouter('api::solution-type.solution-type');

View File

@ -0,0 +1,7 @@
/**
* solution-type service
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreService('api::solution-type.solution-type');

View File

@ -0,0 +1,61 @@
{
"kind": "collectionType",
"collectionName": "solutions",
"info": {
"singularName": "solution",
"pluralName": "solutions",
"displayName": "Solution"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {
"i18n": {
"localized": true
}
},
"attributes": {
"title": {
"type": "string",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"required": true
},
"summary": {
"type": "string",
"pluginOptions": {
"i18n": {
"localized": true
}
}
},
"cover": {
"type": "media",
"pluginOptions": {
"i18n": {
"localized": true
}
},
"multiple": false,
"allowedTypes": [
"images"
]
},
"solution_type": {
"type": "relation",
"relation": "oneToOne",
"target": "api::solution-type.solution-type"
},
"content": {
"type": "richtext",
"pluginOptions": {
"i18n": {
"localized": true
}
}
}
}
}

View File

@ -0,0 +1,7 @@
/**
* solution controller
*/
import { factories } from '@strapi/strapi'
export default factories.createCoreController('api::solution.solution');

View File

@ -0,0 +1,7 @@
/**
* solution router
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreRouter('api::solution.solution');

View File

@ -0,0 +1,7 @@
/**
* solution service
*/
import { factories } from '@strapi/strapi';
export default factories.createCoreService('api::solution.solution');