User permissions on proxy models in modeladmin

前端 未结 4 1245
被撕碎了的回忆
被撕碎了的回忆 2020-12-17 21:22

When using a proxy model:

class Uf(models.Model):
...

class CustomUf(Uf):
    class Meta:
        proxy = True

class CustomUfAdmin(admin.ModelAdmin)

admin         


        
4条回答
  •  臣服心动
    2020-12-17 21:56

    Ok, Chris remark about content types gave me the hint...

    I made the mistake to define the proxy object in "admin.py". This way, you have to be superadmin to access it.

    If I define the proxy object in models.py, then the content type appears and everything works fine...

提交回复
热议问题