Sha256: a54b0b491a29bf96cfa7e7fd924ba11bfa5611b8a841c7e5551aae07fb13c9c2
Contents?: true
Size: 654 Bytes
Versions: 119
Compression:
Stored size: 654 Bytes
Contents
# frozen_string_literal: true require_dependency "renalware/patients" module Renalware module Patients # Responsible for transforming an HL7 message payload into a params hash # that can be persisted by Patient. # class MessageParamParser def parse(hl7_message) pi = hl7_message.patient_identification { patient: { nhs_number: pi.external_id, local_patient_id: pi.internal_id, family_name: pi.family_name, given_name: pi.given_name, sex: pi.sex, born_on: Date.parse(pi.dob).to_s } } end end end end
Version data entries
119 entries across 119 versions & 1 rubygems