Give this a shot:
has_many :jobs, foreign_key: 'user_id', class_name: 'Task'
Note, that :as
is used for polymorphic associations.
Also, foreign_key option for has_many.
Give this a shot:
has_many :jobs, foreign_key: 'user_id', class_name: 'Task'
Note, that :as
is used for polymorphic associations.
Also, foreign_key option for has_many.