ideas icon indicating copy to clipboard operation
ideas copied to clipboard

Inverse relations

Open repomaa opened this issue 4 years ago • 2 comments

When adding a field of type entries, add an "inverse of" option. Whenever an entry is linked with the entries field, check if the "inverse of" option is not null and if not, add the uuid of the linking entry to the linked entry also. This might help fixing https://github.com/statamic/cms/issues/1820

repomaa avatar May 12 '20 10:05 repomaa

Thats exactly what we think about atm.

LEts say we have persons and groups, then i want to assign groups while editing a person and persons while editing a group in cp. And in the frontened i want to display the goups of a person on his page, and the persons bwlonging to a gruop on the grouppage...

mmodler avatar Sep 23 '20 08:09 mmodler

I'm not sure if I'm looking for the same thing as the OP but inverse relations would definitely be useful and I'm surprised that they are not available already, being that relationships are such a big part of Laravel.

This works great for my current needs though: https://github.com/Stillat/relationships

stuartcusackie avatar May 30 '22 14:05 stuartcusackie