Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/iphone/38.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Braintree iOS集成_Ios_Iphone_Swift_Payment Gateway_Braintree - Fatal编程技术网

Braintree iOS集成

Braintree iOS集成,ios,iphone,swift,payment-gateway,braintree,Ios,Iphone,Swift,Payment Gateway,Braintree,我正在尝试在iOS中实现支付。我在你的帮助下尝试了你的沙盒测试 在添加了4111111111卡号后,我完全失明了,接下来该怎么办? 现在,我没有任何服务器 问题: 4111111111卡的有效期是什么时候 2增加卡片点击后,下一步应该做什么来完成交易 3成功交易是否需要自己的服务器 谢谢,我试过用Swift,它对我很好。我附上了下面的代码检查并让我知道: var braintree: Braintree? braintree = Braintree(clientToken: "

我正在尝试在iOS中实现支付。我在你的帮助下尝试了你的沙盒测试

在添加了4111111111卡号后,我完全失明了,接下来该怎么办? 现在,我没有任何服务器

问题:

4111111111卡的有效期是什么时候

2增加卡片点击后,下一步应该做什么来完成交易

3成功交易是否需要自己的服务器


谢谢,

我试过用Swift,它对我很好。我附上了下面的代码检查并让我知道:

    var braintree: Braintree?
     braintree = Braintree(clientToken: "")



    func userDidCancelPayment() {
        self.dismiss(animated: true, completion: nil)
    }

    func drop(_ viewController: BTDropInViewController!, didSucceedWith paymentMethod: BTPaymentMethod!) {

        print(paymentMethod.nonce)

        // Send payment method nonce to your server

        dismiss(animated: true, completion: nil)
        let alert = UIAlertController(title: "Alert", message: "Send payment method nonce to your server Sucessfully", preferredStyle: UIAlertControllerStyle.alert)
        alert.addAction(UIAlertAction(title: "Ok", style: UIAlertActionStyle.default, handler: nil))
        self.present(alert, animated: true, completion: nil)

    }

 func tappedMyPayButton() 
{
 let dropInViewController = braintree!.dropInViewController(with: self)
        dropInViewController.navigationItem.leftBarButtonItem = UIBarButtonItem(barButtonSystemItem: UIBarButtonSystemItem.cancel, target: self, action: #selector(PaymentVController.userDidCancelPayment))

        let navigationController = UINavigationController(rootViewController: dropInViewController)
        self.present(navigationController, animated: true, completion: nil)
    }



    func drop(inViewControllerDidCancel viewController: BTDropInViewController!) {
        dismiss(animated: true, completion: nil)
    }  
签证:424242 万事达卡:55555555554444 美国运通:3782 822463 10005 重要提示:在测试模式下使用任何未来的到期日期、卡上姓名、CVC和计费Zip