app/models/cqm/patient.rb in cqm-models-4.1.1 vs app/models/cqm/patient.rb in cqm-models-4.2.0
- old
+ new
@@ -9,10 +9,10 @@
field :notes, type: String
field :measure_ids, type: Array
has_and_belongs_to_many :providers, class_name: 'CQM::Provider'
embeds_one :qdmPatient, class_name: 'QDM::Patient', autobuild: true
- has_many :calculation_results, class_name: 'CQM::IndividualResult'
+ has_many :calculation_results, class_name: 'CQM::IndividualResult', inverse_of: :patient
# Include '_type' in any JSON output. This is necessary for deserialization.
def to_json(options = nil)
serializable_hash(include: :_type, methods: :_type).to_json(options)
end