Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
erp5_workflow
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wenjie.zheng
erp5_workflow
Commits
28bd395f
Commit
28bd395f
authored
Oct 16, 2015
by
wenjie.zheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Folder_viewSearchDialog.py: compatibility modification.
parent
88850816
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
product/ERP5Form/Extensions/Folder_viewSearchDialog.py
product/ERP5Form/Extensions/Folder_viewSearchDialog.py
+7
-7
No files found.
product/ERP5Form/Extensions/Folder_viewSearchDialog.py
View file @
28bd395f
...
...
@@ -320,16 +320,16 @@ def getSearchDialog(self, REQUEST=None):
workflow_set
=
set
()
# possible workflow states
for
type_name
in
allowed_content_types
:
for
workflow
_id
in
workflow_tool
.
getChain
For
(
type_name
):
workflow
=
workflow_tool
.
getWorkflowById
(
workflow_id
)
state_var
=
workflow
.
variables
.
getStateVar
()
for
workflow
in
workflow_tool
.
getWorkflows
For
(
type_name
):
workflow
_id
=
workflow
.
getId
(
)
state_var
=
workflow
.
getStateVariable
()
if
state_var
in
workflow_set
:
continue
workflow_set
.
add
(
state_var
)
if
workflow
.
states
is
None
or
\
len
(
workflow
.
states
.
objectIds
())
<=
1
:
if
workflow
.
getStateValueList
()
is
None
or
\
len
(
workflow
.
getStateValueList
())
<=
1
:
continue
field_id
=
'your_%s'
%
state_var
...
...
@@ -339,8 +339,8 @@ def getSearchDialog(self, REQUEST=None):
field
.
manage_edit_xmlrpc
(
dict
(
form_id
=
'Base_viewDialogFieldLibrary'
,
field_id
=
'your_category_list'
))
items
=
sorted
([(
translateString
(
x
.
title
),
x
.
id
)
for
x
in
workflow
.
states
.
objectValue
s
()],
items
=
sorted
([(
translateString
(
x
.
title
),
x
.
id
)
for
x
_ref
,
x
in
workflow
.
getStateValueList
().
item
s
()],
key
=
lambda
x
:
str
(
x
[
0
]))
field
.
_surcharged_edit
(
dict
(
title
=
translateString
(
workflow
.
title
),
...
...
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