[Zapp-cvs-commit] ZApp/skins/zapp_generic zapp_cmf_object_edit.py,1.4,1.5
Brought to you by:
sspickle
|
From: <ssp...@us...> - 2003-11-24 16:45:38
|
Update of /cvsroot/zapp/ZApp/skins/zapp_generic
In directory sc8-pr-cvs1:/tmp/cvs-serv27366/skins/zapp_generic
Modified Files:
zapp_cmf_object_edit.py
Log Message:
fixe up rediection and status message
Index: zapp_cmf_object_edit.py
===================================================================
RCS file: /cvsroot/zapp/ZApp/skins/zapp_generic/zapp_cmf_object_edit.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** zapp_cmf_object_edit.py 28 Oct 2003 20:27:04 -0000 1.4
--- zapp_cmf_object_edit.py 24 Nov 2003 16:45:35 -0000 1.5
***************
*** 5,15 ****
##bind script=script
##bind subpath=traverse_subpath
! ##parameters=inputDict=None
##title=
##
title=context.REQUEST.get('title',None)
if title is not None:
! context.manage_changeProperties(title=title)
myApp = context.getApplication()
--- 5,20 ----
##bind script=script
##bind subpath=traverse_subpath
! ##parameters=inputDict=None, redirect_url=None
##title=
##
+ propDict = {'cmf_portal_type':getattr(context,'portal_type','unknown')}
+
title=context.REQUEST.get('title',None)
+
if title is not None:
! propDict['title'] = title
!
! context.manage_changeProperties(propDict)
myApp = context.getApplication()
***************
*** 59,62 ****
context.safeMiscData.setXMLAttrs(dict = dict)
! context.REQUEST.RESPONSE.redirect('zapp_cmf_object_edit_form?portal_status_message=ZApp+CMF+Object+Changed.')
--- 64,71 ----
context.safeMiscData.setXMLAttrs(dict = dict)
+ context.reindexObject()
! if not redirect_url:
! redirect_url=context.absolute_url() + '/zapp_cmf_object_edit_form?portal_status_message=ZApp+CMF+Object+Changed.'
!
! context.REQUEST.RESPONSE.redirect(redirect_url)
|