This commit is contained in:
ada-dmitry
2023-12-12 13:52:36 +03:00
parent 873072487b
commit 8722b83f16
+14 -1
View File
@@ -131,4 +131,17 @@ class DocAppointment:
self.appointment_id, self.patient, self.status, self.time_of_appoint) self.appointment_id, self.patient, self.status, self.time_of_appoint)
conn.commit() conn.commit()
finally: finally:
self.database.close(conn, cur) self.database.close(conn, cur)
database = data_base()
my_patient = patient(pat_id=11, name='Володимир Володимирович Володимир', email='volodimir@example.com', database=database)
my_patient.note_check()
application = DocAppointment(application_id=1, patient=my_patient, status='waiting', database=database)
application.add2bd()
doc = doctor(doc_id=11, doc_fio='Доктор Врачов Докторович', doc_specialization='Врач', doc_room=228, database=database)
doc.add2db()