This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.
I'm showing a hasMany partial but need to configure what is shown. It seems that the default options for hasMany (showing a management popup when clicking, showing delete button, showing checkboxes) can't be overwritten using the documented available options (https://github.com/octobercms/docs/blob/master/backend-relations.md#configuring-the-relation-behavior).
Is it possible to show a list from a hasMany relationship and remove the delete button (by using a custom toolBarbuttons partial file, set the text on the create button, remove checkboxes and overwrite the link?
Seems strange to have these options but not be able to use them? Unless I'm doing something spectacularly wrong.
In below example the search is showing, but the custom toolbar partial isn't showing, url isn't working and checkboxes are showing.
label: Offers
list: @/plugins/foo/bar/models/offer/columns_for_property.yaml
form: @/plugins/foo/bar/models/offer/fields.yaml
view:
recordUrl: /foo/bar/offers/update/:id
toolbarButtons: @/plugins/foo/bar/controller/offer/_relation_toolbar.htm
showSearch: true
showCheckboxes: false
Last updated
Is the hasMany relationship working? I want to show a list of the related items in my form. My primary form.yaml has a field with type: relationship but I get the following error:
The partial '/www/modules/backend/Widgets/form/partials/_field_relationship.htm' is not found. I'm running build 183 of Octobercms
chad said:
Is the hasMany relationship working? I want to show a list of the related items in my form. My primary form.yaml has a field with type: relationship but I get the following error:
The partial '/www/modules/backend/Widgets/form/partials/_field_relationship.htm' is not found. I'm running build 183 of Octobercms
Any idea how to fix this?
Thank you
1-7 of 7