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
afaa9d19
Commit
afaa9d19
authored
Jan 21, 2019
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CMFActivity: remove old skin if any
parent
d64887cb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
product/CMFActivity/ActivityTool.py
product/CMFActivity/ActivityTool.py
+14
-0
No files found.
product/CMFActivity/ActivityTool.py
View file @
afaa9d19
...
@@ -682,6 +682,20 @@ class ActivityTool (BaseTool):
...
@@ -682,6 +682,20 @@ class ActivityTool (BaseTool):
self
.
maybeMigrateConnectionClass
()
self
.
maybeMigrateConnectionClass
()
for
activity
in
activity_dict
.
itervalues
():
for
activity
in
activity_dict
.
itervalues
():
activity
.
initialize
(
self
,
clear
=
False
)
activity
.
initialize
(
self
,
clear
=
False
)
# Remove old skin if any.
skins_tool
=
self
.
getPortalObject
().
portal_skins
name
=
'activity'
if
(
getattr
(
skins_tool
.
get
(
name
),
'_dirpath'
,
None
)
==
'Products.CMFActivity:skins/activity'
):
for
selection
,
skins
in
skins_tool
.
getSkinPaths
():
skins
=
skins
.
split
(
','
)
try
:
skins
.
remove
(
name
)
except
ValueError
:
continue
skins_tool
.
manage_skinLayers
(
add_skin
=
1
,
skinname
=
selection
,
skinpath
=
skins
)
skins_tool
.
_delObject
(
name
)
def
_callSafeFunction
(
self
,
batch_function
):
def
_callSafeFunction
(
self
,
batch_function
):
return
batch_function
()
return
batch_function
()
...
...
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