Пример #1
0
def start_module():
    """
    Starts this module and displays its menu.
     * User can access default special features from here.
     * User can go back to main menu from here.

    Returns:
        None
    """
    exit_message = main.handle_menu()
    title = "Human resources manager"
    list_options = [
        'Show table Hr', 'Add user', 'remove', 'update', 'Olders',
        'Closeset Yesr'
        'exit program'
    ]
    ui.print_manu(title, list_options, exit_message)
    # id_ =
    table = data_manager.get_table_from_file("persons.csv")
    inputs = ui.get_inputs(["Please enter a number: "], "")
    option = inputs[0]
    if option == "1":
        show_table(table)
    elif option == "2":
        add(table)
    elif option == "3":
        remove(table, id_)
    elif option == "4":
        update(table)
    elif option == "5":
        get_oldest_person(table)
    elif option == "6":
        get_persons_closest_to_average(table)
    elif option == "0":
        main.main()
def start_module():
    """
    Starts this module and displays its menu.
     * User can access default special features from here.
     * User can go back to main menu from here.

    Returns:
        None
    """
    options = ['Show table Hr', 'Add user', 'remove ]
    ui.print_manu("Human resources manager",options, exit_message)
def start_module():
    """
    Starts this module and displays its menu.
     * User can access default special features from here.
     * User can go back to main menu from here.

    Returns:
        None
    """
    title = "Human resources manager"
    list_options = ['Show table Hr', 'Add user', 'remove' , 'update', 'exit program' ]
    ui.print_manu(title, list_options, "Main manu")