Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I am trying to create a payment method where no payment is required. Customer will pay on delivery. So, I need to confirm sales when pay now is created. I have written following codes -
_inherit = 'payment.acquirer'
def _get_providers(self, cr, uid, context=None):
providers = super(payment_acquirer_extend, self)._get_providers(cr, uid, context=context)
providers.append(['cash', _('Cash on Delivery')])
def transfer_get_form_action_url(self, cr, uid, id, context=None):
def create(self, cr, uid, values, context=None):
if values.get('provider') == 'cash' and not values.get('post_msg'):
values['post_msg'] = 'CASH DELIVERY'
return super(payment_acquirer_extend, self).create(cr, uid, values, context=context)
Now I understand I have to write following function:
How to do that and if I click on pay now button it doesn't work?
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 11/20/16, 7:54 AM|
|Seen: 830 times|
|Last updated: 11/20/16, 8:37 AM|