mirror of
https://github.com/fastogt/fastocloud_admin.git
synced 2025-03-09 23:38:52 +00:00
Dict
This commit is contained in:
parent
0de8b3d763
commit
e111d76e74
1 changed files with 2 additions and 2 deletions
|
@ -34,7 +34,7 @@ if __name__ == '__main__':
|
|||
database='xtream_iptvpro'
|
||||
)
|
||||
|
||||
mycursor = mydb.cursor()
|
||||
mycursor = mydb.cursor(dictionary=True)
|
||||
|
||||
sql = 'SELECT username,password,exp_date,max_connections FROM users'
|
||||
|
||||
|
@ -43,7 +43,7 @@ if __name__ == '__main__':
|
|||
myresult = mycursor.fetchall()
|
||||
|
||||
for sql_entry in myresult:
|
||||
new_user = SubscriberUser.make_subscriber(email=sql_entry.username, password=sql_entry.password, country='US')
|
||||
new_user = SubscriberUser.make_subscriber(email=sql_entry['username'], password=sql_entry['password'], country='US')
|
||||
new_user.save()
|
||||
|
||||
mydb.close()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue