Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Klaus Wölfel
erp5
Commits
1e3f897f
Commit
1e3f897f
authored
Apr 03, 2019
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixup! accounting: reset grouping reference in a "context free" script
parent
4bd5cbe7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionLine_resetGroupingReference.py
...nting/AccountingTransactionLine_resetGroupingReference.py
+7
-5
No files found.
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionLine_resetGroupingReference.py
View file @
1e3f897f
...
...
@@ -15,23 +15,25 @@ portal = context.getPortalObject()
resetGroupingReference
=
portal
.
ERP5Site_resetAccountingTransactionLineGroupingReference
if
async
:
resetGroupingReference
=
portal
.
portal_simulation
.
activate
(
activity
=
'SQLQueue'
,
after_tag
=
'accounting_grouping_reference'
).
ERP5Site_resetAccountingTransactionLineGroupingReference
ungrouped_line_list
=
[]
ungrouped_line_set
=
set
()
grouping_reference
=
context
.
getGroupingReference
()
for
(
section_value
,
node_uid
,
mirror_section_uid
)
in
(
(
context
.
getSourceSectionValue
(),
context
.
getSourceUid
(),
context
.
getDestinationSectionUid
(),),
(
context
.
getDestinationSectionValue
(),
context
.
getDestinationUid
(),
context
.
getSourceSectionUid
(),),
):
if
section_value
is
not
None
:
if
node_uid
is
not
None
and
section_value
is
not
None
:
section_value
=
section_value
.
Organisation_getMappingRelatedOrganisation
()
section_category
=
section_value
.
getGroup
(
base
=
True
)
if
section_category
:
ungrouped_line_
list
.
extend
(
resetGroupingReference
(
ungrouped_line_
set
.
update
(
resetGroupingReference
(
section_category
=
section_category
,
node_uid
=
node_uid
,
mirror_section_uid
=
mirror_section_uid
,
grouping_reference
=
context
.
getGroupingReference
()
grouping_reference
=
grouping_reference
)
or
[])
return
list
(
ungrouped_line_set
)
return
ungrouped_line_list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment