Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
Boxiang Sun
slapos.core
Commits
4331e3de
Commit
4331e3de
authored
Apr 12, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pass path as uid is not supported by searchAndActivate
parent
59f48f8d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
11 deletions
+12
-11
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/Alarm_expandConfirmedSaleOrder.xml
...skins/vifib_simulation/Alarm_expandConfirmedSaleOrder.xml
+3
-3
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/Alarm_expandDeliveryLine.xml
...ortal_skins/vifib_simulation/Alarm_expandDeliveryLine.xml
+8
-7
master/bt5/vifib_base/bt/revision
master/bt5/vifib_base/bt/revision
+1
-1
No files found.
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/Alarm_expandConfirmedSaleOrder.xml
View file @
4331e3de
...
...
@@ -56,14 +56,14 @@ portal = context.getPortalObject()\n
activate_kw = {\n
\'tag\': tag\n
}\n
uid_list = [q.UID
for q in portal.Base_getNotCategoryRelatedList(\n
path_list = [q.getPath()
for q in portal.Base_getNotCategoryRelatedList(\n
portal_type_list=[\'Sale Order Line\'],\n
simulation_state_list=[\'confirmed\'],\n
base_category_uid=portal.portal_categories.delivery.getUid())]\n
\n
if len(
uid
_list) >
0:\n
if len(
path
_list) >
0:\n
portal.portal_catalog.searchAndActivate(\n
uid=uid
_list,\n
path=path
_list,\n
activate_kw=activate_kw,\n
packet_size=1, # Separate calls to many transactions\n
method_id=\'DeliveryLine_updateAppliedRule\',\n
...
...
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/Alarm_expandDeliveryLine.xml
View file @
4331e3de
...
...
@@ -53,6 +53,7 @@
<value>
<string
encoding=
"cdata"
>
<![CDATA[
portal = context.getPortalObject()\n
\n
activate_kw = {\n
\'tag\': tag\n
}\n
...
...
@@ -64,25 +65,25 @@ kw = dict(\n
simulation_state_list=simulation_state_list,\n
base_category_uid=portal.portal_categories.delivery.getUid()\n
)\n
uid
_list = set()\n
path
_list = set()\n
\n
for q in portal.Base_getNotCategoryRelatedList(**kw):\n
uid_list.add(q.UID
)\n
path_list.add(q.getPath()
)\n
\n
for q in portal.Base_getNotSynchronisedSimulationStateCategoryRelatedList(**kw):\n
uid_list.add(q.UID
)\n
path_list.add(q.getPath()
)\n
\n
# and all invoice lines and and transcation lines in confirmed state\n
# XXX: We do simple version, and in Vifib confirmed ones can be often expanded, as it is short living state\n
\n
for q in portal.portal_catalog(portal_type=\'Invoice Line\', simulation_state=\'confirmed\'):\n
if q.getSimulationState() == \'confirmed\':\n
uid_list.add(q.UID
)\n
uid_list = list(uid
_list)\n
path_list.add(q.getPath()
)\n
path_list = list(path
_list)\n
\n
if len(
uid
_list) >
0:\n
if len(
path
_list) >
0:\n
portal.portal_catalog.searchAndActivate(\n
uid=uid
_list,\n
path=path
_list,\n
packet_size=1, # Separate calls to many transactions\n
activate_kw=activate_kw,\n
method_id=\'DeliveryLine_updateAppliedRule\',\n
...
...
master/bt5/vifib_base/bt/revision
View file @
4331e3de
427
\ No newline at end of file
428
\ No newline at end of file
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