diff --git a/HISTORY.rst b/HISTORY.rst index e37241c5..d0387638 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -3,6 +3,19 @@ History ======= +0.7.0 +----- + +Fixes some issues which may require some users to clear out extraneous +migrations produced by using configurable base classes. + +* Fixes condition where `create_organization` produces an owner who is not an + admin user. +* Fixes issue in slug field import resulting in spurious migrations. +* Immediately deprecates configurable TimeStampedModel import. This caused + serious problems with Django's migration library which were not easily + resolved for a feature that added little value. + 0.6.1 ----- diff --git a/README.rst b/README.rst index 3acde44c..56f23b7f 100644 --- a/README.rst +++ b/README.rst @@ -3,7 +3,7 @@ django-organizations ==================== :Info: Groups and multi-user account management -:Version: 0.6.0 +:Version: 0.7.0 :Author: Ben Lopatin (http://benlopatin.com) .. image:: https://secure.travis-ci.org/bennylope/django-organizations.svg?branch=master @@ -74,26 +74,26 @@ main application URL conf as well as your chosen invitation backend URLs:: url(r'^invitations/', include(invitation_backend().get_urls())), ) -Timestamped models and auto slug fields -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Auto slug field +~~~~~~~~~~~~~~~ The standard way of using Django Organizations is to use it as an installed app -in your Django project. Django Organizations will need to use a -`TimeStampedModel` and an auto slug field which are not included. By default it -will try to import these from django-extensions, but you can configure your own -in settings. The defaults:: +in your Django project. Django Organizations will need to use an auto slug +field which are not included. By default it will try to import these from +django-extensions, but you can configure your own in settings. The default:: ORGS_SLUGFIELD = 'django_extensions.db.fields.AutoSlugField' - ORGS_TIMESTAMPED_MODEL = 'django_extensions.db.models.TimeStampedModel' -Alternatives:: +Alternative:: ORGS_SLUGFIELD = 'autoslug.fields.AutoSlugField' - ORGS_TIMESTAMPED_MODEL = 'model_utils.models.TimeStampedModels' + +Previous versions allowed you to specify an `ORGS_TIMESTAMPED_MODEL` path. This +is now ignored and the functionality satisifed by a vendored solution. A +warning will be given but this *should not* have any effect on your code. - `django-extensions `_ - `Django Autoslug `_ -- `django-model-utils `_ Registration & invitation backends ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/docs/conf.py b/docs/conf.py index 6f948ce2..fd15ae3a 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -48,9 +48,9 @@ # built documents. # # The short X.Y version. -version = '0.6' +version = '0.7' # The full version, including alpha/beta/rc tags. -release = '0.6.1' +release = '0.7.0' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff --git a/docs/getting_started.rst b/docs/getting_started.rst index 5a9408f2..222a3f38 100644 --- a/docs/getting_started.rst +++ b/docs/getting_started.rst @@ -82,28 +82,25 @@ URLs defined by that backend. You can do the same with the ORGS_INVITATION_BACKEND = 'myapp.backends.MyInvitationBackend' ORGS_REGISTRATION_BACKEND = 'myapp.backends.MyRegistrationBackend' -Timestamp model and slug field ------------------------------- +Auto slug field +--------------- Historically Django-Organizations relied on `django-extensions `_ for the base -`TimeStampedModel -`_ -and `AutoSlugField +`AutoSlugField `_. -While these work great, this does require that every project install -django-extensions for two small features. +While django-extensions is great, this does require that every project install +django-extensions for this one small feature. If you decide to use the default django-organization models by adding `organizations` to your INSTALLED_APPS, you can choose a different -TimeStampedModel base and AutoSlugField. Just specify the full dotted path like so:: +AutoSlugField. Just specify the full dotted path like so:: ORGS_SLUGFIELD = 'django_extensions.db.fields.AutoSlugField' - ORGS_TIMESTAMPED_MODEL = 'django_extensions.db.models.TimeStampedModel' -While you can specify the source of these classes, **their interfaces must be -consistent.** The TimeStampedModel should have two timestamp fields -(`DateTimeField`) named `created` and `modified`, respectively. The SlugField +While you can specify the source of this class, **its interfaces must be +consistent**, including keyword arguments. Otherwise you will end up generating +extraneous and possibly conflicting migrations in your own app. The SlugField must accept the `populate_from` keyword argument. Users and multi-account membership