Пример #1
0
 def deleteClientFromList(self, clientToDelete, ui=True) -> None:
     #Functie care sterge un client din repo
     #Date de intrare: clientToDelete Client
     #Date de iesire: -
     idx = 0
     for index, client in enumerate(self.__listaClienti):
         if client.getId() == clientToDelete.getId():
             idx = index
             break
     del(self.__listaClienti[idx])
     if ui: UI.display_client_deleted_notification()
Пример #2
0
 def meniu_sterge_client(self):
     id_client = input("ID-ul clientului pe care vrei sa-l stergi: ")
     self.__dict_list[self.__user_input](id_client)
     self.__dict_list['21'](int(id_client))
     UI.display_client_deleted_notification()