[FIX] payment: untranslated message
Without this the error message will always be in English, no matter the language of the end-user. Closes #17141
This commit is contained in:
@@ -805,6 +805,13 @@ msgstr ""
|
|||||||
msgid "The payment transaction reference must be unique!"
|
msgid "The payment transaction reference must be unique!"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
#. module: payment
|
||||||
|
#: code:addons/payment/models/account_payment.py:43
|
||||||
|
#, python-format
|
||||||
|
msgid "This feature is not available for payment acquirers set to the "Authorize" mode.\n"
|
||||||
|
"Please use a token from another provider than %s."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
#. module: payment
|
#. module: payment
|
||||||
#: model:ir.model.fields,help:payment.field_payment_acquirer_image
|
#: model:ir.model.fields,help:payment.field_payment_acquirer_image
|
||||||
msgid "This field holds the image used for this provider, limited to 1024x1024px"
|
msgid "This field holds the image used for this provider, limited to 1024x1024px"
|
||||||
@@ -961,4 +968,3 @@ msgstr ""
|
|||||||
#: model:ir.ui.view,arch_db:payment.acquirer_form
|
#: model:ir.ui.view,arch_db:payment.acquirer_form
|
||||||
msgid "user: current user browse record"
|
msgid "user: current user browse record"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
|||||||
@@ -39,8 +39,8 @@ class AccountPayment(models.Model):
|
|||||||
|
|
||||||
def _do_payment(self):
|
def _do_payment(self):
|
||||||
if self.payment_token_id.acquirer_id.auto_confirm == 'authorize':
|
if self.payment_token_id.acquirer_id.auto_confirm == 'authorize':
|
||||||
raise ValidationError('This feature is not available for payment acquirers set to the "Authorize" mode.\n'
|
raise ValidationError(_('This feature is not available for payment acquirers set to the "Authorize" mode.\n'
|
||||||
'Please use a token from another provider than %s.' % self.payment_token_id.acquirer_id.name)
|
'Please use a token from another provider than %s.') % self.payment_token_id.acquirer_id.name)
|
||||||
reference = "P-%s-%s" % (self.id, datetime.datetime.now().strftime('%y%m%d_%H%M%S'))
|
reference = "P-%s-%s" % (self.id, datetime.datetime.now().strftime('%y%m%d_%H%M%S'))
|
||||||
tx = self.env['payment.transaction'].create({
|
tx = self.env['payment.transaction'].create({
|
||||||
'amount': self.amount,
|
'amount': self.amount,
|
||||||
|
|||||||
Reference in New Issue
Block a user