Ticket #12601: slugfield_docs.diff

File slugfield_docs.diff, 895 bytes (added by gabrielhurley, 5 years ago)

Documents SlugField in its proper place.

  • docs/ref/forms/fields.txt

     
    607607    * Validates that the given value is a valid IPv4 address, using a regular
    608608      expression.
    609609    * Error message keys: ``required``, ``invalid``
     610   
     611``SlugField``
     612~~~~~~~~~~~~~
    610613
     614.. class:: SlugField(**kwargs)
     615
     616    * Default widget: ``TextInput``
     617    * Empty value: ``''`` (an empty string)
     618    * Normalizes to: A Unicode object.
     619    * Validates that the given value consists solely of letters, numbers,
     620      underscores or hyphens. Also validates ``max_length`` or ``min_length``
     621      if they are provided.
     622    * Error message keys: ``required``, ``max_length``, ``min_length``,
     623      ``invalid``
     624
    611625``MultipleChoiceField``
    612626~~~~~~~~~~~~~~~~~~~~~~~
    613627
Back to Top