Class: Cb::Models::WorkStatus
- Inherits:
-
Object
- Object
- Cb::Models::WorkStatus
- Defined in:
- lib/cb/models/implementations/work_status.rb
Defined Under Namespace
Classes: Translation
Instance Attribute Summary collapse
-
#key ⇒ Object
Returns the value of attribute key.
-
#translations ⇒ Object
Returns the value of attribute translations.
Instance Method Summary collapse
-
#initialize(args = {}) ⇒ WorkStatus
constructor
A new instance of WorkStatus.
Constructor Details
#initialize(args = {}) ⇒ WorkStatus
Returns a new instance of WorkStatus.
6 7 8 9 10 |
# File 'lib/cb/models/implementations/work_status.rb', line 6 def initialize(args = {}) return if args.nil? @key = args['Key'] || '' @translations = [ args['Description'] ].flatten.map { |translation| Translation.new translation } end |
Instance Attribute Details
#key ⇒ Object
Returns the value of attribute key.
4 5 6 |
# File 'lib/cb/models/implementations/work_status.rb', line 4 def key @key end |
#translations ⇒ Object
Returns the value of attribute translations.
4 5 6 |
# File 'lib/cb/models/implementations/work_status.rb', line 4 def translations @translations end |