예제 #1
0
파일: users.py 프로젝트: agrover/BandRadar
 def validate_python(self, value, state):
     rows = UserAcct.select(func.LOWER(UserAcct.q.email_address) == value.lower()).count()
     if rows:
         raise formencode.Invalid('Sorry, that email exists', value, state)
예제 #2
0
파일: users.py 프로젝트: agrover/BandRadar
 def list(self):
     u = UserAcct.select(orderBy=UserAcct.q.created).reversed()
     return dict(users=u)