Exception: SpreeCmCommissioner::Seats::BlocksAreOnHoldByOtherGuestError
- Inherits:
-
StandardError
- Object
- StandardError
- SpreeCmCommissioner::Seats::BlocksAreOnHoldByOtherGuestError
- Defined in:
- app/errors/spree_cm_commissioner/seats/blocks_are_on_hold_by_other_guest_error.rb
Instance Attribute Summary collapse
-
#block_label ⇒ Object
readonly
Returns the value of attribute block_label.
Instance Method Summary collapse
-
#initialize(block_label = nil) ⇒ BlocksAreOnHoldByOtherGuestError
constructor
A new instance of BlocksAreOnHoldByOtherGuestError.
-
#message ⇒ Object
override.
Constructor Details
#initialize(block_label = nil) ⇒ BlocksAreOnHoldByOtherGuestError
Returns a new instance of BlocksAreOnHoldByOtherGuestError.
5 6 7 8 |
# File 'app/errors/spree_cm_commissioner/seats/blocks_are_on_hold_by_other_guest_error.rb', line 5 def initialize(block_label = nil) @block_label = block_label super() end |
Instance Attribute Details
#block_label ⇒ Object (readonly)
Returns the value of attribute block_label.
3 4 5 |
# File 'app/errors/spree_cm_commissioner/seats/blocks_are_on_hold_by_other_guest_error.rb', line 3 def block_label @block_label end |
Instance Method Details
#message ⇒ Object
override
11 12 13 14 15 16 17 |
# File 'app/errors/spree_cm_commissioner/seats/blocks_are_on_hold_by_other_guest_error.rb', line 11 def if block_label.present? I18n.t('line_item.validation.blocks_are_on_hold_by_other_guest_with_label', label: block_label) else I18n.t('line_item.validation.blocks_are_on_hold_by_other_guest') end end |