Class: Gecko::Widget::Rag
- Inherits:
-
Gecko::Widget
- Object
- Gecko::Widget
- Gecko::Widget::Rag
- Defined in:
- lib/gecko/widget/rag.rb
Instance Attribute Summary collapse
-
#amber_text ⇒ Object
Returns the value of attribute amber_text.
-
#amber_value ⇒ Object
Returns the value of attribute amber_value.
-
#green_text ⇒ Object
Returns the value of attribute green_text.
-
#green_value ⇒ Object
Returns the value of attribute green_value.
-
#red_text ⇒ Object
Returns the value of attribute red_text.
-
#red_value ⇒ Object
Returns the value of attribute red_value.
Attributes inherited from Gecko::Widget
Instance Method Summary collapse
Methods inherited from Gecko::Widget
#config, #config!, #initialize, #on_update, #payload, #push_requests, #push_url, #update
Constructor Details
This class inherits a constructor from Gecko::Widget
Instance Attribute Details
#amber_text ⇒ Object
Returns the value of attribute amber_text.
4 5 6 |
# File 'lib/gecko/widget/rag.rb', line 4 def amber_text @amber_text end |
#amber_value ⇒ Object
Returns the value of attribute amber_value.
4 5 6 |
# File 'lib/gecko/widget/rag.rb', line 4 def amber_value @amber_value end |
#green_text ⇒ Object
Returns the value of attribute green_text.
4 5 6 |
# File 'lib/gecko/widget/rag.rb', line 4 def green_text @green_text end |
#green_value ⇒ Object
Returns the value of attribute green_value.
4 5 6 |
# File 'lib/gecko/widget/rag.rb', line 4 def green_value @green_value end |
#red_text ⇒ Object
Returns the value of attribute red_text.
4 5 6 |
# File 'lib/gecko/widget/rag.rb', line 4 def red_text @red_text end |
#red_value ⇒ Object
Returns the value of attribute red_value.
4 5 6 |
# File 'lib/gecko/widget/rag.rb', line 4 def red_value @red_value end |
Instance Method Details
#data_payload ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/gecko/widget/rag.rb', line 6 def data_payload {:item => [{ :text => self.red_text, :value => self.red_value }, { :text => self.amber_text, :value => self.amber_value }, { :text => self.green_text, :value => self.green_value }]} end |