Sha256: 794b8059750024c981b9457c2f86bda6a6139cf2e55425f0eb9fa0fc91f915b3
Contents?: true
Size: 557 Bytes
Versions: 16
Compression:
Stored size: 557 Bytes
Contents
# frozen_string_literal: true module Renalware module HD class PatientListener def patient_modality_changed_to_death(patient:, modality:, actor:) nullify_significant_hd_profile_attributes(patient, by: actor) end private def nullify_significant_hd_profile_attributes(patient, by:) hd_profile = HD.cast_patient(patient).hd_profile return if hd_profile.nil? hd_profile.hospital_unit = nil hd_profile.schedule_definition = nil hd_profile.save_by!(by) end end end end
Version data entries
16 entries across 16 versions & 1 rubygems