當前位置: 首頁>>代碼示例>>Python>>正文


Python PaymentProcessor.get_backend_setting方法代碼示例

本文整理匯總了Python中getpaid.backends.transferuj.PaymentProcessor.get_backend_setting方法的典型用法代碼示例。如果您正苦於以下問題:Python PaymentProcessor.get_backend_setting方法的具體用法?Python PaymentProcessor.get_backend_setting怎麽用?Python PaymentProcessor.get_backend_setting使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在getpaid.backends.transferuj.PaymentProcessor的用法示例。


在下文中一共展示了PaymentProcessor.get_backend_setting方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: handle

# 需要導入模塊: from getpaid.backends.transferuj import PaymentProcessor [as 別名]
# 或者: from getpaid.backends.transferuj.PaymentProcessor import get_backend_setting [as 別名]
    def handle(self, *args, **options):

        key = PaymentProcessor.get_backend_setting("key", None)
        if key is None:
            self.stdout.write('Please be sure to provide "key" setting for this backend (random max. 16 characters)')
        else:
            self.stdout.write("Please setup in Transferuj.pl user defined key (for security signing): %s\n" % key)
開發者ID:giam-forte,項目名稱:ExpertBilling,代碼行數:9,代碼來源:transferuj_configuration.py

示例2: test_default_config_url_transaction_params

# 需要導入模塊: from getpaid.backends.transferuj import PaymentProcessor [as 別名]
# 或者: from getpaid.backends.transferuj.PaymentProcessor import get_backend_setting [as 別名]
    def test_default_config_url_transaction_params(self):
        data = self.get_geteway_data()

        crc = data['crc']
        kwota = data['kwota']
        id_ = data['id']
        key = PaymentProcessor.get_backend_setting('key')
        md5sum = six.text_type(id_) + kwota + six.text_type(crc) + key
        md5sum = md5sum.encode('utf-8')

        self.assertEquals(crc, self.payment.pk)
        self.assertEquals(kwota, six.text_type(self.payment.amount))
        self.assertEquals(id_, 1234)
        self.assertEquals(data['md5sum'], md5(md5sum).hexdigest())
開發者ID:dcondeurra,項目名稱:django-getpaid,代碼行數:16,代碼來源:test_transferuj.py


注:本文中的getpaid.backends.transferuj.PaymentProcessor.get_backend_setting方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。