Laravel Many-to-Many Relationship -
i have 2 models user , role have turned off timestamps both of them so
public static $timestamps=false and have removed created_at , updated_at columns both tables(users & roles).
i have 3rd pivot table called role_user 3 columns id,user_id , role_id
when seek find role of user maintain getting column unknown role_user.created_at not found.`
please help stuck problem. give thanks in advance!
in laravel 3 pivot tables needs have time stamp. either add together line migrations: $table->timestamps() or create columns manually. believe column type datetime both created_at , updated_at columns.
many-to-many laravel laravel-3
No comments:
Post a Comment