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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Vivek
erp5
Commits
8a19c736
Commit
8a19c736
authored
12 years ago
by
Rafael Monnerat
Committed by
Jérome Perrin
9 years ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Split aggregated Values when use splitAndDefer
And merged with
5c09e2e2
parent
5a27182c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
product/ERP5/TargetSolver/SplitAndDefer.py
product/ERP5/TargetSolver/SplitAndDefer.py
+11
-0
No files found.
product/ERP5/TargetSolver/SplitAndDefer.py
View file @
8a19c736
...
...
@@ -66,6 +66,9 @@ class SplitAndDefer(CopyToTarget):
# Adopt different dates for deferred movements
movement_dict
=
_getPropertyAndCategoryList
(
simulation_movement
)
# new properties
delivery
=
simulation_movement
.
getDeliveryValue
()
aggregate_set
=
set
(
simulation_movement
.
getAggregateList
())
aggregate_diff_set
=
aggregate_set
.
difference
(
delivery
.
getAggregateList
())
movement_dict
.
update
(
portal_type
=
"Simulation Movement"
,
id
=
new_id
,
...
...
@@ -98,7 +101,15 @@ class SplitAndDefer(CopyToTarget):
if
stop_date
is
not
None
:
new_movement
.
recordProperty
(
'stop_date'
)
new_movement
.
edit
(
stop_date
=
stop_date
)
new_movement
.
recordProperty
(
'aggregate'
)
new_movement
.
edit
(
aggregate_list
=
list
(
aggregate_diff_set
))
new_movement
.
expand
(
activate_kw
=
self
.
additional_parameters
)
# Only update simulation movement if quantity was changed.
simulation_movement
.
recordProperty
(
'aggregate'
)
simulation_movement
.
edit
(
aggregate_list
=
delivery
.
getAggregateList
())
# adopt new quantity on original simulation movement
simulation_movement
.
edit
(
quantity
=
new_movement_quantity
)
simulation_movement
.
setDefaultActivateParameterDict
(
self
.
activate_kw
)
...
...
This diff is collapsed.
Click to expand it.
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