Class: SpreeCmCommissioner::VotingContestant
- Inherits:
-
Base
- Object
- Base
- SpreeCmCommissioner::VotingContestant
- Defined in:
- app/models/spree_cm_commissioner/voting_contestant.rb
Instance Method Summary collapse
- #advanced_from_name ⇒ Object
- #advanced_to_name ⇒ Object
- #special_rule_type ⇒ Object
- #special_rule_type=(value) ⇒ Object
Instance Method Details
#advanced_from_name ⇒ Object
52 53 54 |
# File 'app/models/spree_cm_commissioner/voting_contestant.rb', line 52 def advanced_from_name advanced_from&.name end |
#advanced_to_name ⇒ Object
56 57 58 |
# File 'app/models/spree_cm_commissioner/voting_contestant.rb', line 56 def advanced_to_name advanced_to&.name end |
#special_rule_type ⇒ Object
48 49 50 |
# File 'app/models/spree_cm_commissioner/voting_contestant.rb', line 48 def special_rule_type (special_rules || {})['type'] end |
#special_rule_type=(value) ⇒ Object
44 45 46 |
# File 'app/models/spree_cm_commissioner/voting_contestant.rb', line 44 def special_rule_type=(value) self.special_rules = value.present? ? { 'type' => value } : {} end |