Sha256: ccfbe802d18bce891a45b180297f9256e4a05cdedce407b1e8288d577ab24e2f

Contents?: true

Size: 1008 Bytes

Versions: 46

Compression:

Stored size: 1008 Bytes

Contents

# frozen_string_literal: true

xml = builder

xml.Transplant do
  if operation.operation_type.present?
    xml.ProcedureType do
      xml.CodingStandard "SNOMED"
      xml.Code operation.procedure_type_snomed_code
      xml.Description operation.procedure_type_name
    end
  end

  xml.ProcedureTime operation.performed_on&.to_time&.iso8601

  if operation.hospital_centre_code.present?
    xml.EnteredAt do
      xml.CodingStandard "ODS"
      xml.Code operation.hospital_centre_code
      xml.Description operation.hospital_centre_name
    end
  end

  xml.Attributes do
    if operation.nhsbt_type.present?
      xml.TRA77 operation.nhsbt_type
    end
    # Note sending TRA76 yet as defined as datetime in XSD and needs changeing there.
    # if operation.rr_tra76_options.present?
    #   xml.TRA76 do
    #     xml.CodingStandard "CF_RR7_TREATMENT"
    #     xml.Code operation.rr_tra76_options[:code]
    #     xml.Description operation.rr_tra76_options[:description]
    #   end
    # end
  end
end

Version data entries

46 entries across 46 versions & 1 rubygems

Version Path
renalware-core-2.0.136 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.135 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.134 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.133 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.132 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.131 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.130 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.129 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.128 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.127 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.126 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.125 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.124 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.123 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.121 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.120 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.119 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.118 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.117 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder
renalware-core-2.0.116 app/views/renalware/api/ukrdc/patients/procedures/_transplant_operation.xml.builder