def run_main():
    close = False
    while not close:
        connect = None
        choice, choice1 = validate_choice()
        if choice == 0:
            close = True
        elif choice == 1:
            connect = customer_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 2:
            connect = product_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 3:
            connect = prescription_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 4:
            connect = order_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 5:
            connect = manufacturer_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        else:
            print("Hey Listen")
 def __init__(self):
     self.running = None
     self.active_detail = prescription_manage()
     self.active_replacement = customer_menu()
     self.active_products = product_manage()
 def __init__(self):
     self.running = None
     self.active_detail = prescription_manage()
     self.active_replacement = customer_menu()
     self.active_products = product_manage()
Beispiel #4
0
def run_main():
    close = False
    while not close:
        connect = None
        choice, choice1 = validate_choice()
        if choice == 0:
            close = True
        elif choice == 1:
            connect = customer_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 2:
            connect = product_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 3:
            connect = prescription_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 4:
            connect = order_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        elif choice == 5:
            connect = manufacturer_menu()
            if choice1 == 1:
                connect.run_menu(choice1)
            elif choice1 == 2:
                connect.run_menu(choice1)
            elif choice1 == 3:
                connect.run_menu(choice1)
            elif choice1 == 4:
                connect.run_menu(choice1)
            elif choice1 == 5:
                connect.run_menu(choice1)
        else:
            print("Hey Listen")