diff --git a/l10n_it_fatturapa_in/README.rst b/l10n_it_fatturapa_in/README.rst index 1acf450142cb..a58c86e5a49c 100644 --- a/l10n_it_fatturapa_in/README.rst +++ b/l10n_it_fatturapa_in/README.rst @@ -178,7 +178,7 @@ Contributors * Giovanni Serra * Gianmarco Conte * Marco Colombo - +* Salvo Rapisarda * `Aion Tech `_: * Simone Rubino diff --git a/l10n_it_fatturapa_in/readme/CONTRIBUTORS.rst b/l10n_it_fatturapa_in/readme/CONTRIBUTORS.rst index 1d05f367b355..e7eb9e874520 100644 --- a/l10n_it_fatturapa_in/readme/CONTRIBUTORS.rst +++ b/l10n_it_fatturapa_in/readme/CONTRIBUTORS.rst @@ -5,7 +5,7 @@ * Giovanni Serra * Gianmarco Conte * Marco Colombo - +* Salvo Rapisarda * `Aion Tech `_: * Simone Rubino diff --git a/l10n_it_fatturapa_in/static/description/index.html b/l10n_it_fatturapa_in/static/description/index.html index 0fc210fdbf57..bd4b4d4646ab 100644 --- a/l10n_it_fatturapa_in/static/description/index.html +++ b/l10n_it_fatturapa_in/static/description/index.html @@ -500,6 +500,7 @@

Contributors

  • Giovanni Serra <giovanni@gslab.it>
  • Gianmarco Conte <gconte@dinamicheaziendali.it>
  • Marco Colombo <https://github.com/TheMule71>
  • +
  • Salvo Rapisarda <https://github.com/salvorapi>
  • Aion Tech: diff --git a/l10n_it_ricevute_bancarie/tests/test_riba.py b/l10n_it_ricevute_bancarie/tests/test_riba.py index 2cb610b1d190..9391aca7a8c3 100644 --- a/l10n_it_ricevute_bancarie/tests/test_riba.py +++ b/l10n_it_ricevute_bancarie/tests/test_riba.py @@ -375,6 +375,28 @@ def test_unsolved_riba(self): wiz_accreditation.create_move() self.assertEqual(riba_list.state, "accredited") + # credit wizard with skip + credit_wizard = ( + self.env["riba.accreditation"] + .with_context( + { + "active_model": "riba.distinta", + "active_ids": [riba_list_id], + "active_id": riba_list_id, + } + ) + .create( + { + "bank_amount": 95, + "expense_amount": 5, + } + ) + ) + credit_wizard.skip() + self.assertEqual(riba_list.state, "accredited") + + self.assertEqual(riba_list.line_ids[0].state, "accredited") + # past due wizard wiz_unsolved = ( self.env["riba.unsolved"] diff --git a/l10n_it_ricevute_bancarie/wizard/wizard_accreditation.py b/l10n_it_ricevute_bancarie/wizard/wizard_accreditation.py index 43005a9cbc6a..fc45ab63a896 100644 --- a/l10n_it_ricevute_bancarie/wizard/wizard_accreditation.py +++ b/l10n_it_ricevute_bancarie/wizard/wizard_accreditation.py @@ -76,7 +76,9 @@ def skip(self): active_id = self.env.context.get("active_id") or False if not active_id: raise UserError(_("No active ID found.")) - self.env["riba.distinta"].browse(active_id).state = "accredited" + riba_distinta = self.env["riba.distinta"].browse(active_id) + riba_distinta.state = "accredited" + riba_distinta.line_ids.state = "accredited" return {"type": "ir.actions.act_window_close"} def create_move(self):