This question regards the following warning:
warning: Please define the following association(s) in the schema for App.Context1.User: belongs_to :invited_by, App.Context1.User has_many :invited_users, App.Context1.User, [foreign_key: :invited_by_id]
It completely messes up the way I thought of contexts. I was under the impression that we are supposed to reuse certain fields in certain contexts. And other fields of the same database table in other contexts. Is that wrong?
Let me give you an example:
Why would my login context (passwords, invited_by, …) want anything to do with payment details or vice versa? Those are two different types of users in my understanding and therefore belong in different contexts.
By the way, this warning is being followed by another warning telling me to add some fields to the
App.Context1.User which just don’t belong there.
Please help me understand this or let’s get rid of the warning.