Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5-Boxiang
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
Hamza
erp5-Boxiang
Commits
6baf7df4
Commit
6baf7df4
authored
Dec 23, 2011
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Really fix getId/getTitle of broken objects
Commit
aa8e9a60
broke testBusinessTemplate
parent
5f6c557a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
product/ERP5Type/dynamic/lazy_class.py
product/ERP5Type/dynamic/lazy_class.py
+9
-3
No files found.
product/ERP5Type/dynamic/lazy_class.py
View file @
6baf7df4
...
...
@@ -28,10 +28,16 @@ class ERP5BaseBroken(Broken, ERP5Base):
d
=
dict
(
PersistentBroken
.
__dict__
,
**
d
)
for
x
in
'__dict__'
,
'__metaclass__'
,
'__weakref__'
:
del
d
[
x
]
def
get
(
*
args
):
return
lambda
self
:
self
.
__dict__
[
'__Broken_state__'
].
get
(
*
args
)
def
get
(
x
):
def
get
(
self
):
d
=
self
.
__dict__
try
:
return
d
.
get
(
'__Broken_state__'
,
d
)[
x
]
except
KeyError
:
return
getattr
(
self
.
__class__
,
x
)
return
property
(
get
)
for
x
in
'id'
,
'title'
:
d
[
x
]
=
property
(
get
(
x
,
getattr
(
ERP5Base
,
x
,
None
))
)
d
[
x
]
=
get
(
x
)
return
type
(
name
,
base
,
d
)
def
__getattr__
(
self
,
name
):
...
...
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