[19.0][MIG] l10n_my_edi: model move from pos + account.move MyInvois data#97
Open
dnplkndll wants to merge 1 commit into
Open
[19.0][MIG] l10n_my_edi: model move from pos + account.move MyInvois data#97dnplkndll wants to merge 1 commit into
dnplkndll wants to merge 1 commit into
Conversation
- update_module_moved_models for myinvois.document + 2 transient wizards (l10n_my_edi_pos -> l10n_my_edi); 4 xmlids renamed from l10n_my_edi_pos. - pre-migration preserves the existing account.move MyInvois columns as legacy (filtered by column_exists -- l10n_my_edi_file is attachment-backed, no column); post-migration inserts one myinvois.document per move with non-NULL data (company_id/currency_id from the move, state copied 1:1), links via the myinvois_document_invoice_rel m2m, and re-points the file ir_attachment. - Lab-validated: migration rc=0; myinvois.document row + m2m link created with the expected data.
c387cc2 to
049a5f2
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Companion to #89, with an m2m link. The
myinvois.documentmodel (+ 2 transient wizards) moves out ofl10n_my_edi_pos; 18.0 invoice MyInvois EDI state lived on account.move, 19.0 it lives on myinvois.document rows linked viamyinvois_document_invoice_rel.update_module_moved_models+ 4 xmlid renames from l10n_my_edi_pos.column_exists—l10n_my_edi_fileis attachment-backed, no column); post-migration inserts one myinvois.document per move (company_id/currency_id from the move, state copied 1:1), fills the m2m via a scratch column, and re-points the file's ir_attachment.Lab-validated end-to-end: fresh 18.0 DB + synthetic MyInvois data + full
-u allmigration (rc=0); myinvois.document row created (state=valid, uuid, submission) with the m2m link to the source invoice. The fixture caught a real bug first —rename_columnson the attachment-backedl10n_my_edi_file(no column) — now fixed.