Opened 18 years ago

Closed 18 years ago

#2364 closed enhancement (fixed)

[patch] Add a numeric range validator

Reported by: Matt McClanahan Owned by: Adrian Holovaty
Component: Core (Other) Version:
Severity: minor Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

This patch adds NumericRangeValidator to core/validators.py. Both upper and lower bounds are optional.

Usages:

minimumValue = NumericRangeValidator(lower_bound=10)
maximumValue = NumericRangeValidator(upper_bound=20)
valueRange = NumericRangeValidator(10,20)

Attachments (3)

numericrangevalidator.diff (1.4 KB ) - added by Matt McClanahan 18 years ago.
numericrangevalidator-doc.diff (736 bytes ) - added by Matt McClanahan 18 years ago.
Doc patch for docs/forms.txt
numericrangevalidator-doc-1.diff (690 bytes ) - added by Matt McClanahan <cardinal@…> 18 years ago.
Doc patch for docs/forms.txt - Rephrased a bit

Download all attachments as: .zip

Change History (4)

by Matt McClanahan, 18 years ago

Attachment: numericrangevalidator.diff added

by Matt McClanahan, 18 years ago

Doc patch for docs/forms.txt

by Matt McClanahan <cardinal@…>, 18 years ago

Doc patch for docs/forms.txt - Rephrased a bit

comment:1 by Jacob, 18 years ago

Resolution: fixed
Status: newclosed

(In [4039]) Fixed #2364: added NumberIsInRange validator. Thanks, Matt McClanahan.

Note: See TracTickets for help on using tickets.
Back to Top