我在我的項目django.contrib.auth應用程序中使用自定義應用程序和身份驗證後端替換,但仍使用原始應用程序中的某些函數/類(如_user_has_perm,_user_has_module_perms等)。禁用django.contrib.auth應用程序的遷移
的問題是,如果我不把INSTALLED_APPS我django.contrib.auth得到這樣的警告: RemovedInDjango19Warning: Model class django.contrib.auth.models.User doesn't declare an explicit app_label and either isn't in an application in INSTALLED_APPS or else was imported before its application was loaded. This will no longer be supported in Django 1.9.
但如果我把它放在INSTALLED_APPS,旁邊遷移創建我與替換我的表自定義模型。
那麼,如何禁用django.contrib.auth遷移?
您是否想要防止僅創建用戶表或所有表被創建? – knbk
我想阻止創建表auth_group,auth_permission,auth_group_permissions和django_content_type。沒有創建auth_user表.. – Alex