I am working on a custom module named "Amendments". I successfully write CRUD code of both "Categories" and "Amendments" models. I just can't figure out "How to establish a link between both entities".
What I'm trying to achieve is,
- How to store values in table "tnc_amendments_category_amendment"?
- Where can I specify association (in "AbstractModel", "AbstractDb" or in "AbstractCollection")?
- When I load any Category from the database, Category Object has an array of associated amendments and vice versa amendments has associated categories. something like given below image
I can't find any information related to Relationship on official documentation.