Hi all,
I am a bit new on django and just would like to make sure my
understanding is good before I go on integrating payments on my app.
1-PAYPAL_DICT
paypal_dict{
"invoice":"unique"
}
I am thinking of modeling it as {{
client.pk}}+"-"+
{{client.order.number}}+"-"+{{other_bla_bla"}}
I hope this number comes back to me from paypal by a signal and that I
can parse this numbers and process my order.
Am I right?
I Understand that "notify_url" is the url for signals, and
"return_url" is the url where the client will be
redirected from paypal to my site after paying, correct?
Can I add other keys to this dictionnary
( "my_custom_data_to_recover_later":"this_data")?
2-IPN and SIGNALS PROCESSING
if i get it right, django-paypal handles IPN by itself, all I have to
do is connect the signals to functions and do what I have to do when I
am signaled. Practically :
#models.py
payment_was_successful.connect(process_successfull_payment)
payment_was_flagged.connect(process_flagged_payment)
#views.py
def process_successfull_payment(sender, **kwargs):
blabla
def process_flagged_payment(sender, **kwargs):
blibli
Is that the correct way to handle the signals ?
What will I find in sender anf **kwargs ? the initial dictionary ?
can I even pull anything form **kwargs ?
3-Payment Button
When I opened my Paypal account I was able to configure a custom
button. is there a way I can recover it?
(my site is in French and the paypal button saying "Buy" is not really
convinient)
I know it is a lot of questions but hopefully most of the answers will
be "correct" ;)
Thanks in advance
A.