From 206e7f45f86cd156b90e35c8a6eeda68057890c4 Mon Sep 17 00:00:00 2001 From: Sergi Almacellas Abellana Date: Wed, 18 Mar 2020 12:32:56 +0100 Subject: [PATCH] Show the move resulting from the GroupLines wizard issue8410 review262921002 --- CHANGELOG | 1 + move.py | 8 ++++---- move.xml | 9 +++++++++ 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 07bae0b0a1..8845c49873 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,4 @@ +* Show the move resulting from the GroupLines wizard * Allow periods to end on any day of the month * Use a wizard to select parameters when creating periods * Modularize code in GroupLines wizard diff --git a/move.py b/move.py index 8f7e7c1681..c33719b1c8 100644 --- a/move.py +++ b/move.py @@ -1864,16 +1864,16 @@ class GroupLines(Wizard): Button("Cancel", 'end', 'tryton-cancel'), Button("Group", 'group', 'tryton-ok', default=True), ]) - group = StateTransition() + group = StateAction('account.act_move_form_grouping') - def transition_group(self): + def do_group(self, action): pool = Pool() Line = pool.get('account.move.line') lines = Line.browse(Transaction().context['active_ids']) move, balance_line = self._group_lines(lines) - - return 'end' + action['res_id'] = [move.id] + return action, {} def _group_lines(self, lines, date=None): move, balance_line = self.group_lines(lines, self.start.journal, date) diff --git a/move.xml b/move.xml index 3ce79e1f1d..956f9693ab 100644 --- a/move.xml +++ b/move.xml @@ -427,5 +427,14 @@ this repository contains the full copyright notices and license terms. --> account.move.general_journal account/general_journal.fodt + + Grouped Account Move + account.move + + + + + +