Skip to content

Commit

Permalink
[IMP] l10n_it_fatturapa_pec state related source strings (OCA#736)
Browse files Browse the repository at this point in the history
  • Loading branch information
primes2h authored and TheMule71 committed Apr 21, 2023
1 parent 2707187 commit 033234b
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 20 deletions.
20 changes: 10 additions & 10 deletions l10n_it_fatturapa_pec/i18n/it.po
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ msgid "Last error message"
msgstr "Ultimo messaggio di errore"

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:56
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:58
#, python-format
msgid "No incoming PEC server found. Please configure it."
msgstr "Nessun server PEC in ingresso trovato, configurarne uno."
Expand Down Expand Up @@ -219,21 +219,21 @@ msgid "Wizard to send multiple e-invoice PEC"
msgstr "Procedura per inviare PEC e-fattura multiple"

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:242
#, python-format
msgid "You can only delete 'ready to send' files."
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:246
#, fuzzy, python-format
msgid "You can only delete files in 'Ready to Send' state."
msgstr "È possibile eliminare solo file con stato «Pronto per l'invio»."

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:46
#, python-format
msgid "You can only reset 'sender error' files."
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:47
#, fuzzy, python-format
msgid "You can only reset files in 'Sender Error' state."
msgstr "È possibile reimpostare solo file con stato «Errore trasmittente»."

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:65
#, python-format
msgid "You can only send 'ready to send' files."
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:68
#, fuzzy, python-format
msgid "You can only send files in 'Ready to Send' state."
msgstr "È possibile inviare solo file con stato «Pronto per l'invio»."

#. module: l10n_it_fatturapa_pec
Expand Down
14 changes: 7 additions & 7 deletions l10n_it_fatturapa_pec/i18n/l10n_it_fatturapa_pec.pot
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ msgid "Last error message"
msgstr ""

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:56
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:58
#, python-format
msgid "No incoming PEC server found. Please configure it."
msgstr ""
Expand Down Expand Up @@ -215,21 +215,21 @@ msgid "Wizard to send multiple e-invoice PEC"
msgstr ""

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:242
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:246
#, python-format
msgid "You can only delete 'ready to send' files."
msgid "You can only delete files in 'Ready to Send' state."
msgstr ""

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:46
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:47
#, python-format
msgid "You can only reset 'sender error' files."
msgid "You can only reset files in 'Sender Error' state."
msgstr ""

#. module: l10n_it_fatturapa_pec
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:65
#: code:addons/l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py:68
#, python-format
msgid "You can only send 'Ready to Send' files."
msgid "You can only send files in 'Ready to Send' state."
msgstr ""

#. module: l10n_it_fatturapa_pec
Expand Down
10 changes: 7 additions & 3 deletions l10n_it_fatturapa_pec/models/fatturapa_attachment_out.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ class FatturaPAAttachmentOut(models.Model):
def reset_to_ready(self):
for att in self:
if att.state != 'sender_error':
raise UserError(_("You can only reset 'sender error' files."))
raise UserError(
_("You can only reset files in 'Sender Error' state.")
)
att.state = 'ready'

@api.model
Expand All @@ -62,7 +64,9 @@ def send_via_pec(self):
self.env.user.company_id.sdi_channel_id.check_first_pec_sending()
states = self.mapped('state')
if set(states) != set(['ready']):
raise UserError(_("You can only send 'Ready to Send' files."))
raise UserError(
_("You can only send files in 'Ready to Send' state.")
)
for att in self:
mail_message = self.env['mail.message'].create({
'model': self._name,
Expand Down Expand Up @@ -240,6 +244,6 @@ def unlink(self):
for att in self:
if att.state != 'ready':
raise UserError(_(
"You can only delete 'ready to send' files."
"You can only delete files in 'Ready to Send' state."
))
return super(FatturaPAAttachmentOut, self).unlink()

0 comments on commit 033234b

Please sign in to comment.