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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tatuya Kamada
erp5
Commits
59fe5071
Commit
59fe5071
authored
Mar 03, 2021
by
Gabriel Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_xhtml_style: add compatibility with _raw for every category
parent
9e3b20c9
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
15 deletions
+18
-15
product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/Base_fixDialogActions.py
...em/portal_skins/erp5_xhtml_style/Base_fixDialogActions.py
+18
-15
No files found.
product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/Base_fixDialogActions.py
View file @
59fe5071
...
@@ -3,21 +3,24 @@ actions that does not provide one.
...
@@ -3,21 +3,24 @@ actions that does not provide one.
"""
"""
from
Products.PythonScripts.standard
import
url_quote
from
Products.PythonScripts.standard
import
url_quote
if
dialog_category
==
'object_jump'
:
action_mapping_dict
=
{
return
sorted
(
actions
.
get
(
'object_jump'
,
[])
+
actions
.
get
(
'object_jio_jump'
,
[]),
key
=
lambda
x
:
x
[
"priority"
])
"object_jump"
:
[
"object_jump"
,
"object_jio_jump"
],
if
dialog_category
==
'object_report'
:
"object_report"
:
[
"object_report"
,
"object_jio_report"
],
return
sorted
(
actions
.
get
(
'object_report'
,
[])
+
actions
.
get
(
'object_jio_report'
,
[]),
key
=
lambda
x
:
x
[
"priority"
])
"object_exchange"
:
[
"object_exchange"
,
"object_jio_exchange"
],
elif
dialog_category
==
'object_exchange'
:
"object_action"
:
[
"object_action"
,
"object_jio_action"
],
return
sorted
(
actions
.
get
(
'object_exchange'
,
[])
+
actions
.
get
(
'object_jio_exchange'
,
[]),
key
=
lambda
x
:
x
[
"priority"
])
"object_fast_input"
:
[
"object_fast_input"
,
"object_jio_fast_input"
],
elif
dialog_category
==
'object_action'
:
"object_button"
:
[
"object_button"
,
"object_jio_button"
]
return
sorted
(
actions
.
get
(
'object_action'
,
[])
+
actions
.
get
(
'object_jio_action'
,
[]),
key
=
lambda
x
:
x
[
"priority"
])
}
elif
dialog_category
==
'object_fast_input'
:
return
sorted
(
actions
.
get
(
'object_fast_input'
,
[])
+
actions
.
get
(
'object_jio_fast_input'
,
[]),
key
=
lambda
x
:
x
[
"priority"
])
def
getActionList
(
dialog_category
):
elif
dialog_category
==
'object_button'
:
action_list
=
[]
return
sorted
(
actions
.
get
(
'object_button'
,
[])
+
for
key
in
action_mapping_dict
[
dialog_category
]:
actions
.
get
(
'object_jio_button'
,
[])
+
action_list
+=
actions
.
get
(
key
,
[])
+
actions
.
get
(
"{}_raw"
.
format
(
key
),
[])
actions
.
get
(
'object_jio_button_raw'
,
[]),
return
sorted
(
action_list
,
key
=
lambda
x
:
x
[
"priority"
])
key
=
lambda
x
:
x
[
"priority"
])
if
dialog_category
in
action_mapping_dict
:
return
getActionList
(
dialog_category
)
if
dialog_category
!=
'object_print'
:
if
dialog_category
!=
'object_print'
:
return
actions
.
get
(
dialog_category
,
[])
return
actions
.
get
(
dialog_category
,
[])
...
...
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