Пример #1
0
def get_test():
    for users in Users.select().where(Users.banned == 0):
        print users.id
Пример #2
0
def models_test():
    #for user in User.select():
    #    print user.key
    #print User.get_one(User.key == 'sx2767722_10')
    u = Users.get_one(Users.username == 'kakou')
    print u.password
Пример #3
0
def create_table():
    Users.create_table(True)
    Recglist.create_table(True)
Пример #4
0
from car_recg import app, Users
from car_recg import debug_logging, online_logging, RecgServer, MyIni

if __name__ == '__main__':
    Users.create_table(True)
    debug_logging('log\carrecgser.log')
    rs = RecgServer()
    rs.main()
    ini = MyIni()
    sysini = ini.get_sys_conf()
    app.config['THREADS'] = sysini['threads']
    app.config['MAXSIZE'] = sysini['threads'] * 16
    app.run(host='0.0.0.0', port=sysini['port'], threaded=True)
    del rs
    del ini
Пример #5
0
def models_test():
    #for user in User.select():
    #    print user.key
    #print User.get_one(User.key == 'sx2767722_10')
    u = Users.get_one(Users.username == 'kakou')
    print u.password
Пример #6
0
def get_test():
    for users in Users.select().where(Users.banned == 0):
        print users.id
Пример #7
0
def create_table():
    Users.create_table(True)
    Recglist.create_table(True)