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
Gabriel Monnerat
slapos.core
Commits
3f0dd2e5
Commit
3f0dd2e5
authored
Aug 23, 2016
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_accounting: Speed up query by using uid of the known objects (intead reference+portal_type)
parent
7856a2f1
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
3 deletions
+2
-3
master/bt5/slapos_accounting/SkinTemplateItem/portal_skins/slapos_accounting/OrderBuilder_generateSlapOSAggregatedMovementList.py
...ting/OrderBuilder_generateSlapOSAggregatedMovementList.py
+2
-3
No files found.
master/bt5/slapos_accounting/SkinTemplateItem/portal_skins/slapos_accounting/OrderBuilder_generateSlapOSAggregatedMovementList.py
View file @
3f0dd2e5
...
...
@@ -8,7 +8,7 @@ portal = context.getPortalObject()
business_process_uid_list
=
[
portal
.
business_process_module
.
slapos_consumption_business_process
.
getUid
(),
portal
.
business_process_module
.
slapos_subscription_business_process
.
getUid
()]
specialise_
reference_list
=
[
q
.
getReference
()
for
q
in
portal
.
portal_catalog
(
specialise_uid
=
business_process_uid_list
,
specialise_
uid_list
=
[
q
.
getUid
()
for
q
in
portal
.
portal_catalog
(
specialise_uid
=
business_process_uid_list
,
portal_type
=
'Sale Trade Condition'
)]
select_dict
=
{
'default_aggregate_portal_type'
:
None
}
...
...
@@ -16,8 +16,7 @@ select_kw.update(
limit
=
50
,
# just take a bit
portal_type
=
'Sale Packing List Line'
,
simulation_state
=
'delivered'
,
parent_specialise_reference
=
specialise_reference_list
,
parent_specialise_portal_type
=
'Sale Trade Condition'
,
parent_specialise_uid
=
specialise_uid_list
,
select_dict
=
select_dict
,
left_join_list
=
select_dict
.
keys
(),
default_aggregate_portal_type
=
ComplexQuery
(
NegatedQuery
(
Query
(
default_aggregate_portal_type
=
'Computer'
)),
...
...
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