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
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
Amer
erp5
Commits
3d209aa1
Commit
3d209aa1
authored
Mar 08, 2012
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make sure that 'erp5' version is always defined when setting version priority list on ERP5Site.
parent
db4b73b1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
4 deletions
+12
-4
product/ERP5/ERP5Site.py
product/ERP5/ERP5Site.py
+12
-4
No files found.
product/ERP5/ERP5Site.py
View file @
3d209aa1
...
...
@@ -455,15 +455,23 @@ class ERP5Site(FolderMixIn, CMFSite, CacheCookieMixin):
security
.
declareProtected
(
Permissions
.
ModifyPortalContent
,
'setVersionPriorityList'
)
def
setVersionPriorityList
(
self
,
v
alu
e
):
def
setVersionPriorityList
(
self
,
v
ersion_priority_tupl
e
):
"""
XXX-arnau: must be written through an interaction workflow when ERP5Site
will become a real ERP5 object...
"""
if
not
isinstance
(
v
alu
e
,
tuple
):
v
alue
=
tuple
(
valu
e
)
if
not
isinstance
(
v
ersion_priority_tupl
e
,
tuple
):
v
ersion_priority_tuple
=
tuple
(
version_priority_tupl
e
)
self
.
_version_priority_list
=
value
# erp5 version must always be present, thus add it at the end if it's not
# already there
for
version_priority
in
version_priority_tuple
:
if
version_priority
.
split
(
'|'
)[
0
].
strip
()
==
'erp5'
:
break
else
:
version_priority_tuple
=
version_priority_tuple
+
(
'erp5 | 0.0'
,)
self
.
_version_priority_list
=
version_priority_tuple
# Reset cached value of getVersionPriorityNameList() if present
try
:
...
...
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