lib/active_merchant/billing/gateways/cyberpac/cyberpac.rb
# TODO: implement recurring payments case TRANSACTIONS[:recurring]
implement recurring payments case TRANSACTIONS[:recurring]
implement recurring payments case TRANSACTIONS [ : recurring ]
def signature(transaction, amount, creditcard, order_id, options = {})
          currency = options[:currency] || self.class.default_currency
          transaction_code = TRANSACTIONS[transaction]
          ary = [ amount, order_id, @options[:merchant_code], currency,
                  creditcard.number, creditcard.verification_value, transaction_code,
                  @options[:secret_key]
                ].compact
          Digest::SHA1.hexdigest(ary.map(&:to_s).join(''))
        end
def signature ( transaction , amount , creditcard , order_id , options = { } ) currency = options [ :currency ] || self . class . default_currency transaction_code = TRANSACTIONS [ transaction ] ary = [ amount , order_id , @options [ :merchant_code ] , currency , creditcard . number , creditcard . verification_value , transaction_code , @options [ :secret_key ] ] . compact Digest :: SHA1 . hexdigest ( ary . map ( & :to_s ) . join ( '' ) ) end
TODO: implement recurring payments case TRANSACTIONS[:recurring]
TODO : implement recurring payments case TRANSACTIONS [ : recurring ]
# NOTE: the order is important, affects the result digest
transaction
<not_specific>
amount
<not_specific>
creditcard
<not_specific>
order_id
<not_specific>
options
<not_specific>