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
Labels
Merge Requests
138
Merge Requests
138
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
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
3742e09b
Commit
3742e09b
authored
Dec 05, 2017
by
Ayush Tiwari
Committed by
Ayush Tiwari
Apr 17, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BusinessManager: No need to create new Id for objects in Business Item
parent
86ea1af6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
product/ERP5/Document/BusinessManager.py
product/ERP5/Document/BusinessManager.py
+5
-2
No files found.
product/ERP5/Document/BusinessManager.py
View file @
3742e09b
...
...
@@ -777,8 +777,11 @@ class BusinessItem(XMLObject):
_recursiveRemoveUid
(
obj
)
obj
=
aq_base
(
obj
)
obj
.
isIndexable
=
ConstantGetter
(
'isIndexable'
,
value
=
False
)
new_id
=
self
.
generateNewId
()
self
.
_setObject
(
new_id
,
obj
,
suppress_events
=
True
)
# In general, one Business Item only has one object in it, so we never end
# up in conflict as we'll always be having its unique path(due to GUID of
# Business Item), thus we can just use object Id as it is while making it
# a sub-object of Business Item
self
.
_setObject
(
obj
.
id
,
obj
,
suppress_events
=
True
)
def
_resolvePath
(
self
,
folder
,
relative_url_list
,
id_list
):
"""
...
...
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