olach / kirby3-relationship

Sortable multiselect field for Kirby 3 CMS
MIT License
24 stars 0 forks source link

3.8 compatibility #15

Closed afbora closed 2 years ago

afbora commented 2 years ago

From @trych post https://github.com/getkirby/kirby/issues/4713#issuecomment-1270630451


The Kirby Relationship Field plugin does not show the already entered entries anymore. It does list entries, but those are empty.

In the content file, entries are still listed by their ids, so I assume that's the reason. If I add a new entry to the field that one is shown correctly.

Bildschirmfoto 2022-10-06 um 22 13 25

Bildschirmfoto 2022-10-06 um 22 16 48

trych commented 2 years ago

@afbora If I am not mistaken, this field is based on the multiselect field, so I guess the same mechanism could be used to correctly update those relationship fields that was also used by the kirby team to update existing multiselect fields.

olach commented 2 years ago

@trych I will look into this. Actually it is based on the tags field. Maybe I could change this so it extends the native multiselect field instead.

olach commented 2 years ago

I have updated this plugin to be compatible with Kirby 3.8.

This plugin extends the native Tags field (just as the native Multiselect field does). In Kirby 3.8, the loading and saving of the data had changed at the php level for the Tags field. This new version fixes this and restores the old behavior. It's still compatible with Kirby versions prior to 3.8.

trych commented 2 years ago

Hi @olach , unfortunately it seems not to have solved the issue with the blank fields when you upgrade a 3.7.5 project to 3.8. Any advice on how I could gracefully transition these fields?

Also, there seems to be a new issue related to this: https://github.com/olach/kirby3-relationship/issues/16