[FIX] website_sale: translated terms payment status
Payment status (website_sale confirmation page) inject a status message, which was not set to be translatable. It should be the case.
This commit is contained in:
parent
586b0e2f5d
commit
474eae9a43
|
@ -685,7 +685,7 @@ class Ecommerce(http.Controller):
|
|||
if not order:
|
||||
return {
|
||||
'state': 'error',
|
||||
'message': '<p>There seems to be an error with your request.</p>',
|
||||
'message': '<p>%s</p>' % _('There seems to be an error with your request.'),
|
||||
}
|
||||
|
||||
tx_ids = request.registry['payment.transaction'].search(
|
||||
|
@ -697,7 +697,7 @@ class Ecommerce(http.Controller):
|
|||
if order.amount_total:
|
||||
return {
|
||||
'state': 'error',
|
||||
'message': '<p>There seems to be an error with your request.</p>',
|
||||
'message': '<p>%s</p>' % _('There seems to be an error with your request.'),
|
||||
}
|
||||
else:
|
||||
state = 'done'
|
||||
|
@ -707,14 +707,14 @@ class Ecommerce(http.Controller):
|
|||
tx = request.registry['payment.transaction'].browse(cr, uid, tx_ids[0], context=context)
|
||||
state = tx.state
|
||||
if state == 'done':
|
||||
message = '<p>Your payment has been received.</p>'
|
||||
message = '<p>%s</p>' % _('Your payment has been received.')
|
||||
elif state == 'cancel':
|
||||
message = '<p>The payment seems to have been canceled.</p>'
|
||||
message = '<p>%s</p>' % _('The payment seems to have been canceled.')
|
||||
elif state == 'pending' and tx.acquirer_id.validation == 'manual':
|
||||
message = '<p>Your transaction is waiting confirmation.</p>'
|
||||
message = '<p>%s</p>' % _('Your transaction is waiting confirmation.')
|
||||
message += tx.acquirer_id.post_msg
|
||||
else:
|
||||
message = '<p>Your transaction is waiting confirmation.</p>'
|
||||
message = '<p>%s</p>' % _('Your transaction is waiting confirmation.')
|
||||
validation = tx.acquirer_id.validation
|
||||
|
||||
return {
|
||||
|
|
Loading…
Reference in New Issue