From bb46b5bc1acc918bff9eab3e81976667920c7cc1 Mon Sep 17 00:00:00 2001 From: Jacob Rief Date: Tue, 7 Feb 2017 17:26:29 +0100 Subject: [PATCH] added missing settings --- README.md | 45 ++++++++++++++++++++++++++++++++++++--------- 1 file changed, 36 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 8866266..86d2da5 100644 --- a/README.md +++ b/README.md @@ -1,25 +1,52 @@ # REST based PayPal Payment Provider Integration for django-shop -This integration only works for django-shop version 0.3 and above. - +This integrates the PayPal for django-shop version 0.9 and above. ## Installation -In ``settings.py`` add ``'shop_paypal'`` to ``INSTALLED_APPS``. +for django-shop version 0.9.x: + +``` +pip install djangoshop-paypal==0.1.4 +``` + +for django-shop version 0.10.x: + +``` +pip install djangoshop-paypal==0.2.0 +``` + +## Configuration + +In ``settings.py`` of the merchant's project: + +Add ``'shop_paypal'`` to ``INSTALLED_APPS``. + +At [PayPal](https://paypal.com/) create a business account and apply for the vendor credentials. +For a testing account add them as: + +``` +SHOP_PAYPAL = { + 'API_ENDPOINT': 'https://api.sandbox.paypal.com', + 'MODE': 'sandbox', + 'CLIENT_ID': '', + 'CLIENT_SECRET': '', +} +``` -In ``settings.py`` add +and for production: ``` SHOP_PAYPAL = { - 'API_ENDPOINT': 'https://api.sandbox.paypal.com', # or 'https://api.paypal.com' - 'MODE': 'sandbox', # 'sandbox' or 'live' + 'API_ENDPOINT': 'https://api.paypal.com', + 'MODE': 'live', 'CLIENT_ID': '', 'CLIENT_SECRET': '', } ``` -In ``settings.py`` add ``'shop_paypal.payment.PaymentModifier'`` to ``SHOP_CART_MODIFIERS``. +Add ``'shop_paypal.modifiers.PaymentModifier'`` to the list of ``SHOP_CART_MODIFIERS``. -In ``settings.py`` add ``'shop_paypal.payment.OrderWorkflowMixin'`` to ``SHOP_ORDER_WORKFLOWS``. +Add ``'shop_paypal.payment.OrderWorkflowMixin'`` to the list of ``SHOP_ORDER_WORKFLOWS``. -This will add a list item for PayPal to the select fields, when chosing the payment method. +When rendering the payment method form, "PayPal" shall appear in the list of possible payments.