neerajkalyank commited on
Commit
977854e
1 Parent(s): f5394cc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -4
app.py CHANGED
@@ -88,11 +88,14 @@ def confirm_tests_interface(patient_id, selected_tests):
88
  return response
89
 
90
 
91
- # Billing Tab
92
  def billing_interface(patient_id):
93
- data = load_data()
94
- billing_info = fetch_billing(patient_id, data)
95
- return billing_info
 
 
 
 
96
 
97
  # Gradio Interface
98
  with gr.Blocks() as app:
 
88
  return response
89
 
90
 
 
91
  def billing_interface(patient_id):
92
+ patients, _ = load_data() # Load patients and ignore last_sequence
93
+ if patient_id in patients:
94
+ billing_info = fetch_billing(patient_id, patients)
95
+ return billing_info
96
+ else:
97
+ return "Invalid Patient ID. Please check the ID."
98
+
99
 
100
  # Gradio Interface
101
  with gr.Blocks() as app: