コード例 #1
0
ファイル: helpers.py プロジェクト: Lobos/wordstore
 def validate(value):
     if len_cn(value) <= length:
         return True
     raise Exception(u'%s最大字符长度不能超过' + str(length))
コード例 #2
0
ファイル: helpers.py プロジェクト: Lobos/wordstore
 def validate(value):
     if len_cn(value) >= length:
         return True
     raise Exception(u'%s最少字符长度不能少于 %s' % length)