I’d like to create a recommended product feature on an app I’m working on and I’ve found a few articles about this topic but something is messed up and when I try to create a recommended product it only partially works.
In my DB I see that it successfully create a new row but only saves the product_id and the recommended_id is empty.
Here are some snippets of my code which I think is relevant to this topic. Let me know if you need more.
Any idea what might be the problem?