Back to index

plone3  3.1.7
Functions
plone.app.iterate.subscribers.locking Namespace Reference

Functions

def handleWCDeleted
def handleCheckout
def handleCheckin
def handleCancelCheckout

Function Documentation

Definition at line 45 of file locking.py.

00045 
00046 def handleCancelCheckout( event ):
00047     lockable = ILockable( event.object )
00048     if lockable.locked():
00049         # unlock working copy if it was auto-locked, or this will fail
00050         lockable.clear_locks()
00051     lock.unlockContext( event.baseline )
00052     event.baseline.reindexObject( idxs=['review_state'] )    
00053         
00054     

Definition at line 39 of file locking.py.

00039 
00040 def handleCheckin( event ):
00041     lockable = ILockable( event.object )
00042     if lockable.locked():
00043         # unlock working copy if it was auto-locked, or this will fail
00044         lockable.clear_locks()
    

Definition at line 35 of file locking.py.

00035 
00036 def handleCheckout( event ):
00037     lock.lockContext( event.object )
00038     event.object.reindexObject( idxs=['review_state'] )
    

Definition at line 29 of file locking.py.

00029 
00030 def handleWCDeleted( event ):
00031     # may be called multiple times, must be reentrant
00032     lock.unlockContext( event.baseline )
00033     # we reindex to force a metadata update
00034     event.baseline.reindexObject( idxs=['review_state'] )