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
Xiaowu Zhang
erp5
Commits
dc2bab95
Commit
dc2bab95
authored
Sep 19, 2017
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Folder_generateWorkflowReport: Use select_dict to alias select function
parent
827dc5dc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
3 deletions
+2
-3
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_generateWorkflowReport.py
...m/portal_skins/erp5_core/Folder_generateWorkflowReport.py
+2
-3
No files found.
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_generateWorkflowReport.py
View file @
dc2bab95
...
...
@@ -27,15 +27,14 @@ for portal_type in context.allowedContentTypes():
state_count_dict
[
state_id
]
=
0
add
(
state_var
)
column_list
=
[
'portal_type'
]
+
list
(
state_variable_set
)
COUNT
=
'count(*)'
search_folder_kw
=
{}
if
use_selection
:
selection_kw
=
portal
.
portal_selections
.
getSelectionParamsFor
(
selection_name
).
copy
()
selection_kw
.
pop
(
'limit'
,
None
)
search_folder_kw
[
'query'
]
=
portal
.
portal_catalog
.
getSQLCatalog
().
buildQuery
(
selection_kw
)
for
line
in
context
.
searchFolder
(
group_by
=
column_list
,
select_
list
=
[
COUNT
]
+
column_list
,
**
search_folder_kw
):
for
line
in
context
.
searchFolder
(
group_by
=
column_list
,
select_
dict
=
{
'count'
:
'count(*)'
}
+
column_list
,
**
search_folder_kw
):
portal_type
=
line
.
portal_type
count
=
getattr
(
line
,
COUNT
)
count
=
line
.
count
for
state_variable
in
state_variable_set
:
workflow
=
type_state_variable_workflow_dict
.
get
((
line
.
portal_type
,
state_variable
))
state
=
getattr
(
line
,
state_variable
)
...
...
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