[IMP] payment, website_sale, website_payment: unique reference on payment no longer prevent paying
Payment transactions referenceis have a unique constraint which was problematic when a payment was cancelled from the acquirer's page. To stick the to DRY principle, I factorized a method that checks for existing references and happens a numerical suffix if necessary. This was already implemented in website_payment but was moved to payment and used in website_sale.
Showing
- addons/payment/models/payment_acquirer.py 8 additions, 0 deletionsaddons/payment/models/payment_acquirer.py
- addons/website_payment/controllers/main.py 1 addition, 5 deletionsaddons/website_payment/controllers/main.py
- addons/website_sale/controllers/main.py 4 additions, 6 deletionsaddons/website_sale/controllers/main.py
Loading
Please register or sign in to comment