Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[17.0][MIG] l10n_es_aeat_sii_oca: Migration to v17 #3737

Open
wants to merge 301 commits into
base: 17.0
Choose a base branch
from

Conversation

manuelregidor
Copy link
Contributor

@manuelregidor manuelregidor commented Sep 27, 2024

Supersedes: #3504

En esta migración se han incluido algunos cambios con respecto a v16:

  • Se ha eliminado la dependencia hacia el módulo queue_job. Ahora, el envío al SII se realiza a través de triggers, una opción base de Odoo.
  • Se han incluido las funcionalidades del módulo l10n_es_dua_sii (https://github.com/OCA/l10n-spain/tree/16.0/l10n_es_dua_sii), que en v17 ya no será necesario por haber pasado la gestión del DUA al módulo l10n-es.
  • Se ha eliminado el envío instantáneo cuando se valida una factura.

Quedará pendiente crear un nuevo campo sii_start_date en res.company, que serviría para que la función _compute_sii_enabled de sii.mixin lo tenga en cuenta para dar valor al campo sii_enabled.

T-5833

@manuelregidor
Copy link
Contributor Author

Copy link
Contributor

@HaraldPanten HaraldPanten left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Un par de comentarios, antes de revisarlo funcionalmente:

  • En el README (apartado DESCRIPTION) se sigue haciendo referencia al queue_job. Ese punto habría que quitarlo.
  • Puedes poner a Sygel como autores? Hemos hecho un buen refactoring y creo que es justo estar ahí. @pedrobaeza entiendo que no hay problema en ello, no?

Gracias!

@pedrobaeza
Copy link
Member

Estoy de acuerdo con la co-autoría en este caso. Bien es cierto que AuresTIC (cc @zamberjo) por trabajos pasados también la merece.

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch from 1fb8cbf to 7c0456a Compare September 27, 2024 07:49
@manuelregidor
Copy link
Contributor Author

@HaraldPanten Cambios aplicados. En cuanto a los autores, he añadido a Sygel. Si finalmente tengo que añadir a AuresTIC, lo hago en un momento.

@pedrobaeza
Copy link
Member

Incluid por favor #3736

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch from 7c0456a to fc0ea1f Compare September 27, 2024 07:58
@manuelregidor
Copy link
Contributor Author

@pedrobaeza incluido

@pedrobaeza
Copy link
Member

/ocabot migration l10n_es_aeat_sii_oca

Habría que incluir (adaptando) #3740 para los nuevos impuestos de octubre.

@OCA-git-bot OCA-git-bot added this to the 17.0 milestone Sep 28, 2024
@OCA-git-bot OCA-git-bot mentioned this pull request Sep 28, 2024
50 tasks
@pedrobaeza
Copy link
Member

Para incluir también #3741, y se pueden juntar ambos commits, ya que es un leftover del primero.

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch 2 times, most recently from ef7a702 to 7455920 Compare September 30, 2024 06:27
@manuelregidor
Copy link
Contributor Author

@pedrobaeza commits añadidos

@pedrobaeza
Copy link
Member

Incluye por favor #3759, y a ver si esta semana lo puedo revisar ya para fusionarlo.

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch from 7455920 to 6511e98 Compare October 9, 2024 13:24
@manuelregidor
Copy link
Contributor Author

@pedrobaeza commit #3759 añadido

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch from 6511e98 to 69e97db Compare October 21, 2024 05:49
Copy link
Contributor

@Jesarregui Jesarregui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functional Review: LGTM

Copy link
Contributor

@HaraldPanten HaraldPanten left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems to be OK.

Copy link
Contributor

@HaraldPanten HaraldPanten left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Disculpad, para el SII vamos a añadir la compatibilidad con DUA (impuestos que ya llevan en el core) en este mismo módulo, no me acordaba.

Queda este aspecto pendiente.

@HaraldPanten HaraldPanten self-requested a review October 30, 2024 14:34
@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch 3 times, most recently from 82c6319 to 2467f8e Compare November 4, 2024 17:08
Copy link
Contributor

@Jesarregui Jesarregui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functional Review: LGTM

@manuelregidor
Copy link
Contributor Author

@pedrobaeza @etobella @acysos Ya se puede revisar.

OCA-git-bot and others added 15 commits February 24, 2025 11:24
Steps to reproduce:

- Enable SII in a company with connector with a delay of 48 hours.
- Create and validate an invoice. A job is configured for being executed
  in 48 hours.
- Next day, filter "Not sent to SII", and do Action > Send to SII.

Result: the pending invoices are requeued and the delay is reapplied,
so the invoices will be sent in 48 hours from that moment. Doing this
indefinitely, the invoices will never be sent!

Although it's a weird behavior, let's avoid it not requeuing the
invoices with pending jobs.

For this, a little refactor in the code has been done, not calling
_cancel_sii_jobs, but filtering another way, and not removing previous
failed jobs, which can be considered the only functional change, and
it's not bad IMO.

TT50641
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: l10n-spain-16.0/l10n-spain-16.0-l10n_es_aeat_sii_oca
Translate-URL: https://translation.odoo-community.org/projects/l10n-spain-16-0/l10n-spain-16-0-l10n_es_aeat_sii_oca/
Creación de un nuevo modelo en `l10n_es_aeat` llamado *aeat_mixin*, del
que heredan *sii.mixin* (ya existente) y un nuevo *verifactu.mixin*.
Refactor de *sii.mixin* pasando funcionalidad a *aeat_mixin*
Se han renombrado varios campos sii_* a aeat_* ya que serán utilizados
por ambos.
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: l10n-spain-16.0/l10n-spain-16.0-l10n_es_aeat_sii_oca
Translate-URL: https://translation.odoo-community.org/projects/l10n-spain-16-0/l10n-spain-16-0-l10n_es_aeat_sii_oca/
Following odoo/odoo@fbc7214, this commit
puts the new taxes on the corresponding SII maps for being able to
send invoices containing them to the AEAT service.

TT51016
…atibilities (hr_expense for example)

Steps to reproduce:
- Install hr_expense
- Create a purchase type journal named Expenses and uncheck the Enable SII field.
- Go to Expense > Configuration > Settings and define in Employee Expense Journal the
Expenses journal previously created
- Create an expense and an expense sheet
- Click on the Submit to manager button
- Click on the Approve button
- Click on the Post journal entries button
- The journal entry will be created correctly without any error

TT51825
@ValentinVinagre
Copy link
Contributor

Disculpad, para el SII vamos a añadir la compatibilidad con DUA (impuestos que ya llevan en el core) en este mismo módulo, no me acordaba.

Queda este aspecto pendiente.

@HaraldPanten este PR está bloqueado por tu parte. ¿Que quedaría por realizar del DUA?

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch from f31ee12 to aadcf51 Compare February 27, 2025 11:39
@HaraldPanten
Copy link
Contributor

[MIG] l10n_es_aeat_sii_oca: Migration to v18 #4046

Lo del DUA ya se añadió. @AaronHForgeFlow Como estás haciendo la migración a V18, puedes revisar este PR primero?

Gracias.

@AaronHForgeFlow
Copy link
Contributor

@HaraldPanten He hecho pruebas y no he encontrado ningún error. Sigo revisando los procesos, pero tengo poca experiencia en la localización y puede que se me escapen cosas.

@AaronHForgeFlow
Copy link
Contributor

¿Podéis hacer commits separados para cada módulo? es más entendible luego a la hora de migrar. Supongo que los cambios en el modelo de ir.cron.trigger son necesarios en el módulo base de AEAT porque los usarán otros módulos de sii, facturae y demás.

@manuelregidor manuelregidor force-pushed the 17.0-mig-l10n_es_aeat_sii_oca branch from aadcf51 to f0d99ee Compare February 28, 2025 07:48
@manuelregidor
Copy link
Contributor Author

@AaronHForgeFlow Se ha separado la parte de los triggers del módulo l10n_es_aeat en otro commit.

Copy link
Contributor

@ValentinVinagre ValentinVinagre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.