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


Python KycDocument.Type方法代碼示例

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


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

示例1: test_Users_CreateKycPage_CorrectFilePath

# 需要導入模塊: from mangopaysdk.entities.kycdocument import KycDocument [as 別名]
# 或者: from mangopaysdk.entities.kycdocument.KycDocument import Type [as 別名]
    def test_Users_CreateKycPage_CorrectFilePath(self) :
        user = self.getJohn()
        kycDocumentInit = KycDocument()
        kycDocumentInit.Status = KycDocumentStatus.CREATED
        kycDocumentInit.Type = KycDocumentType.IDENTITY_PROOF
        kycDocument = self.sdk.users.CreateUserKycDocument(kycDocumentInit, user.Id)

        self.sdk.users.CreateKycPageFromFile(user.Id, kycDocument.Id, os.path.join(os.path.dirname(__file__), "TestKycPageFile.png"))
開發者ID:Homeloc,項目名稱:mangopay2-python-sdk,代碼行數:10,代碼來源:testapiusers.py

示例2: create

# 需要導入模塊: from mangopaysdk.entities.kycdocument import KycDocument [as 別名]
# 或者: from mangopaysdk.entities.kycdocument.KycDocument import Type [as 別名]
 def create(self, tag=''):
     document = KycDocument()
     document.Tag = tag
     document.Type = DOCUMENT_TYPE_CHOICES_DICT[self.type]
     client = get_mangopay_api_client()
     created_document = client.users.CreateUserKycDocument(
         document, self.mangopay_user.mangopay_id)
     self.mangopay_id = created_document.Id
     self.status = STATUS_CHOICES_DICT[created_document.Status]
     self.save()
開發者ID:bsvetchine,項目名稱:django-mangopay,代碼行數:12,代碼來源:models.py

示例3: test_Users_CreateKycPage_WrongFilePath

# 需要導入模塊: from mangopaysdk.entities.kycdocument import KycDocument [as 別名]
# 或者: from mangopaysdk.entities.kycdocument.KycDocument import Type [as 別名]
 def test_Users_CreateKycPage_WrongFilePath(self) :
     user = self.getJohn()
     kycDocumentInit = KycDocument()
     kycDocumentInit.Status = KycDocumentStatus.CREATED
     kycDocumentInit.Type = KycDocumentType.IDENTITY_PROOF
     kycDocument = self.sdk.users.CreateUserKycDocument(kycDocumentInit, user.Id)
     
     try:
         self.sdk.users.CreateKycPageFromFile(user.Id, kycDocument.Id, 'notExistFileName.tmp')
     except Exception as exc:
         self.assertTrue(str(exc).find('File not exist') != -1)
開發者ID:Homeloc,項目名稱:mangopay2-python-sdk,代碼行數:13,代碼來源:testapiusers.py

示例4: test_Users_CreateKycPage_EmptyFilePath

# 需要導入模塊: from mangopaysdk.entities.kycdocument import KycDocument [as 別名]
# 或者: from mangopaysdk.entities.kycdocument.KycDocument import Type [as 別名]
 def test_Users_CreateKycPage_EmptyFilePath(self):
     user = self.getJohn()
     kycDocumentInit = KycDocument()
     kycDocumentInit.Status = KycDocumentStatus.CREATED
     kycDocumentInit.Type = KycDocumentType.IDENTITY_PROOF
     kycDocument = self.sdk.users.CreateUserKycDocument(kycDocumentInit, user.Id)
     
     try:
         self.sdk.users.CreateKycPageFromFile(user.Id, kycDocument.Id, '')
     except Exception as exc:
         self.assertEqual(str(exc), 'Path of file cannot be empty')
開發者ID:Homeloc,項目名稱:mangopay2-python-sdk,代碼行數:13,代碼來源:testapiusers.py

示例5: getUserKycDocument

# 需要導入模塊: from mangopaysdk.entities.kycdocument import KycDocument [as 別名]
# 或者: from mangopaysdk.entities.kycdocument.KycDocument import Type [as 別名]
 def getUserKycDocument(self):
     """Creates KycDocument
     return KycDocument 
     """
     if (self._johnsKycDocument == None):
         user = self.getJohn()
         kycDocument = KycDocument()
         kycDocument.Tag = 'test tag 1'
         kycDocument.Type = KycDocumentType.IDENTITY_PROOF
         self._johnsKycDocument = self.sdk.users.CreateUserKycDocument(kycDocument, user.Id)
     return self._johnsKycDocument
開發者ID:ebewe,項目名稱:mangopay2-python-sdk,代碼行數:13,代碼來源:testbase.py

示例6: test_Users_CreateKycPage_CorrectFileString

# 需要導入模塊: from mangopaysdk.entities.kycdocument import KycDocument [as 別名]
# 或者: from mangopaysdk.entities.kycdocument.KycDocument import Type [as 別名]
 def test_Users_CreateKycPage_CorrectFileString(self):
     user = self.getJohn()
     kycDocumentInit = KycDocument()
     kycDocumentInit.Status = KycDocumentStatus.CREATED
     kycDocumentInit.Type = KycDocumentType.IDENTITY_PROOF
     kycDocument = self.sdk.users.CreateUserKycDocument(kycDocumentInit, user.Id)
     kycPage = KycPage()
     kycPage.File = 'dGVzdCB0ZXN0IHRlc3QgdGVzdA=='
     
     kycPageResponse = self.sdk.users.CreateUserKycPage(kycPage, user.Id, kycDocument.Id)
     self.assertEqual(kycPageResponse, None)
開發者ID:depop,項目名稱:mangopay2-python-sdk,代碼行數:13,代碼來源:testapiusers.py


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