Commit Graph

114 Commits

Author SHA1 Message Date
Massimo c2a23d03c2 fixed issues with regex2 in validators? 2014-01-09 11:47:32 -06:00
mdipierro 09fb170a83 possibile regex fix 2014-01-09 08:38:39 -06:00
mdipierro 4192405444 IS_LIST_OF(other=[..]) 2014-01-08 13:43:49 -06:00
mdipierro 5a0aec5b1d fixed LazyCrypt.__ne__, thanks Jonathan 2014-01-08 10:24:37 -06:00
mdipierro e56e376894 fixed issue 1836, Problem with IS_IN_DB(label='%(x)3.3s') 2014-01-03 20:58:57 -06:00
hectord 231fa489cb Translate the formatters for DATE/DATETIME_IN_RANGE validators 2013-11-01 22:43:31 +01:00
niphlod 78a0fe0769 removed unmaintained test.sh, ported validators doctests to unittests, fixed an issue with IS_MATCH() that never worked 2013-10-13 17:48:07 +02:00
Stefan Pochmann 20cdd86fcf simpler integer validation test 2013-10-12 22:42:27 +02:00
Stefan Pochmann 351a59033f unified and easier number range validator constructors 2013-10-12 21:46:17 +02:00
Stefan Pochmann 34bfe4527d consistency in error messages of number range validators 2013-10-12 21:22:11 +02:00
Stefan Pochmann 667069b573 Corrections for IS_INT_IN_RANGE 2013-10-12 21:10:29 +02:00
mdipierro 5551a018ac fixed unnecessary escaping in regex, thanks Stefan Pochmann 2013-10-11 22:36:39 -05:00
mdipierro 1356dc1ef0 +-int in IS_INT validator 2013-10-11 20:42:51 -05:00
mdipierro ff7f9568db fixed validation of nagtive integers, thanks Stefan 2013-10-11 18:06:57 -05:00
mdipierro d5fda056ff simplified logic for number validators 2013-10-11 17:07:17 -05:00
mdipierro d8e8d1d597 fixed problem with IS_INT_IN_RANGE for large numbers 2013-10-11 16:59:05 -05:00
mdipierro f8e2c8e319 new validator IS_LIST_OF_EMAILS 2013-09-20 21:17:05 -05:00
mdipierro 4556a355a2 fixed a problem with CRYPT password length 2013-09-15 11:46:46 -05:00
mdipierro 7dafb07438 added a extra level of protection for long passwords, even if IS_LENGTH validator is missing 2013-09-15 09:40:15 -05:00
mdipierro 6c1cc6fc96 tabs -> spaces 2013-09-13 15:39:39 -05:00
mdipierro ed9def985e R-2.6.1 2013-09-12 17:08:52 -05:00
mdipierro aacbb5cef8 reverted previous patch 2013-09-07 21:01:30 -05:00
Luca de Alfaro fae29bf0e1 Update validators.py
Updated the IS_DATETIME validator; otherwise it would fail when creating a new record with SQLFORM, for dates that have an empty default.
2013-09-07 16:57:17 -07:00
mdipierro 2d59e86ab9 removed e, no None in IS_JSON 2013-07-23 01:05:09 -05:00
mdipierro 44985f0076 removed non-translatable json error 2013-07-22 14:52:53 -05:00
Michele Comitini 8d7f6b7b7f improved json validator to output meaningful error 2013-07-22 15:07:12 +02:00
Michele Comitini abf138c842 bugfix native json fields were not supported correcly 2013-07-21 23:32:58 +02:00
mdipierro d1065178bd css.patch, less html5 syntax error noise, thanks Jonathan 2013-07-12 09:52:31 -05:00
mdipierro 4b2afc8ae1 fixed Issue 1541:[REQ] support for dot=T('.') in IS_DECIMAL_IN_RANGE() 2013-06-18 04:45:16 -05:00
mdipierro 69c888d071 Issue 1506: length argument wrong with unicode 2013-05-27 10:33:37 -05:00
mdipierro a380ae69d5 IS_SLUG patch, thanks Jonathan, Niphlod and Villas 2013-05-15 12:41:28 -05:00
mdipierro 8e4bc72fca IS_IPADDRESS added to __all__ 2013-05-03 08:27:35 -05:00
mdipierro bc481e954c something went wrong with VCS, trying fix it 2013-05-02 20:32:21 -05:00
mdipierro 97b70eff9f better populate 2013-04-24 18:05:22 -05:00
Michele Comitini c999b16a27 Merge with upstream. 2013-04-13 00:04:26 +02:00
Michele Comitini 9bda793d46 orderby disabled where not needed 2013-04-13 00:03:43 +02:00
Massimo 5e9fbdd24f faster labels, thanks Anthony 2013-04-12 13:07:37 -05:00
mdipierro 2119bacd22 Merge pull request #71 from grutz/IS_IPADDRESS
Adds IS_IPADDRESS() to gluon/validators.py
2013-04-07 19:41:25 -07:00
mdipierro 89021b6409 fixed Issue 1432:Oracle: invalid SQL generated when requires = IS_NOT_IN_DB, thanks jphillips 2013-04-06 09:40:07 -05:00
Kurt Grutzmacher 79a4693f34 Adds IS_IPADDRESS() to gluon/validators.py
IS_IPADDRESS() is mostly a meta function that will call IS_IPV4()
or IS_IPV6 accordingly based upon both dev-configured logic and
library checking of the address given. For instance:

 >>> IS_IPADDRESS()('192.168.1.5')
 ('192.168.1.5', None)

