1
ユーザーのgroup_id
(user
のauth_user
テーブル)をauth_user_groups
テーブルに挿入する必要があります。どうすればこれを達成できますか?我々はユーザーのgroup_idを 'auth_user_groups'テーブルに挿入する方法
details = User(username = "somename",password = "somepassword", email = "email",
first_name = "firstname",
last_name = "lastname",
is_staff = 0,
is_active = 1,
is_superuser = 0
)
details.save()
を行うことができますauth_user
テーブルに挿入する
は
save = auth_user_groups(user_id=1,group_id = 5)
このような方法はあります?
ありがとう!!! – Alchemist777