Class: MergeAccountingClient::InvoiceStatusEnum

Inherits:
Object
  • Object
show all
Defined in:
lib/merge_accounting_client/models/invoice_status_enum.rb

Constant Summary collapse

"PAID".freeze
DRAFT =
"DRAFT".freeze
SUBMITTED =
"SUBMITTED".freeze
PARTIALLY_PAID =
"PARTIALLY_PAID".freeze
OPEN =
"OPEN".freeze
VOID =
"VOID".freeze
MERGE_NONSTANDARD_VALUE =
"MERGE_NONSTANDARD_VALUE".freeze

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#raw_valueObject

Returns the value of attribute raw_value.



28
29
30
# File 'lib/merge_accounting_client/models/invoice_status_enum.rb', line 28

def raw_value
  @raw_value
end

#valueObject

Returns the value of attribute value.



27
28
29
# File 'lib/merge_accounting_client/models/invoice_status_enum.rb', line 27

def value
  @value
end

Class Method Details

.build_from_hash(value) ⇒ Object



44
45
46
# File 'lib/merge_accounting_client/models/invoice_status_enum.rb', line 44

def self.build_from_hash(value)
  InvoiceStatusEnum.new.build_from_hash(value)
end

Instance Method Details

#build_from_hash(value) ⇒ String

Builds the enum from string

Parameters:

  • The (String)

    enum value in the form of the string

Returns:

  • (String)

    The enum value



33
34
35
36
37
38
39
40
41
42
# File 'lib/merge_accounting_client/models/invoice_status_enum.rb', line 33

def build_from_hash(value)
  @raw_value = value
  if ["PAID", "DRAFT", "SUBMITTED", "PARTIALLY_PAID", "OPEN", "VOID", ].include? value
    @value = value
  else
    @value = MERGE_NONSTANDARD_VALUE
  end

  self
end