when providing a folder called meeting in /api containing the 4 created folders including content-types/meeting/schema.json
{
"kind": "collectionType",
"collectionName": "meetings",
"info": {
"singularName": "meeting",
"pluralName": "meetings",
"displayName": "Meeting",
"description": ""
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {},
"attributes": {
"Start": {
"type": "datetime"
},
"End": {
"type": "datetime"
},
"user": {
"type": "relation",
"relation": "manyToOne",
"target": "plugin::users-permissions.user",
"inversedBy": "meetings"
},
"title": {
"type": "string"
},
"description": {
"type": "text"
}
}
}
the inversedBy attribute is resulting in an error:
Error: Error on attribute users_permissions_user in model meeting(api::meeting.meeting): inversedBy attribute meetings not found target plugin::users-permissions.user
when done via UI, it works. It seems I need to manually add the meetings key to the user-permissions.user object.
(that cant be correct
)
current workaround is to remove the inversedBy attribute and set the relation to oneToOne
→ then change it in UI ![]()
Any help would be amazing ![]()
This topic has been created from a Discord post (1238671188314689628) to give it more visibility.
It will be on Read-Only mode here.
Join the conversation on Discord