Module: StarkitBanking::Payment

Extended by:
ActiveSupport::Concern
Includes:
ApiStepConcern
Defined in:
lib/starkit_banking/concerns/payment.rb,
lib/starkit_banking/api/ybl/payment/activity.rb

Defined Under Namespace

Classes: Activity

Instance Method Summary collapse

Methods included from ApiStepConcern

included

Instance Method Details

#is_eftObject



12
13
14
# File 'lib/starkit_banking/concerns/payment.rb', line 12

def is_eft
  self.transfer_type != 'IMT'
end

#is_imtObject



8
9
10
# File 'lib/starkit_banking/concerns/payment.rb', line 8

def is_imt
  self.transfer_type == 'IMT'
end

#release(opts = {}) ⇒ Object



16
17
18
19
20
21
22
23
# File 'lib/starkit_banking/concerns/payment.rb', line 16

def release(opts = {})
  self..instance_variable_set(:@password, opts[:api_password])
  self.environment = self..environment
  self.updated_by = opts[:current_user_id]
  self.approve
  self.reference_no = self.id
  self.response = StarkitBanking::API::Factory.get_client(self).exec(self)
end

#sync_status(opts = {}) ⇒ Object



25
26
27
28
# File 'lib/starkit_banking/concerns/payment.rb', line 25

def sync_status(opts = {})
  self..instance_variable_set(:@password, opts[:api_password])
  self.response = StarkitBanking::API::Factory.get_client(self, 'GetStatus').exec(self)
end