Commit 77285926 by BellCodeEditor

save project

parent fcf3f6a5
Showing with 6 additions and 1 deletions
import tkinter
from tkinter import messagebox
import json
with open("user.txt","r",encoding="utf-8") as f:
info = f.read()
users = json.loads(info)
def login_to_reg(): # 登录界面转注册界面
app_login.root.destroy()
global app_reg
......@@ -15,6 +19,7 @@ def register(): # 注册验证
name,password1,password2 = app_reg.get_input()
if name == "" or password1 == password2 == "":
messagebox.showwaring("警告","请填写完整的注册内容")
elif name in users:
messagebox.showwaring("警告","用户名已存在")
elif password1 != password2:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment