From 93bbd897739992fd1a80f18b27e667c599e439e7 Mon Sep 17 00:00:00 2001 From: "Francisco J. Seva" Date: Mon, 23 Jul 2018 12:59:10 +0200 Subject: [PATCH] Issue31 add README.md file --- paypal_sdk/README.md | 46 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 paypal_sdk/README.md diff --git a/paypal_sdk/README.md b/paypal_sdk/README.md new file mode 100644 index 0000000..20e847c --- /dev/null +++ b/paypal_sdk/README.md @@ -0,0 +1,46 @@ +# Drupal Paypal Recurring Payment + + +## Installation + +First you need to [install composer](https://getcomposer.org/doc/00-intro.md#installation-linux-unix-osx) + + + +1) Add dependency to composer.json file. + ``` + "capynet/DrupalPayPalRecurrringPayment": { + "type": "package", + "package": { + "name": "capynet/DrupalPayPalRecurrringPayment", + "version": "dev-1.x", + "type": "drupal-module", + "source": { + "url": "https://github.com/capynet/DrupalPayPalRecurrringPayment.git", + "type": "git", + "reference": "master" + } + } + } + ``` +2) Once the module is installed DrupalPayPalRecurrringPayment dependency will need to be installed. + + cd paypal_sdk + composer install + + +After execute **composer install** paypal/rest-api-sdk-php will be added to vendor folder. + + +### Notes + +####Taxes +The tax is being hardcoded and it seems it is not being used. We still need to improve the code. + + ``` + $chargeModel->setType('TAX') + ->setAmount(new Currency(array( + 'value' => $data['payment_amount'] * .21, + 'currency' => $data['payment_currency'] + ))); + ```