drupalpaypalrecurrringpayment's People
drupalpaypalrecurrringpayment's Issues
Define and setup the permissions
The basics are:
- Manage plans (for the managers. alloe ABM plans)
- Allow subscription (for the field. only prints if the rol has the perm)
Add the config link for the module configuration at admin/modules
Exclude paypal credential as an exportable
Delete all agreemens of a person when its account gets deleted
We dont want a user gets a charge next year if it deleted it's account.
Decopule user creation from the main module
The task of the main module is allow visitors subscribe to a paypal plan but what to do when the job is done should be tacked by contrib modules (or submodules in this case)
Make the module compatible with composer
- The module needs to be able to be added as dependency on a project via composer require drupal/OURMODULE
- The module itself needs a composer.json with "paypal/rest-api-sdk-php" as dependency.
Created plans are storing the current URL of the site
And this is a problem since I can install a new drupal with bar.com and if a plan been created at foo.com and I want use it at bar.com, the ok and ko URLs will be pointing to foo.com.
We need to check if the available plans should be filtered by site (from the drupal side) or if the plans (any plan) can be used on any site changing the URLs on the fly.
Allow user to unsubscribe
Im not sure about the best implementation for this. As a extra field for the user entity maybe?
Implement the agreement field formatter
Must print:
- Agreement name
- Payment cycle date.
- Amount
- Cancel button.
Create Agreements list
Add Set status action to plans
Deprecate all entities layer
Add a response message or URL when the user agreed or cancelled the deal
Use case: The user approves or cancel the agreement at paypal. Paypal will return the response to static process urls BUT we need to decide what to do after the processing.
We need to add to the config area (/admin/config/system/paypal-sdk) the possibility to redirect a user to an url and optionally show a message.
If you try to edit an active plan will not get saved
Check if paypal_subscribe_field_type really is capable to render multivalued contents
Add a field multivalued and add 2 or more plans to a content. Chack if 2 or more links gets printed.
Prevent errors at the paypal section for the lack of credentials
If you still did not setted up the credentials and try to enter to admin/store/billing-plan/list will get a PHP error.
We need to check if the user entered the credentials and if not, show a message indicating the need to setup them.
Create a config page for the paypal credentials
Falta una pantalla en al cual se pueda poner la api key y el secret. Ahora mismo los tengo hardcoded en paypal_sdk.services.yml
Add README.md and update README.txt
A README.md is needed with information about how use the module. We also should update README.txt file.
Create tests
Link the user to the apprved agreement.
Whe the user accepts the agreement we are processing the response at PaypalSDKController->processResponse()
We create a new account for the user if it does not exist or use an existing accound (we search it via the paypal's email matching).
BUT we are not persisting the agreement to use it at the user profile. Thats what we need to implement here.
Fix/Complete paypal field (remove entity dependency)
Modify the main service to allow to read the credentials from the system config
Add a new setting option
To allow select between test and live.
And implement this code
$this->apiContext->setConfig(
array(
'mode' => 'live',
)
);
If I subscribe more than once I only see the last subscription.
If an agreement field gets deleted, the related agreements should be moved to the default agreement field
Verify how to act if the plan changes.
Te plan changes and:
User cases:
- The user is subscribed. What happend. His plan gets updated or supended (see paypal documentation)
- The user is have a suspended subscription. What happend. His plan gets will be updated when it gets enabled or he/she must subscribe to a new plan? (see paypal documentation)
Add cache to paypal_subscribe_field_formatter
The url comes from BillingAgreement->getUserAgreementLink() and we should cache the api call since the link is always the sam (at plan level. If the plan is another one the link is different).
The default billing field (on the user) should not be deletable.
I didn't checked out but just want to be sure the admin user cant delete the default created agreement field.
Check response [processResponse()]
For:
- Anonymous but really existent user.
- Anonymous but non existent user.
- Logged in user.
And both 3 cases but with existing subscriptions (can be of the same plan or a different plan).
Make plan form more conditional
Review the form logic. for example If you select infinite "Plan type" then "Payment cycles" should not be shown as an option.
Show agreement details
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.