Skip to content

Commit

Permalink
update page, resource and button (#2413)
Browse files Browse the repository at this point in the history
  • Loading branch information
Datayama38 authored Feb 14, 2024
1 parent 3c4101f commit ac4ae01
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 11 deletions.
7 changes: 5 additions & 2 deletions cms/src/api/page/content-types/page/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,14 @@
"page.list-title"
]
},
"resource": {
"resources": {
"type": "relation",
"relation": "manyToOne",
"relation": "manyToMany",
"target": "api::resource.resource",
"inversedBy": "pages"
},
"complement": {
"type": "richtext"
}
}
}
12 changes: 6 additions & 6 deletions cms/src/api/resource/content-types/resource/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,6 @@
"type": "date",
"required": true
},
"pages": {
"type": "relation",
"relation": "oneToMany",
"target": "api::page.page",
"mappedBy": "resource"
},
"slug": {
"type": "uid",
"targetField": "title"
Expand Down Expand Up @@ -57,6 +51,12 @@
],
"type": "media",
"multiple": false
},
"pages": {
"type": "relation",
"relation": "manyToMany",
"target": "api::page.page",
"mappedBy": "resources"
}
}
}
7 changes: 4 additions & 3 deletions cms/src/components/shared/button.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@
"color": {
"type": "enumeration",
"enum": [
"bleu",
"blanc"
"primary",
"secondary"
],
"required": true
"required": true,
"default": "primary"
}
}
}

0 comments on commit ac4ae01

Please sign in to comment.