Sha256: 468d94c831b9d5577776fa2fec048d089a69d3766147a934035b4692dd128b23

Contents?: true

Size: 597 Bytes

Versions: 90

Compression:

Stored size: 597 Bytes

Contents

# frozen_string_literal: true

require_dependency "renalware/hd"

module Renalware
  module HD
    class PrescriptionAdministration < ApplicationRecord
      include Accountable

      # Set to true by the parent hd_session if we are not signing off at this stage
      attr_accessor :skip_validation

      belongs_to :hd_session, class_name: "HD::Session", touch: true
      belongs_to :prescription, class_name: "Medications::Prescription"
      validates :administered, inclusion: { in: [true, false] }, unless: :skip_validation
      validates :prescription, presence: true
    end
  end
end

Version data entries

90 entries across 90 versions & 1 rubygems

Version Path
renalware-core-2.0.105 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.104 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.103 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.102 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.101 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.100 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.99 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.98 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.97 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.96 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.95 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.94 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.93 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.92 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.91 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.90 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.89 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.88 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.87 app/models/renalware/hd/prescription_administration.rb
renalware-core-2.0.86 app/models/renalware/hd/prescription_administration.rb