You are viewing the old version (0.13) of the documentation.
Starting with Phoenix 0.16 This should be:
mix phoenix.gen.model Video videos name:string approved_at:datetime description:text likes:integer views:integer user_id:references:users
Note:
user_id:references:users
instead:
user:belongs_to
Here is a link to the latest docs .
source share