2

こんにちは、みんな、

    I need to integrate paypal guest payment via credit card.


私が知る限り、android ペイパル SDK では、ペイパル アカウント経由で支払うことができます。


私が検索した結果、それを達成するにはアダプティブ ペイメントが必要になりますが、それで成功することはありませんでした。

それで、あなたの誰かが何らかの助けを提供できますか.........?

4

2 に答える 2

2

Paypal はクレジット カードによる支払いにアクセスできますが、現在は廃止されています。

于 2016-12-20T07:38:27.843 に答える
0

Android PayPal アダプティブ ペイメント インテグレーション

first implement method
   private void initLibrary() {
        PayPal pp = PayPal.getInstance();
        if(pp == null) {
            pp = PayPal.initWithAppID(this, PAYPAL_APP_ID, PayPal.ENV_SANDBOX);
            pp.setLanguage("en_US"); // Sets the language for the library.
            pp.setFeesPayer(PayPal.FEEPAYER_EACHRECEIVER);
//            pp.setShippingEnabled(true);
            pp.setDynamicAmountCalculationEnabled(false);
        }
    }    

===================================

**paypal button click event code**

     double secondary_payment = 0;
    double primary_payment = 0;

      PayPalAdvancedPayment advPayment = makeChainedPayment(secondary_payment,primary_payment,"primary_email","secondary_email");

      Intent checkoutIntent = PayPal.getInstance().checkout(advPayment, your_current_activity);
                    startActivityForResult(checkoutIntent, 1); 

    =============================================
    private PayPalAdvancedPayment makeChainedPayment(double priceSecondary, double pricePrimary, String primary_email, String secondary_email) {
            PayPalAdvancedPayment payment = new PayPalAdvancedPayment();
            payment.setCurrencyType("USD");
    //        payment.setMerchantName("PushND");
            BigDecimal bigDecimalPrimary=new BigDecimal(pricePrimary);
            PayPalReceiverDetails receiverPrimary = new PayPalReceiverDetails();
            receiverPrimary.setRecipient(primary_email);
            //receiverPrimary.setRecipient("adaptive_receiver_1@pushnd.com");
            receiverPrimary.setSubtotal(bigDecimalPrimary);
            receiverPrimary.setIsPrimary(true);
            payment.getReceivers().add(receiverPrimary);

            PayPalReceiverDetails receiverSecondary= new PayPalReceiverDetails();
            receiverSecondary.setRecipient(secondary_email);
            BigDecimal bigDecimalSecond=new BigDecimal(priceSecondary);
            receiverSecondary.setSubtotal(bigDecimalSecond);
            payment.getReceivers().add(receiverSecondary);

            return payment;
        }
于 2016-04-28T05:19:02.340 に答える