Browse Source

SlugTreeMixin: Check `parent` and `has_url` fields, too.

master
Erik Stein 7 years ago
parent
commit
c778a6c4d9
  1. 3
      CHANGES
  2. 2
      shared/utils/models/slugs.py

3
CHANGES

@ -1,6 +1,7 @@
0.2.13 2018-10-13 0.2.13 2018-10-13
- Improved USE_TRANSLATABLE_FIELDS - Improved USE_TRANSLATABLE_FIELDS
- Option to allow empty runtimes (without even a start date). - Option to allow empty runtimes (without even a start date)
- SlugTreeMixin: Check `has_url` and `parent` fields, too
0.2.12 2018-09-28 0.2.12 2018-09-28
- Additional text template tags. - Additional text template tags.

2
shared/utils/models/slugs.py

@ -132,7 +132,7 @@ class SlugTreeMixin(DirtyFieldsMixin, models.Model):
# TODO Make slug_path manually overridable (see feincms3 -> use_static_path) # TODO Make slug_path manually overridable (see feincms3 -> use_static_path)
has_url = models.BooleanField(_("has webaddress"), default=True) has_url = models.BooleanField(_("has webaddress"), default=True)
FIELDS_TO_CHECK = ['slug'] FIELDS_TO_CHECK = ['slug', 'parent', 'has_url']
class Meta: class Meta:
abstract = True abstract = True

Loading…
Cancel
Save