Sha256: 56a98fd9db885c4e840e19a874bbd5781e2f4d5c2bcab7b8ee9f41f822be8538

Contents?: true

Size: 453 Bytes

Versions: 7

Compression:

Stored size: 453 Bytes

Contents

module Lifen
  class Patient < Base

    attribute :first_name, String
    attribute :last_name, String
    attribute :birthdate, Date

    def fhir_payload
      {
        id: "patient",
        resourceType: "Patient",
        name: [
          {
            family: [
              last_name
            ],
            given: [
              first_name
            ]
          }
        ],
        birthDate: birthdate.to_s
      }
    end

  end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
lifen-fhir-0.1.0 lib/lifen/patient.rb
lifen-3.0.0 lib/lifen/patient.rb
lifen-2.4.0 lib/lifen/patient.rb
lifen-2.3.0 lib/lifen/patient.rb
lifen-2.2.0 lib/lifen/patient.rb
lifen-2.1.0 lib/lifen/patient.rb
lifen-2.0.0 lib/lifen/patient.rb