Loading docs/ref/forms/fields.txt +15 −0 Original line number Diff line number Diff line Loading @@ -643,6 +643,21 @@ compatibility. The preferred way to provide an error message is to use the ``error_messages`` argument, passing a dictionary with ``'invalid'`` as a key and the error message as the value. ``SlugField`` ~~~~~~~~~~~~~ .. class:: SlugField(**kwargs) * Default widget: ``TextInput`` * Empty value: ``''`` (an empty string) * Normalizes to: A Unicode object. * Validates that the given value contains only letters, numbers and hyphens. * Error messages: ``required``, ``invalid`` This field is intended for use in representing a model :class:`~django.db.models.SlugField` in forms. ``TimeField`` ~~~~~~~~~~~~~ Loading Loading
docs/ref/forms/fields.txt +15 −0 Original line number Diff line number Diff line Loading @@ -643,6 +643,21 @@ compatibility. The preferred way to provide an error message is to use the ``error_messages`` argument, passing a dictionary with ``'invalid'`` as a key and the error message as the value. ``SlugField`` ~~~~~~~~~~~~~ .. class:: SlugField(**kwargs) * Default widget: ``TextInput`` * Empty value: ``''`` (an empty string) * Normalizes to: A Unicode object. * Validates that the given value contains only letters, numbers and hyphens. * Error messages: ``required``, ``invalid`` This field is intended for use in representing a model :class:`~django.db.models.SlugField` in forms. ``TimeField`` ~~~~~~~~~~~~~ Loading