reorganize application code into fiveparaminte-main directory structure
This commit is contained in:
@@ -165,6 +165,10 @@ def parse_contec_hl7_text(raw_text: str, client_ip: str) -> Optional[NormalizedV
|
||||
if len(fields) > 8 and fields[8]:
|
||||
vitals_dict["patient_gender"] = fields[8].strip().upper()
|
||||
|
||||
# PID-35: Patient Category (ADULT / PEDIATRIC / NEONATAL)
|
||||
if len(fields) > 35 and fields[35]:
|
||||
vitals_dict["patient_type"] = fields[35].strip()
|
||||
|
||||
elif seg_name == "PV1":
|
||||
# PV1-3: Assigned Patient Location (Room^Bed^...)
|
||||
if len(fields) > 3 and fields[3]:
|
||||
@@ -174,6 +178,10 @@ def parse_contec_hl7_text(raw_text: str, client_ip: str) -> Optional[NormalizedV
|
||||
if bed:
|
||||
vitals_dict["bed_id"] = bed
|
||||
|
||||
# PV1-18: Patient Type
|
||||
if len(fields) > 18 and fields[18]:
|
||||
vitals_dict["patient_type"] = fields[18].strip()
|
||||
|
||||
elif seg_name == "OBX":
|
||||
if len(fields) > 5:
|
||||
obs_val = fields[5].strip()
|
||||
|
||||
Reference in New Issue
Block a user