Class: SDM::ApprovalWorkflowApprover

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

Overview

ApprovalWorkflowApprover links an approval workflow approver to an ApprovalWorkflowStep

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(account_id: nil, approval_flow_id: nil, approval_step_id: nil, id: nil, reference: nil, role_id: nil) ⇒ ApprovalWorkflowApprover



2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
# File 'lib/models/porcelain.rb', line 2757

def initialize(
  account_id: nil,
  approval_flow_id: nil,
  approval_step_id: nil,
  id: nil,
  reference: nil,
  role_id: nil
)
  @account_id =  == nil ? "" : 
  @approval_flow_id = approval_flow_id == nil ? "" : approval_flow_id
  @approval_step_id = approval_step_id == nil ? "" : approval_step_id
  @id = id == nil ? "" : id
  @reference = reference == nil ? "" : reference
  @role_id = role_id == nil ? "" : role_id
end

Instance Attribute Details

#account_idObject

The approver account id.



2743
2744
2745
# File 'lib/models/porcelain.rb', line 2743

def 
  @account_id
end

#approval_flow_idObject

The approval flow id specified the approval workflow that this approver belongs to



2745
2746
2747
# File 'lib/models/porcelain.rb', line 2745

def approval_flow_id
  @approval_flow_id
end

#approval_step_idObject

The approval step id specified the approval flow step that this approver belongs to



2747
2748
2749
# File 'lib/models/porcelain.rb', line 2747

def approval_step_id
  @approval_step_id
end

#idObject

Unique identifier of the ApprovalWorkflowApprover.



2749
2750
2751
# File 'lib/models/porcelain.rb', line 2749

def id
  @id
end

#referenceObject

A reference to an approver. Will be one of ApproverReference constants. This field is only populated when reading historical Approval Workflow Approvers data through the Approval Workflows History API. For the deprecated Approval Workflow Approvers API no value is returned for this field and it is non-settable.



2753
2754
2755
# File 'lib/models/porcelain.rb', line 2753

def reference
  @reference
end

#role_idObject

The approver role id



2755
2756
2757
# File 'lib/models/porcelain.rb', line 2755

def role_id
  @role_id
end

Instance Method Details

#to_json(options = {}) ⇒ Object



2773
2774
2775
2776
2777
2778
2779
# File 'lib/models/porcelain.rb', line 2773

def to_json(options = {})
  hash = {}
  self.instance_variables.each do |var|
    hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var
  end
  hash.to_json
end