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
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Cédric Le Ninivin
erp5
Commits
d0ae8ccf
Commit
d0ae8ccf
authored
Jun 19, 2023
by
Xiaowu Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_base: check stock for multi destinations
parent
0b7a086b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
bt5/erp5_base/MixinTemplateItem/portal_components/mixin.erp5.BuilderMixin.py
...TemplateItem/portal_components/mixin.erp5.BuilderMixin.py
+3
-3
No files found.
bt5/erp5_base/MixinTemplateItem/portal_components/mixin.erp5.BuilderMixin.py
View file @
d0ae8ccf
...
@@ -509,7 +509,7 @@ class BuilderMixin(XMLObject, Amount, Predicate):
...
@@ -509,7 +509,7 @@ class BuilderMixin(XMLObject, Amount, Predicate):
# Prepare history list to work with
# Prepare history list to work with
history_list
=
resource_value
.
Resource_getInventoryHistoryList
(
history_list
=
resource_value
.
Resource_getInventoryHistoryList
(
from_date
=
from_date
,
from_date
=
from_date
,
node_uid
=
supply
.
getDestinationUid
()
node_uid
=
supply
.
getDestinationUid
List
()
# XXX This should be bound to a stard and stop date
# XXX This should be bound to a stard and stop date
)
)
#self.log("history_list len: %s" % len(history_list))
#self.log("history_list len: %s" % len(history_list))
...
@@ -542,14 +542,14 @@ class BuilderMixin(XMLObject, Amount, Predicate):
...
@@ -542,14 +542,14 @@ class BuilderMixin(XMLObject, Amount, Predicate):
future_inventory_to_date
=
portal
.
portal_simulation
.
getFutureInventory
(
future_inventory_to_date
=
portal
.
portal_simulation
.
getFutureInventory
(
to_date
=
limit_date_list
[
0
],
to_date
=
limit_date_list
[
0
],
resource_uid
=
resource_value
.
getUid
(),
resource_uid
=
resource_value
.
getUid
(),
node_uid
=
supply
.
getDestinationUid
(),
node_uid
=
supply
.
getDestinationUid
List
(),
)
)
# We update history_list to include movements from the initial inventory date
# We update history_list to include movements from the initial inventory date
history_list
=
resource_value
.
Resource_getInventoryHistoryList
(
history_list
=
resource_value
.
Resource_getInventoryHistoryList
(
from_date
=
limit_date_list
[
0
],
from_date
=
limit_date_list
[
0
],
to_date
=
history_list
[
0
][
0
],
to_date
=
history_list
[
0
][
0
],
node_uid
=
supply
.
getDestinationUid
()
node_uid
=
supply
.
getDestinationUid
List
()
)
+
history_list
)
+
history_list
next_period_history_list
=
[]
next_period_history_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