Commit 8a6cf5c1 authored by Andreas Jung's avatar Andreas Jung

Collector #905: Locked objects can no longer be renamed

parent 0be58301
...@@ -80,9 +80,9 @@ Zope Changes ...@@ -80,9 +80,9 @@ Zope Changes
This restricts access to the Control_Panel and especially This restricts access to the Control_Panel and especially
to the Products management to trusted users. to the Products management to trusted users.
- Cut & Delete operations on locked objects (WebDAV) are no longer - Rename, Cut & Delete operations on locked objects (WebDAV) are
permitted and will raise an exception. Copies of locked objects no longer permitted and will raise an exception. Copies of
are copied without lock. locked objects are copied without lock.
- Collector #634: Image objects can now be rendered without border - Collector #634: Image objects can now be rendered without border
attribute by calling "image.tag(border='')". attribute by calling "image.tag(border='')".
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
# #
############################################################################## ##############################################################################
__doc__="""Copy interface""" __doc__="""Copy interface"""
__version__='$Revision: 1.84 $'[11:-2] __version__='$Revision: 1.85 $'[11:-2]
import sys, Globals, Moniker, tempfile, ExtensionClass import sys, Globals, Moniker, tempfile, ExtensionClass
from marshal import loads, dumps from marshal import loads, dumps
...@@ -237,6 +237,8 @@ class CopyContainer(ExtensionClass.Base): ...@@ -237,6 +237,8 @@ class CopyContainer(ExtensionClass.Base):
message=sys.exc_info()[1], message=sys.exc_info()[1],
action ='manage_main') action ='manage_main')
ob=self._getOb(id) ob=self._getOb(id)
if ob.wl_isLocked():
raise ResourceLockedError, 'Object "%s" is locked via WebDAV' % ob.getId()
if not ob.cb_isMoveable(): if not ob.cb_isMoveable():
raise CopyError, eNotSupported % id raise CopyError, eNotSupported % id
self._verifyObjectPaste(ob) self._verifyObjectPaste(ob)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment