From 23dec7fff554c5c618f10b8384d464c8e2eb34e7 Mon Sep 17 00:00:00 2001 From: Rohit Sharma Date: Tue, 25 Jun 2024 11:39:10 +0530 Subject: [PATCH] Remove Some bugs --- index.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/index.py b/index.py index 706d06b..2630830 100644 --- a/index.py +++ b/index.py @@ -87,14 +87,14 @@ def patRemove(): def dispPatient(): - patdf = pd.read_csv("csvfile\\patientnew.csv", index_col= 0) + patdf = pd.read_csv("patientnew.csv", index_col= 0) print(patdf) def serPatientbyId(pid): global patdf - patdf = pd.read_csv("csvfile\\patientnew.csv", index_col = 0) + patdf = pd.read_csv("patientnew.csv", index_col = 0) if patdf.empty: return 0 else: @@ -102,7 +102,7 @@ def serPatientbyId(pid): def getPatient(pid): global patdf - patdf = pd.read_csv("csvfile\\patientnew.csv", index_col = 0) + patdf = pd.read_csv("patientnew.csv", index_col = 0) if patdf.empty: return "Invalid ID" else: @@ -111,7 +111,7 @@ def getPatient(pid): def getPatientName(pid): - patdf = pd.read_csv("csvfile\\patientnew.csv", index_col = 0) + patdf = pd.read_csv("patientnew.csv", index_col = 0) if patdf.empty: return "Invalid ID" else: @@ -121,13 +121,13 @@ def getPatientName(pid): def serPatientbyName(): global patdf - patdf = pd.read_csv("csvfile\\patientnew.csv", index_col = 0) + patdf = pd.read_csv("patientnew.csv", index_col = 0) pname = input("Patient Name :: ") print(patdf.loc[patdf['name'] == pname]) def serPatientbyIDPrint(): global patdf - patdf = pd.read_csv("csvfile\\patientnew.csv", index_col = 0) + patdf = pd.read_csv("patientnew.csv", index_col = 0) tid = int(input("Patient ID :: ")) print(patdf.loc[patdf['pid'] == tid])