Changes between Initial Version and Version 1 of Ticket #26745, comment 2


Ignore:
Timestamp:
Jun 11, 2016, 4:13:13 AM (8 years ago)
Author:
Florian Apolloner

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #26745, comment 2

    initial v1  
    66
    77Another option: Stuff something onto AppConfig and make create_superuser use `apps.get_app_config(get_user_model()._meta.app_label).create_superuser` which by default just be (ie if not defined):
    8 ```
     8{{{
    99UserModel._default_manager.db_manager(database).create_superuser(**user_data)
    10 ```
     10}}}
    1111
    1212I think pre/post are overkill, someone customizing that can as well just write the create_superuser line too.
Back to Top