Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ayush Tiwari
erp5
Commits
5e17819e
Commit
5e17819e
authored
Nov 22, 2017
by
Ayush Tiwari
Committed by
Ayush Tiwari
Apr 17, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add _delPropValue which can be used to del property value without deleting the proeprty itself
parent
0db17646
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
0 deletions
+10
-0
product/ERP5Type/Base.py
product/ERP5Type/Base.py
+7
-0
product/ERP5Type/Core/Folder.py
product/ERP5Type/Core/Folder.py
+3
-0
No files found.
product/ERP5Type/Base.py
View file @
5e17819e
...
...
@@ -789,6 +789,13 @@ class Base( CopyContainer,
pformat
(
rev1
.
__dict__
),
pformat
(
rev2
.
__dict__
)))
def
_delPropValue
(
self
,
property_name
):
if
self
.
hasProperty
(
property_name
):
value
=
None
if
property_name
.
endswith
(
'_list'
):
value
=
[]
self
.
_setPropValue
(
property_name
,
value
)
def
_aq_dynamic
(
self
,
id
):
# ahah! disabled, thanks to portal type classes
return
None
...
...
product/ERP5Type/Core/Folder.py
View file @
5e17819e
...
...
@@ -627,6 +627,9 @@ class Folder(CopyContainer, CMFBTreeFolder, CMFHBTreeFolder, Base, FolderMixIn,
Title
=
Base
.
Title
_setPropValue
=
Base
.
_setPropValue
_propertyMap
=
Base
.
_propertyMap
# are there any others XXX ?
# Required while Business Manager installation. Better to rely on properties
# from property sheet than on the attributes
_delPropValue
=
Base
.
_delPropValue
PUT_factory
=
None
# XXX Prevent inheritance from PortalFolderBase
description
=
None
...
...
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