mirror of
https://github.com/SectorLabs/django-localized-fields.git
synced 2025-12-14 15:52:25 +03:00
Add option include_time to LocalizedUniqueSlugField
This commit is contained in:
@@ -212,6 +212,15 @@ Besides ``LocalizedField``, there's also:
|
||||
title = LocalizedField()
|
||||
slug = LocalizedUniqueSlugField(populate_from='title')
|
||||
|
||||
By setting the option ``include_time=True``
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
slug = LocalizedUniqueSlugField(populate_from='title', include_time=True)
|
||||
|
||||
You can instruct the field to include a part of the current time into
|
||||
the resulting slug. This is useful if you're running into a lot of collisions.
|
||||
|
||||
* ``LocalizedAutoSlugField``
|
||||
Automatically creates a slug for every language from the specified field.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user