will run through the IS_IPV4() function since the ipaddr.py lib
recognizes it as an IPv4 address. Specific v4 or v6 validation
can be done by setting is_ipv4=True or is_ipv6=True:

 >>> IS_IPADDRESS(is_ipv4=True)('fe80::126c:8ffa:fe22:b3af')
 ('fe80::126c:8ffa:fe22:b3af', 'enter valid IP address')
 >>> IS_IPADDRESS(is_ipv6=True)('192.168.1.1')
 ('192.168.1.1', 'enter valid IP address')

The same arguments for IS_IPV4() and IS_IPV6() are supported and
no changes have been made to either of these two functions. The
goal of this function is to allow IPv4 or IPv6 addresses in a
textfield:

 INPUT(_type='text', _name='name', requires=IS_IPADDRESS())
2013-04-05 09:14:37 -07:00
mdipierro d6af8279bc Merge pull request #68 from mictee/any_of_validator
Added an ANY_OF validator
2013-03-31 16:17:48 -07:00
Kurt Grutzmacher 721cb2b90a Adds IS_IPV6() validator using Google ipaddr.py library
ipaddr.py library rev/3144 has been approved as a standard python
library for python3. IS_IPV4() was not modified to use the library.
2013-03-29 08:55:06 -07:00
mictee f98548827a Added an ANY_OF validator that allows a value to be valid according to any of a list of validators. 2013-03-26 17:24:19 +01:00
mdipierro 3494fa2d0d changed the logic behind tz 2013-03-18 22:48:52 -05:00
Massimo 3f7d085f73 fixed timezone and textarea default width 2013-03-18 17:34:06 -05:00
mdipierro 8857e3d521 IS_DATE/DATETIME/etc. (timezone=user_timezone in hrs) 2013-03-17 18:53:19 -05:00
mdipierro f92d97f36e fixed bug in encode/decode, thanks Jonathan 2013-03-10 11:06:20 -05:00
mdipierro 72dade793a attempt to support unicode in IT_MATCH 2013-03-10 10:45:29 -05:00
Massimo 5d9fc2e9af fixed issue VirtualFields in select options 2013-02-21 10:21:31 -06:00
mdipierro 4334ae38ed fixed issue 1339, faster IS_NOT_IN_DB 2013-02-17 01:00:01 -06:00