示例#1
0
文件: manager.py 项目: VeryCB/wedding
def init_data():
    for name, display_name, count in USERS:
        try:
            user = User.add(name=name, display_name=display_name, count=count)
        except IntegrityError:
            continue
        print 'User {0} is added'.format(user)
示例#2
0
文件: app.py 项目: VeryCB/wedding
 def load_user(id_):
     return User.get(id_)