Skip to content

Commit

Permalink
PR #3 SEO Expansion
Browse files Browse the repository at this point in the history
  • Loading branch information
ediazjz authored Aug 4, 2022
2 parents 8eefac6 + b477b02 commit 8af7a2e
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/api/collection/content-types/collection/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@
"relation": "manyToMany",
"target": "api::product.product",
"inversedBy": "collections"
},
"seoInformation": {
"type": "component",
"repeatable": false,
"component": "seo.seo",
"required": false
}
}
}
7 changes: 7 additions & 0 deletions src/api/product/content-types/product/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,13 @@
"relation": "manyToMany",
"target": "api::collection.collection",
"mappedBy": "products"
},
"seoInformation": {
"displayName": "SEO",
"type": "component",
"repeatable": false,
"component": "seo.seo",
"required": false
}
}
}
38 changes: 38 additions & 0 deletions src/components/seo/seo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"collectionName": "components_seo_seos",
"info": {
"displayName": "SEO",
"icon": "link",
"description": ""
},
"options": {},
"attributes": {
"title": {
"type": "string",
"required": true
},
"type": {
"type": "enumeration",
"enum": [
"product",
"product.group",
"article",
"website"
],
"required": true
},
"description": {
"type": "text",
"maxLength": 200,
"required": true
},
"image": {
"allowedTypes": [
"images"
],
"type": "media",
"multiple": true,
"required": true
}
}
}

0 comments on commit 8af7a2e

Please sign in to comment.