Hi guys,
I have a hook that updates relationship field between collections.
I got it working when editing in a collection document edit page.
On Lesson A edit page, I set Course relationship to Course A. It does work as intended, and shows up on Course A page.
However, when bulk editing on lessons list view, only one lesson gets added to target course.
Same issue with skill collection.
btw, I know hook for bidirectional relationships are not recommended, but I don't manage to make join+relation field work when querying on the front, and I'm ok with this hook solution, if I get it to work that is.
Code below.
If someone could help me, that'd be much much appreciated.
Sorry for 6 messages below, I don't know how to share code otherwise.