Add depedencies.

Upgrade translations.
Improves error handling.
#036198
This commit is contained in:
Carlos G?lvez 2018-12-13 12:14:02 +01:00
parent c795ce8c6f
commit b65b118e33
4 changed files with 18 additions and 5 deletions

View File

@ -22,7 +22,10 @@ class Invoice(metaclass=PoolMeta):
cls._error_messages.update({
'missing_facturae_party_info': (
'Missing Factura-e info in party "%(party)s", '
'review the tab Factura-e of this party: "%(field)s"')
'review the tab Factura-e of this party: "%(field)s"'),
'missing_facturae_party_address_info': (
'Missing Factura-e info in party "%(party)s", '
'review the tab General of this party: "%(field)s"')
})
@classmethod
@ -66,7 +69,7 @@ class Invoice(metaclass=PoolMeta):
})
if not self.invoice_address.electronet_sale_point:
self.raise_user_error('missing_facturae_party_info', {
self.raise_user_error('missing_facturae_party_address_info', {
'party': party.rec_name,
'field': 'Electronet Sale Point'
})

View File

@ -6,8 +6,17 @@ msgctxt "error:account.invoice:"
msgid ""
"Missing Factura-e info in party \"%(party)s\", review the tab Factura-e of "
"this party: \"%(field)s\""
msgstr "Información Factura-e faltante en el tercero \"%(party)s\", revisa en la pestaña"
"Factura-e del tercero el campo: \"%(field)s\"."
msgstr ""
"Información Factura-e faltante en el tercero \"%(party)s\", revisa en la "
"pestaña Factura-e del tercero el campo: \"%(field)s\"."
msgctxt "error:account.invoice:"
msgid ""
"Missing Factura-e info in party \"%(party)s\", review the tab General of "
"this party: \"%(field)s\""
msgstr ""
"Información Factura-e faltante en el tercero \"%(party)s\", revisa en la "
"pestaña General del tercero el campo: \"%(field)s\"."
msgctxt "field:party.address,electronet_sale_point:"
msgid "Electronet Sale Point"

View File

@ -227,7 +227,7 @@
<DeliveryNotesReferences>
{% for shipment in line.shipments %}
<DeliveryNote>
<DeliveryNoteNumber>{{ shipment.reference or '' }}</DeliveryNoteNumber>
<DeliveryNoteNumber>{{ shipment.origin_reference or '' }}</DeliveryNoteNumber>
</DeliveryNote>
{% endfor %}
</DeliveryNotesReferences>

View File

@ -4,5 +4,6 @@ depends:
ir
account_invoice_facturae
account_invoice_sale_relation
stock_origin_sale
xml:
party.xml