Skip to content
Snippets Groups Projects
Commit c6708a21 authored by Josse Colpaert's avatar Josse Colpaert
Browse files

[FIX] l10n_latam_invoice_document: change first document number in draft

The name of your first customer invoice is a configuration that
determines the next ones.  The problem before is that when you
confirmed a first invoice, you could not alter its document number
anymore.  With this commit, as long as it is the first invoice,
you can still change the document number when you reset to draft.
parent 01e09720
Branches
Tags
No related merge requests found
......@@ -45,7 +45,7 @@
attrs="{'invisible': [('l10n_latam_use_documents', '=', False)], 'required': [('l10n_latam_use_documents', '=', True)], 'readonly': [('posted_before', '=', True)]}"
domain="[('id', 'in', l10n_latam_available_document_type_ids)]" options="{'no_open': True, 'no_create': True}"/>
<field name="l10n_latam_document_number"
attrs="{'invisible': ['|', ('l10n_latam_use_documents', '=', False), ('l10n_latam_manual_document_number', '=', False), '|', '|', ('l10n_latam_use_documents', '=', False), ('highest_name', '!=', False), ('state', '!=', 'draft')], 'required': ['|', ('l10n_latam_manual_document_number', '=', True), ('highest_name', '=', False)], 'readonly': [('posted_before', '=', True)]}"/>
attrs="{'invisible': ['|', ('l10n_latam_use_documents', '=', False), ('l10n_latam_manual_document_number', '=', False), '|', '|', ('l10n_latam_use_documents', '=', False), ('highest_name', '!=', False), ('state', '!=', 'draft')], 'required': ['|', ('l10n_latam_manual_document_number', '=', True), ('highest_name', '=', False)], 'readonly': [('posted_before', '=', True), ('state', '!=', 'draft')]}"/>
</xpath>
<!-- on latam_documents we use document_number to set name -->
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment