lib/health-data-standards/models/medication.rb in health-data-standards-0.5.0 vs lib/health-data-standards/models/medication.rb in health-data-standards-0.7.0
- old
+ new
@@ -1,25 +1,45 @@
class Medication < Entry
- field :administrationTiming, type: Hash, as: 'administration_timing'
- field :freeTextSig, type: String, as: 'free_text_sig'
+ field :administrationTiming, type: Hash
+ field :freeTextSig, type: String
field :dose, type: Hash
- field :brandName, type: String, as: 'brand_name'
- field :typeOfMedication, type: Hash, as: 'type_of_medication'
- field :statusOfMedication, type: Hash, as: 'status_of_medication'
+ field :brandName, type: String
+ field :typeOfMedication, type: Hash
+ field :statusOfMedication, type: Hash
embeds_many :fulfillmentHistory, class_name: 'FulfillmentHistory'
embeds_many :orderInformation, class_name: 'OrderInformation'
field :route, type: Hash
field :site, type: Hash
- field :doseRestriction, type: Hash, as: 'dose_restriction'
- field :fulfillmentInstructions, type: String, as: 'fulfillment_instructions'
+ field :doseRestriction, type: Hash
+ field :fulfillmentInstructions, type: String
field :indication, type: Hash
- field :productForm, type: Hash, as: 'product_form'
+ field :productForm, type: Hash
field :vehicle, type: Hash
field :reaction, type: Hash
- field :deliveryMethod, type: Hash, as: 'delivery_method'
- field :patientInstructions, type: String, as: 'patient_instructions'
+ field :deliveryMethod, type: Hash
+ field :patientInstructions, type: String
+ alias :administration_timing :administrationTiming
+ alias :administration_timing= :administrationTiming=
+ alias :free_text_sig :freeTextSig
+ alias :free_text_sig= :freeTextSig=
+ alias :brand_name :brandName
+ alias :brand_name= :brandName=
+ alias :type_of_medication :typeOfMedication
+ alias :type_of_medication= :typeOfMedication=
+ alias :status_of_medication :statusOfMedication
+ alias :status_of_medication= :statusOfMedication=
alias :fulfillment_history :fulfillmentHistory
alias :fulfillment_history= :fulfillmentHistory=
alias :order_information :orderInformation
alias :order_information= :orderInformation=
+ alias :dose_restriction :doseRestriction
+ alias :dose_restriction= :doseRestriction=
+ alias :fulfillment_instructions :fulfillmentInstructions
+ alias :fulfillment_instructions= :fulfillmentInstructions=
+ alias :product_form :productForm
+ alias :product_form= :productForm=
+ alias :delivery_method :deliveryMethod
+ alias :delivery_method= :deliveryMethod=
+ alias :patient_instructions :patientInstructions
+ alias :patient_instructions= :patientInstructions=
end
\ No newline at end of file