* remove logic of sequences in invoices and use new logic to set invoices sequences. * re add l10n_latam_document_number field to make the sequence set possible. * replace type field with move_type field in model account.move * add new field l10n_latam_manual_number to know when the document number should be or not set * update compute highest_name everytime that the journal and document type change. * implement how we deal with first number * for customer invoices only compute the name after they has been posted * be able to search by document type code * update translations
10 lines
309 B
Python
10 lines
309 B
Python
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
|
from odoo import fields, models
|
|
|
|
|
|
class IrSequence(models.Model):
|
|
|
|
_inherit = 'ir.sequence'
|
|
|
|
l10n_latam_document_type_id = fields.Many2one('l10n_latam.document.type', 'Document Type') #still needed for l10n_cl until next saas
|