[英]how to integrate Paynimo payment gateway in objective c?
1)您需要從Techprocess獲取UTA和Live Paynimo SDK。
項目名稱:MerchantSampleApp
導入標題:導入
將空白應用程序創建為:
將Windows背景顏色設置為白色。
2)將PayminoStyle.h和.m文件添加到項目中。
3)框架集成:
目標->構建階段->使用庫鏈接二進制文件->單擊(+)->添加其他-> Paynimolib.framework
當框架添加到項目中時
添加其他庫
MessageUI.framework
MobileCoreServices.framework
SystemConfiguration.framework
CFNetwork.framework
安全框架
基礎框架
CoreGraphics.framework
UIKit.framework
AVFoundation.framework
AudioToolbox.framework
CoreMedia.framework
MobileCoreServices.framework
目標->構建設置->其他鏈接器標志設置值“ -ObjC”,“-lstdc ++”,“-lc ++”
4)捆綁集成:•目標->構建階段->復制捆綁資源->單擊(+)->添加其他-> Paynimolib.bundle
用於掃描卡
5)在CheckoutViewController中實現功能
然后添加一個按鈕,
- (IBAction)payBtnTap:(id)sender {
Checkout *checkoutObj = [Checkout new];
//Merchant
[checkoutObj setMerchantIdentifier:@"MerchantIdentifier"];//you need to get from techprocess
[checkoutObj setPaymentTransactionIdentifier:@"TXN001234"];
[checkoutObj setPaymentTransactionReference:@"ORD0001"];
[checkoutObj setPaymentTransactionType:@"SALE"];
[checkoutObj setPaymentTransactionSubType:@"DEBIT"];
[checkoutObj setPaymentTransactionCurrency:@"INR"];
[checkoutObj setPaymentTransactionAmount:@"1.0"];
[checkoutObj setPaymentTransactionDateTime:@"24-11-2016"];
//Consumer
[checkoutObj setConsumerIdentifier:@"appusername"];
[checkoutObj setConsumerEmailID:@"appuser@gmail.com"];
[checkoutObj setConsumerMobileNumber:@"mobilenumber"];
[checkoutObj setConsumerAccountNumber:@""];
[checkoutObj addCartItem:@"Top" amount:@"1.0" SurchargeOrDiscount:@"0.0" SKU:@"com.companyname.yourappname" Description:@"" ProviderID:@"yourcompanyidfrom techprocess" Reference:@"Test" CommisionAmt:@""];
PMPaymentOptionView *payView = [[PMPaymentOptionView alloc] initWithPublicKey:@"MerchantIdentifier" checkout:checkoutObj paymentType:@"Netbanking" success:^(id resObject ) {
NSLog(@"%@",resObject);
} failure:^(NSDictionary *failDict) {
NSLog(@"%@",failDict);
} cancel:^{
}];
[self.navigationController presentViewController:payView animated:YES completion:nil];
}
希望這會有所幫助。 並參考UTA和Live PaynimoSDK文檔。 這是用於網上銀行的過程。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.