Author: mtredinnick
Date: 2007-08-11 07:10:23 -0500 (Sat, 11 Aug 2007)
New Revision: 5855

Modified:
   django/trunk/AUTHORS
   django/trunk/docs/newforms.txt
Log:
Fixed #4987 -- Added documentation for newforms.DecimalField. Based on a patch 
from [EMAIL PROTECTED]


Modified: django/trunk/AUTHORS
===================================================================
--- django/trunk/AUTHORS        2007-08-11 12:10:07 UTC (rev 5854)
+++ django/trunk/AUTHORS        2007-08-11 12:10:23 UTC (rev 5855)
@@ -141,6 +141,7 @@
     Hyun Mi Ae
     Tom Insam
     Baurzhan Ismagulov <[EMAIL PROTECTED]>
+    [EMAIL PROTECTED]
     [EMAIL PROTECTED]
     Zak Johnson <[EMAIL PROTECTED]>
     Michael Josephson <http://www.sdjournal.com/>

Modified: django/trunk/docs/newforms.txt
===================================================================
--- django/trunk/docs/newforms.txt      2007-08-11 12:10:07 UTC (rev 5854)
+++ django/trunk/docs/newforms.txt      2007-08-11 12:10:23 UTC (rev 5855)
@@ -1129,6 +1129,24 @@
     '%m/%d/%y %H:%M',        # '10/25/06 14:30'
     '%m/%d/%y',              # '10/25/06'
 
+``DecimalField``
+~~~~~~~~~~~~~~~~
+
+**New in Django development version**
+
+    * Default widget: ``TextInput``
+    * Empty value: ``None``
+    * Normalizes to: A Python ``decimal``.
+    * Validates that the given value is a decimal. Leading and trailing
+      whitespace is ignored.
+
+Takes four optional arguments: ``max_value``, ``min_value``, ``max_digits``,
+and ``decimal_places``. The first two define the limits for the fields value.
+``max_digits`` is the maximum number of digits (those before the decimal
+point plus those after the decimal point, with leading zeros stripped)
+permitted in the value, whilst ``decimal_places`` is the maximum number of
+decimal places permitted.
+
 ``EmailField``
 ~~~~~~~~~~~~~~
 
@@ -1199,6 +1217,9 @@
     * Validates that the given value is an integer. Leading and trailing
       whitespace is allowed, as in Python's ``int()`` function.
 
+Takes two optional arguments for validation, ``max_value`` and ``min_value``.
+These control the range of values permitted in the field.
+
 ``MultipleChoiceField``
 ~~~~~~~~~~~~~~~~~~~~~~~
 


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to