Class: OpenWFE::Extras::Field
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- OpenWFE::Extras::Field
- Defined in:
- lib/openwfe/extras/participants/activeparticipants.rb
Overview
A Field (Attribute) of a Workitem.
Class Method Summary collapse
-
.new_field(key, value) ⇒ Object
A quick method for doing.
Instance Method Summary collapse
Class Method Details
.new_field(key, value) ⇒ Object
413 414 415 416 417 418 419 |
# File 'lib/openwfe/extras/participants/activeparticipants.rb', line 413 def self.new_field (key, value) f = Field.new f.fkey = key f.value = value f end |
Instance Method Details
#value ⇒ Object
430 431 432 433 434 |
# File 'lib/openwfe/extras/participants/activeparticipants.rb', line 430 def value return self.svalue if self.svalue self.yvalue end |
#value=(v) ⇒ Object
421 422 423 424 425 426 427 428 |
# File 'lib/openwfe/extras/participants/activeparticipants.rb', line 421 def value= (v) if v.is_a?(String) self.svalue = v else self.yvalue = v end end |