[ZCM] [ZC] 455/ 2 Reject "Locking Support in Image.py"
Collector: Zope Bugs, Features,
and Patches ...
zope-coders-admin at zope.org
Tue Oct 21 09:23:10 EDT 2003
Issue #455 Update (Reject) "Locking Support in Image.py"
Status Rejected, Zope/bug medium
To followup, visit:
http://collector.zope.org/Zope/455
==============================================================
= Reject - Entry #2 by regebro on Oct 21, 2003 9:23 am
Status: Pending => Rejected
A WebDAV client would edit the file via PUT, not via manage_edit. PUT uses the correct ifhandler. (Thanks to Tres for pointing this out).
________________________________________
= Request - Entry #1 by Anonymous User on Jul 4, 2002 8:36 am
In the current version, the "manage_upload" and "manage_edit" method of the "File" class only check if the file is locked, but don't allow editing by the person who initially locked the file.
The patch for this is simple:
1. add "from webdav.Resource import Resource" to your import statements
2. add "Resource" to the list of parent classes of the "File" class
3. change "if self.wl_isLocked():" to "if self.wl_isLocked() and not self.dav__simpleifhandler(request=REQUEST,response=None):" in the methods "manage_upload" and "manage_add"
Now the person who locked the file can also edit it without releasing the lock (if he sends the Lock-Token in the WebDAV If-Header with the request)
==============================================================
More information about the Zope-Collector-Monitor
mailing list