Skip to content

Commit

Permalink
Modified templete for external results import file
Browse files Browse the repository at this point in the history
  • Loading branch information
UdaySagar-Git committed Mar 9, 2024
1 parent d82afc9 commit 2276112
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion public/External-Results-Template.csv
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
District,srf id,name,age,age in,gender,mobile number,address,ward,local body,local body type,source,Sample Collection Date,result date,test type,lab name,sample type,patient status,Is Repeat,patient category,result
District,SRF ID,Name,Age,Age in,Gender,Mobile Number,Address,Ward,Local Body,Local Body Type,Source,Sample Collection Date,Result Date,Test Type,Lab Name,Sample Type,Patient Status,Is Repeat,Patient Category,Result
Ernakulam,00/EKM/0000,Bodhi CSN,24,years,m,8888888888,"CSN HQ
Kochi, Kerala ",7,Poothrikka,grama panchayath,Secondary contact aparna,2020-10-14,2020-10-14,Antigen,Karothukuzhi Laboratory,Ag-SD_Biosensor_Standard_Q_COVID-19_Ag_detection_kit,Asymptomatic,NO,Cat 17: All individuals who wish to get themselves tested,Negative
36 changes: 18 additions & 18 deletions src/Common/constants.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1023,17 +1023,17 @@ export const AssetImportSchema: SchemaType = {

export const ExternalResultImportSchema: SchemaType = {
District: { prop: "district", type: "any" },
"srf id": { prop: "srf_id", type: "string" },
name: { prop: "name", type: "string" },
age: { prop: "age", type: "number" },
"age in": { prop: "age_in", type: "string" },
gender: { prop: "gender", type: "string" },
"mobile number": { prop: "mobile_number", type: "any" },
address: { prop: "address", type: "string" },
ward: { prop: "ward", type: "number" },
"local body": { prop: "local_body", type: "string" },
"local body type": { prop: "local_body_type", type: "string" },
source: { prop: "source", type: "string" },
"SRF ID": { prop: "srf_id", type: "string" },
Name: { prop: "name", type: "string" },
Age: { prop: "age", type: "number" },
"Age in": { prop: "age_in", type: "string" },
Gender: { prop: "gender", type: "string" },
"Mobile Number": { prop: "mobile_number", type: "any" },
Address: { prop: "address", type: "string" },
Ward: { prop: "ward", type: "number" },
"Local Body": { prop: "local_body", type: "string" },
"Local Body Type": { prop: "local_body_type", type: "string" },
Source: { prop: "source", type: "string" },
"Sample Collection Date": {
prop: "sample_collection_date",
type: "string",
Expand All @@ -1047,7 +1047,7 @@ export const ExternalResultImportSchema: SchemaType = {
return dateQueryString(parsed);
},
},
"result date": {
"Result Date": {
prop: "result_date",
type: "string",
parse: (date: string) => {
Expand All @@ -1060,13 +1060,13 @@ export const ExternalResultImportSchema: SchemaType = {
return dateQueryString(parsed);
},
},
"test type": { prop: "test_type", type: "string" },
"lab name": { prop: "lab_name", type: "string" },
"sample type": { prop: "sample_type", type: "string" },
"patient status": { prop: "patient_status", type: "string" },
"Test Type": { prop: "test_type", type: "string" },
"Lab Name": { prop: "lab_name", type: "string" },
"Sample Type": { prop: "sample_type", type: "string" },
"Patient Status": { prop: "patient_status", type: "string" },
"Is Repeat": { prop: "is_repeat", type: "string" },
"patient category": { prop: "patient_category", type: "string" },
result: { prop: "result", type: "string" },
"Patient Category": { prop: "patient_category", type: "string" },
Result: { prop: "result", type: "string" },
};

export const USER_TYPES_MAP = {
Expand Down

0 comments on commit 2276112

Please sign in to comment.