-
-
Notifications
You must be signed in to change notification settings - Fork 282
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add example #328
Comments
Do you have any specific questions? The docs might need improvement, but understanding what's missing would be great.
The |
Thank you for your reply first of all. For the implementation part, I'll use the testapp as a reference. Thank you for the advice. The issue I'm having is with understanding the practical usage of it. Basically, how do I turn the testapp into something that is usable for a e-commerce website with providers forms and redirections ? So far I understood it can make payments and refund them, but the API section is not complete and I believe it's where there were going to be the explanation, I'm thinking of the get_form method for instance. I think for more clarity you should go through the library using the following example : Start with this simple example and then provide link if the user wants to investigate more in a given concept (for instance Paymentclass or redirections, or understanding status) They have a really good documentation here using the same method : |
What's missing? What's the question?
https://django-payments.readthedocs.io/en/latest/api.html#payments.models.BasePayment.get_form What's the questions about it?
This is the flow that's being targeted.
Whether a form is used or the client is redirected to the provider depends on the provider. Some payment mechanisms require redirecting the user to the provider's page and that's what we signal by raising
The provider redirects the client to a URL. You need to define those URLs yourself, as described here: https://django-payments.readthedocs.io/en/latest/payment-model.html#create-a-payment-class |
Did you follow the docs through the Installation and Payment class steps?
|
Sorry for the delete it was not properly worded.
I finally understood this part as it didn't get it the first time. I just have one last question regarding payment forms. Where can I get the list of the payment methods that do not provide a form. Because if it's risky, I'd rather not implement them. If you do not have it, it's perfectly fine, Trial and error will suffice. Sadly, yes I did read it and probably 10 times through, there are still some obscure areas i'd like you to enlighten me about. Just so you know, Installation is crystal clear, the issue I'm having is with the payment part. And lastly as you probably guessed it, I'm not expert about web developpement, I do other stuff, so pardon my lack of understanding. So I want to thank you for taking the time give further explanation, and apologize for the passive/aggressiveness in the previous comments. I was pissed as I've been trying to make it work for an entire week, and still can't understand it totally. So the part i'm struggling with is making a payment : How I believe payment work when using an payment API generally speaking : Create a payment object > Submit it to the provider > Wait for response status (Payment confirmation or payment refusal) > Redirect What I understand from the documentation https://django-payments.readthedocs.io/en/latest/usage.html : Create a payment object > Redirect to payment_view > Then it speaks about payment total amount (probably to inform the user that you can check the total) >Then it explains that Payment may have some status (waiting being the default status). > I'm assuming that get_successful/failure_url(self) then Redirect So I have question on this part :
Thank you for your time btw. |
There's no such list. I guess one would be very useful for the docs; a table of providers and the supported functionality of each.
You're close:
When the user is redirected back, they're redirected to one of the views that django-payments requires that you expose. This view will handle any details that the payment provider has passed back via this request, update the
You should only read the
Failed payments are not deleted; they're set to the correct status (
The I am now realising that this signal has zero documentation.. |
|
I've added some docstrings that should answer this doubt: https://github.com/jazzband/django-payments/pull/392/files
|
I've been trying to implement django-payments but so far the documentation is not helpful.
A simple implementation example would solve the matter if it's possible.
It seems that both the documentation and the issues tend to be directed only at contributors, which makes it impossible to understand for outsiders.
Please document it properly
Thank you
The text was updated successfully, but these errors were encountered: