Sha256: b6cbd3ee5db25b28a3d709fd49ccdb61f9b60f9b68d113a97e22823c85d838f0

Contents?: true

Size: 380 Bytes

Versions: 110

Compression:

Stored size: 380 Bytes

Contents

# frozen_string_literal: true

require_dependency "renalware/transplants"

module Renalware
  module Transplants
    # Extends a RecipientWorkupDocument::YesNoUnknownConsent document attribute
    class ConsentPresenter < SimpleDelegator
      # Renders eg "12-Apr-2018 Yes"
      def to_s
        [I18n.l(consented_on), value&.text].compact.join(" ")
      end
    end
  end
end

Version data entries

110 entries across 110 versions & 1 rubygems

Version Path
renalware-core-2.1.1 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.1.0 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.167 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.166 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.165 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.164 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.163 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.162 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.161 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.160 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.159 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.158 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.157 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.156 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.155 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.153 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.152 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.151 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.149 app/presenters/renalware/transplants/consent_presenter.rb
renalware-core-2.0.148 app/presenters/renalware/transplants/consent_presenter.rb