-
Notifications
You must be signed in to change notification settings - Fork 0
/
main_v2.py
78 lines (61 loc) · 1.54 KB
/
main_v2.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
from Biblioteca import *
def menu():
print("Selecione a opção:\n"
"1 – Cadastrar novo livro\n"
"2 – Listar livros\n"
"3 – Buscar livros por nome\n"
"4 – Buscar livros por categoria\n"
"5 – Buscar livros por preço\n"
"6 – Busca por quantidade em estoque\n"
"7 – Valor total no estoque\n"
"8 – Carregar estoque\n"
"9 – Atualizar arquivo de estoque\n"
"0 – Encerrar atividades\n")
match input():
case "55":
cadastrar_temp()
print()
menu()
case "1":
cadastrar_livro()
print()
menu()
case "2":
listar_livros()
print()
menu()
case "3":
pesquisar_nome()
print()
menu()
case "4":
pesquisar_categoria()
print()
menu()
case "5":
pesquisar_preco()
print()
menu()
case "6":
pesquisar_estoque()
print()
menu()
case "7":
somar_estoque()
print()
menu()
case "8":
carregar_arquivo()
print()
menu()
case "9":
atualizar_arquivo()
print()
menu()
case "0":
checar_alteracao()
menu()
case str():
print("\nOpção inválida!\n")
menu()
menu()