[FIX] payment: portal payment use newly generated reference

- When creating a transaction on the payment page of the portal, the
  transaction reference returned was incorrect.
  This commit return the newly created transaction's reference.
This commit is contained in:
Toufik Benjaa
2018-09-07 10:48:35 +02:00
parent e11c0a45f2
commit b4c72220c7
+1 -1
View File
@@ -118,7 +118,7 @@ class WebsitePayment(http.Controller):
'partner_id': partner_id,
}
return acquirer.sudo().render(reference, float(amount), int(currency_id), values=render_values)
return acquirer.sudo().render(tx.reference, float(amount), int(currency_id), values=render_values)
@http.route(['/website_payment/token/<string:reference>/<string:amount>/<string:currency_id>',
'/website_payment/token/v2/<string:amount>/<string:currency_id>/<path:reference>'], type='http', auth='public', website=True)