I'm no genius but (6-5)*10000 should be 10000 and 5 is between 0 and 10,000
I think....
Pstart:GHzPstop:GHzPoints:
enter an integer between 0 and -49995
GHz
from decimal import *
def loadpull_points_in_range(pstop, pstart):
return IS_INT_IN_RANGE(0,
int(Decimal(pstop)-Decimal(pstart)*10000))
db.define_table('loadpull',
.
.
.
Field('pstart', 'decimal(6,4)',
requires=IS_DECIMAL_IN_RANGE(0, 300),
comment='GHz'),
Field('pstop', 'decimal(6,3)',
requires=IS_DECIMAL_IN_RANGE(0, 300),
comment='GHz'),
Field('points', 'integer',
comment='GHz'),
auth.signature,
format='%(name)s',
migrate=settings.migrate)
db.loadpull.points.requires=loadpull_points_in_range(request.vars.pstop,
request.vars.pstart)
########################################
--