def home_page(self): if self.email.get() == "" or self.password.get() == "": messagebox.showerror("Error", "All fields are required", parent=page) elif self.login_confirmation == False: messagebox.showerror("Error", "Invalid Email/Password", parent=page) else: messagebox.showinfo("Welcome", "Welcome to Mr.Doctor", parent=page) home_page = Home.DoctorHomePage(self.doctor_id) Frame_login.destroy()
def submit(self, list): # Get Value from the Entries name = self.name.get() designation = self.designation.get() email = self.email.get() password = self.password.get() dayList = [] for i in list.curselection(): day = list.get(i) dayList.append(day) if name == "" or designation == "" or email == "" or password == "": messagebox.showerror("Error", "All fields are required", parent=page) else: # Connect with Database dbConnect = db.dbConnect() self.submit_confirmation = dbConnect.insertData_doctor( name, designation, email, password, dayList) self.home_page() home_page = Home.DoctorHomePage(self.submit_confirmation) Frame_signup.destroy()