6π
β
This is a known issue. There is a recently updated pull request to fix it, so with any luck it will be fixed in the next version of Django.
In the mean time there are some suggested workarounds in the ticket above. The simplest seems to be to manually create a migration for an un-managed model that points to your proxy model, which will then trigger the appropriate permission objects to be created:
migrations.CreateModel(
name='InstitutionOwnerGroup',
fields=[
],
options={
'verbose_name': 'Group',
'managed': False, # Make it unmanaged
'proxy': True,
'verbose_name_plural': 'Groups',
},
bases=('myapp.proxies.group',),
managers=[
('objects', django.contrib.auth.models.GroupManager()),
],
),
Your mileage may vary with this β Iβm not sure it is entirely safe to do.
π€solarissmoke
Source:stackexchange.com