def add_user_ordinary(self): from model import User from werkzeug.security import generate_password_hash user = User() user.USid = '4304cf38-c3cf-401f-8ba7-f8ce040f064f' user.USname = 'name' user.USpassword = generate_password_hash('pass') self.session.add(user) self.session.commit()
def add_user_partner(self): from model import User from werkzeug.security import generate_password_hash user = User() user.USid = 'jfksadjf-fdaslkjf-3213-31231' user.USname = 'part' user.USpassword = generate_password_hash('pass') user.USlevel = 2 self.session.add(user) self.session.commit()
def add_user2(self): from model import User user = User() user.USid = '3404cf38-c3cf-401f-8ba7-f8ce040f064f' user.USname = 'guodong' user.USphonenum = '15058968546' user.USpassword = "******" user.USbail = 0 user.USmount = 10000 user.USheadimg = 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1540919391&di=91c1ae656341d5814e63280616ad8ade&imgtype=jpg&er=1&src=http%3A%2F%2Fimg.zcool.cn%2Fcommunity%2F0169d55548dff50000019ae9973427.jpg%401280w_1l_2o_100sh.jpg' self.session.add(user) self.session.commit()
def add_user5(self): from model import User user = User() user.USid = 'rfesrgbrtthert4535g2222233333' user.USname = 'guodongtest222333' user.USphonenum = '15058968549' user.USwechat = 'wechat' user.USagentid = 200 user.USpassword = "******" user.USbail = 0 user.USmount = 10000 user.USheadimg = 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1540919391&di=91c1ae656341d5814e63280616ad8ade&imgtype=jpg&er=1&src=http%3A%2F%2Fimg.zcool.cn%2Fcommunity%2F0169d55548dff50000019ae9973427.jpg%401280w_1l_2o_100sh.jpg' user.USpre = 'rfesrgbrtthert4535g222221' self.session.add(user) self.session.commit()
def add_user(self): from model import User user = User() user.USid = '1204cf38-c3cf-401f-8ba7-f8ce040f064f' user.USname = '123' user.USphonenum = '123' user.USwechat = 'wechat' user.USpassword = generate_password_hash('456') user.USbail = 0 user.USmount = 0 user.USagentid = 'BUB12gvhGBNV' user.idcardnum = '12345678909876512' user.USheadimg = 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1540919391&di=91c1ae656341d5814e63280616ad8ade&imgtype=jpg&er=1&src=http%3A%2F%2Fimg.zcool.cn%2Fcommunity%2F0169d55548dff50000019ae9973427.jpg%401280w_1l_2o_100sh.jpg' self.session.add(user) self.session.commit()
def add_user3(self): from model import User for i in range(3): user = User() user.USid = 'rfesrgbrt34qw32thert4535g' + str(i) user.USname = 'guodongtest' + str(i) user.USphonenum = '1505896854' + str(i) user.USwechat = 'wechat' user.USpassword = "******" user.USagentid = 100 + int(i) user.USbail = 0 user.USmount = 999999998.56 user.USheadimg = 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1540919391&di=91c1ae656341d5814e63280616ad8ade&imgtype=jpg&er=1&src=http%3A%2F%2Fimg.zcool.cn%2Fcommunity%2F0169d55548dff50000019ae9973427.jpg%401280w_1l_2o_100sh.jpg' user.USpre = '3404cf38-c3cf-401f-8ba7-f8ce040f064f' self.session.add(user) self.session.commit()