summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-05-05 13:29:14 +0000
committerCoprDistGit <infra@openeuler.org>2023-05-05 13:29:14 +0000
commitd21d7c7d70879791796f2cd597e60d12bce48138 (patch)
treeefbd2e43687114f24e3b3cbd93792085155fadc1
parentbdb8cb75d564f1180d1cbdc663bfcec3031f6254 (diff)
automatic import of python-ax3-mercadopagoopeneuler20.03
-rw-r--r--.gitignore1
-rw-r--r--python-ax3-mercadopago.spec363
-rw-r--r--sources1
3 files changed, 365 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..1793fc7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/AX3%20Mercadopago-0.3.7.tar.gz
diff --git a/python-ax3-mercadopago.spec b/python-ax3-mercadopago.spec
new file mode 100644
index 0000000..dbc59f3
--- /dev/null
+++ b/python-ax3-mercadopago.spec
@@ -0,0 +1,363 @@
+%global _empty_manifest_terminate_build 0
+Name: python-AX3-Mercadopago
+Version: 0.3.7
+Release: 1
+Summary: A Django app to add support for Mercadopago payments
+License: MIT License
+URL: https://github.com/Axiacore/ax3-mercadopago
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/0e/fe/3a50359bf884e7b4d0f168f367612c52935e6c2d20ce5e222bd78b4ad28d/AX3%20Mercadopago-0.3.7.tar.gz
+BuildArch: noarch
+
+Requires: python3-django
+Requires: python3-pymercadopago
+Requires: python3-dateutil
+
+%description
+# AX3 Mercadopago
+
+AX3 Mercadopago A Django app to add support for Mercadopago payments.
+
+## Installation
+
+AX3 Mercadopago is easy to install from the PyPI package:
+
+ $ pip install ax3-mercadopago
+
+After installing the package, the project settings need to be configured.
+
+Add ``ax3_mercadopago`` to your ``INSTALLED_APPS``
+
+```python
+INSTALLED_APPS = [
+ 'django.contrib.admin',
+ 'django.contrib.auth',
+ 'django.contrib.contenttypes',
+ 'django.contrib.sessions',
+ 'django.contrib.messages',
+ 'django.contrib.staticfiles',
+
+ # ax3_mercadopago app can be in any position in the INSTALLED_APPS list.
+ 'ax3_mercadopago',
+]
+```
+
+## Configuration
+
+Add mercadopago settings
+
+```python
+# app/settings.py
+
+MERCADOPAGO_REFERENCE_PREFIX = '' # Prefix for Mercadopago external reference
+MERCADOPAGO_PAYMENT_MODEL = '' # Path to payment model
+MERCADOPAGO_PAID_USECASE = '' # Path to use case for paid payments
+MERCADOPAGO_REJECTED_USECASE = '' # Path to use case for rejected payments
+
+# For Marketplace
+# https://www.mercadopago.com.co/developers/es/guides/online-payments/marketplace/checkout-pro/introduction
+MERCADOPAGO_MARKETPLACE_SELLER = True
+MERCADOPAGO_MARKETPLACE_APP_ID = ''
+MERCADOPAGO_MARKETPLACE_REDIRECT_URI = ''
+```
+
+Set ax3_mercadopago in app urls
+
+```python
+# app/urls.py
+urlpatterns = [
+ path('admin/', admin.site.urls),
+
+ # Add this line
+ path('mercadopago/', include('ax3_mercadopago.urls', namespace='mercadopago')),
+]
+```
+
+Use ``PaymentModelMixin`` in your payment model
+
+```python
+class Payment(PaymentModelMixin):
+```
+
+## Utils
+
+### Get seller token request uri, on shell_plus
+```python
+from ax3_mercadopago.api import AX3Client
+
+mp = AX3Client()
+mp.marketplace_tokens.get_auth_uri()
+# response
+https://auth.mercadopago.com.co/authorization?client_id=&redirect_uri=https%3A%2F%2Fclientes-staging.takami.co&response_type=code&platform_id=mp
+```
+
+### To create Seller Token, on shell_plus use
+```python
+from app.mercadopago import create_seller_token
+
+brand = Brand.objects.first()
+create_seller_token(code='SELLER-CODE', brand=brand)
+```
+
+
+## Releasing a new version
+
+Make sure you increase the version number and create a git tag:
+
+```
+$ python3 -m pip install --user --upgrade setuptools wheel twine
+$ ./release.sh
+```
+
+
+
+
+%package -n python3-AX3-Mercadopago
+Summary: A Django app to add support for Mercadopago payments
+Provides: python-AX3-Mercadopago
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-AX3-Mercadopago
+# AX3 Mercadopago
+
+AX3 Mercadopago A Django app to add support for Mercadopago payments.
+
+## Installation
+
+AX3 Mercadopago is easy to install from the PyPI package:
+
+ $ pip install ax3-mercadopago
+
+After installing the package, the project settings need to be configured.
+
+Add ``ax3_mercadopago`` to your ``INSTALLED_APPS``
+
+```python
+INSTALLED_APPS = [
+ 'django.contrib.admin',
+ 'django.contrib.auth',
+ 'django.contrib.contenttypes',
+ 'django.contrib.sessions',
+ 'django.contrib.messages',
+ 'django.contrib.staticfiles',
+
+ # ax3_mercadopago app can be in any position in the INSTALLED_APPS list.
+ 'ax3_mercadopago',
+]
+```
+
+## Configuration
+
+Add mercadopago settings
+
+```python
+# app/settings.py
+
+MERCADOPAGO_REFERENCE_PREFIX = '' # Prefix for Mercadopago external reference
+MERCADOPAGO_PAYMENT_MODEL = '' # Path to payment model
+MERCADOPAGO_PAID_USECASE = '' # Path to use case for paid payments
+MERCADOPAGO_REJECTED_USECASE = '' # Path to use case for rejected payments
+
+# For Marketplace
+# https://www.mercadopago.com.co/developers/es/guides/online-payments/marketplace/checkout-pro/introduction
+MERCADOPAGO_MARKETPLACE_SELLER = True
+MERCADOPAGO_MARKETPLACE_APP_ID = ''
+MERCADOPAGO_MARKETPLACE_REDIRECT_URI = ''
+```
+
+Set ax3_mercadopago in app urls
+
+```python
+# app/urls.py
+urlpatterns = [
+ path('admin/', admin.site.urls),
+
+ # Add this line
+ path('mercadopago/', include('ax3_mercadopago.urls', namespace='mercadopago')),
+]
+```
+
+Use ``PaymentModelMixin`` in your payment model
+
+```python
+class Payment(PaymentModelMixin):
+```
+
+## Utils
+
+### Get seller token request uri, on shell_plus
+```python
+from ax3_mercadopago.api import AX3Client
+
+mp = AX3Client()
+mp.marketplace_tokens.get_auth_uri()
+# response
+https://auth.mercadopago.com.co/authorization?client_id=&redirect_uri=https%3A%2F%2Fclientes-staging.takami.co&response_type=code&platform_id=mp
+```
+
+### To create Seller Token, on shell_plus use
+```python
+from app.mercadopago import create_seller_token
+
+brand = Brand.objects.first()
+create_seller_token(code='SELLER-CODE', brand=brand)
+```
+
+
+## Releasing a new version
+
+Make sure you increase the version number and create a git tag:
+
+```
+$ python3 -m pip install --user --upgrade setuptools wheel twine
+$ ./release.sh
+```
+
+
+
+
+%package help
+Summary: Development documents and examples for AX3-Mercadopago
+Provides: python3-AX3-Mercadopago-doc
+%description help
+# AX3 Mercadopago
+
+AX3 Mercadopago A Django app to add support for Mercadopago payments.
+
+## Installation
+
+AX3 Mercadopago is easy to install from the PyPI package:
+
+ $ pip install ax3-mercadopago
+
+After installing the package, the project settings need to be configured.
+
+Add ``ax3_mercadopago`` to your ``INSTALLED_APPS``
+
+```python
+INSTALLED_APPS = [
+ 'django.contrib.admin',
+ 'django.contrib.auth',
+ 'django.contrib.contenttypes',
+ 'django.contrib.sessions',
+ 'django.contrib.messages',
+ 'django.contrib.staticfiles',
+
+ # ax3_mercadopago app can be in any position in the INSTALLED_APPS list.
+ 'ax3_mercadopago',
+]
+```
+
+## Configuration
+
+Add mercadopago settings
+
+```python
+# app/settings.py
+
+MERCADOPAGO_REFERENCE_PREFIX = '' # Prefix for Mercadopago external reference
+MERCADOPAGO_PAYMENT_MODEL = '' # Path to payment model
+MERCADOPAGO_PAID_USECASE = '' # Path to use case for paid payments
+MERCADOPAGO_REJECTED_USECASE = '' # Path to use case for rejected payments
+
+# For Marketplace
+# https://www.mercadopago.com.co/developers/es/guides/online-payments/marketplace/checkout-pro/introduction
+MERCADOPAGO_MARKETPLACE_SELLER = True
+MERCADOPAGO_MARKETPLACE_APP_ID = ''
+MERCADOPAGO_MARKETPLACE_REDIRECT_URI = ''
+```
+
+Set ax3_mercadopago in app urls
+
+```python
+# app/urls.py
+urlpatterns = [
+ path('admin/', admin.site.urls),
+
+ # Add this line
+ path('mercadopago/', include('ax3_mercadopago.urls', namespace='mercadopago')),
+]
+```
+
+Use ``PaymentModelMixin`` in your payment model
+
+```python
+class Payment(PaymentModelMixin):
+```
+
+## Utils
+
+### Get seller token request uri, on shell_plus
+```python
+from ax3_mercadopago.api import AX3Client
+
+mp = AX3Client()
+mp.marketplace_tokens.get_auth_uri()
+# response
+https://auth.mercadopago.com.co/authorization?client_id=&redirect_uri=https%3A%2F%2Fclientes-staging.takami.co&response_type=code&platform_id=mp
+```
+
+### To create Seller Token, on shell_plus use
+```python
+from app.mercadopago import create_seller_token
+
+brand = Brand.objects.first()
+create_seller_token(code='SELLER-CODE', brand=brand)
+```
+
+
+## Releasing a new version
+
+Make sure you increase the version number and create a git tag:
+
+```
+$ python3 -m pip install --user --upgrade setuptools wheel twine
+$ ./release.sh
+```
+
+
+
+
+%prep
+%autosetup -n AX3-Mercadopago-0.3.7
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-AX3-Mercadopago -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Fri May 05 2023 Python_Bot <Python_Bot@openeuler.org> - 0.3.7-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..b56267a
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+6f4c0b6e3268becb567c860db09086d7 AX3%20Mercadopago-0.3.7.tar.gz