Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
1 Rispondi
3119 Visualizzazioni

I'm have a problem when I don't get any data in my controller. An external data is sending POST request to my controller but I don't get the data. The external service sends an XML.


My controller

@http.route(['/payment/ack/callback/'], methods=['POST'], auth='none', csrf=False)
def ack_callback(self, **post):
	_logger.error(u'DEBUG: Callback post: {}'.format(post))
	# request.env['payment.transaction'].sudo().form_feedback(post, 'ack')
	return werkzeug.utils.redirect('/payment/process')

Is it maybe in the http.request?





Avatar
Abbandona
Autore Risposta migliore

The data is stored in odoo http request object. Found it when run with debug.

from odoo.http import request

print(request.httprequest.data)


Avatar
Abbandona
Post correlati Risposte Visualizzazioni Attività
3
nov 21
2936
2
dic 19
3966
2
ago 25
2700
2
giu 25
1187
3
lug 24
3932