def setstatus(id, status): isbigint(id) issmallint(status) db.update('notes', where='id=$id', status=status, vars=locals(), _test=is_debug)
def changepwd(i): isbigint(i.id) isvarchar(i.email,1,50) isvarchar(i.password,1,100) isdatetime(i.registerdate) isdatetime(i.lastlogindate) issmallint(i.status) id = i.id db.update('users',where='id=$id', id=i.id,email=i.email,password=i.password,registerdate=i.registerdate,lastlogindate=i.lastlogindate,status=i.status, vars=locals(),_test=is_debug)
def setstatus(id,status): isbigint(id) issmallint(status) db.update('notes',where='id=$id', status = status, vars=locals(),_test=is_debug)