[CMF-checkins] CVS: CMF/CMFDefault/skins/zpt_generic - rejectItems.py:1.1.2.1
Tres Seaver
tseaver@zope.com
Tue, 23 Jul 2002 15:29:16 -0400
Update of /cvs-repository/CMF/CMFDefault/skins/zpt_generic
In directory cvs.zope.org:/tmp/cvs-serv11118/CMFDefault/skins/zpt_generic
Added Files:
Tag: CMF-1_3-branch
rejectItems.py
Log Message:
- Add missing skin method to support 'review' template.
=== Added File CMF/CMFDefault/skins/zpt_generic/rejectItems.py ===
## Script (Python) "rejectItems"
##bind container=container
##bind context=context
##bind namespace=
##bind script=script
##bind subpath=traverse_subpath
##parameters=items, comment=''
##title=
##
wf_tool = context.portal_workflow # XXX getToolByName
for path in items:
object = context.restrictedTraverse( path )
wf_tool.doActionFor( object, 'reject', comment=comment )
context.REQUEST[ 'RESPONSE' ].redirect( '%s/review?%s'
% ( context.portal_url()
, 'portal_status_message=Items+rejected.'
) )