Sha256: 3125eb67b141dc76ecc1ef70451e0c451213e709b6d82085e3111b1ad26c3070
Contents?: true
Size: 448 Bytes
Versions: 8
Compression:
Stored size: 448 Bytes
Contents
require_dependency "renalware/pathology" module Renalware module Pathology class CreateObservations def call(params) observation_params = params.fetch(:observation_request) patient = find_patient(params.fetch(:patient_id)) patient.observation_requests.create!(observation_params) end private def find_patient(id) ::Renalware::Pathology::Patient.find(id) end end end end
Version data entries
8 entries across 8 versions & 1 rubygems