Changeset 213
- Timestamp:
- 01/26/06 08:42:20
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
qPloneComments/trunk/skins/qplonecomments/discussion_publish_comment.py
r212 r213 5 5 ##bind script=script 6 6 ##bind subpath=traverse_subpath 7 ##parameters= obj=None7 ##parameters=reply=None 8 8 ##title= 9 9 ## 10 10 from Products.CMFPlone import transaction_note 11 11 from Products.qPloneComments.utils import publishDiscussion 12 from Products.qPloneComments.utils import publishDiscussion, send_email 13 14 if reply is None: 15 reply=context 12 16 13 17 # Publish discussion item 14 18 publishDiscussion(context) 15 19 20 # Send notification e-mail 21 send_notification_message = send_email(reply, container, state="published") 22 23 # Inform user about awaiting moderation 24 portal_status_message='Comment+successfully+published' 25 16 26 transaction_note('Published discussion item') 17 target = '%s/%s' % (context.absolute_url(), context.getTypeInfo().getActionById('view') ) 27 target = '%s/%s?portal_status_message=%s' % (context.absolute_url(), context.getTypeInfo().getActionById('view'), 28 portal_status_message) 18 29 19 30 return context.REQUEST.RESPONSE.redirect(target) qPloneComments/trunk/skins/qplonecomments/published_comment_template.pt
r212 r213 3 3 tal:define="charset here/portal_properties/site_properties/default_charset|string:utf-8; 4 4 dummy python:request.RESPONSE.setHeader('Content-Type', 'text/html;;charset=%s' % charset); 5 firm options/firm"5 organization_name options/organization_name" 6 6 >To: <tal:x replace="options/mto"/> 7 7 From: <tal:x replace="options/mfrom"/> 8 Subject: <tal:x condition=" firm" replace="string:[$firm] "/>New comment added8 Subject: <tal:x condition="organization_name" replace="string:[$organization_name] "/>New comment added 9 9 10 10 <tal:x define="obj nocall:options/obj"> … … 14 14 15 15 -- 16 <tal:x condition=" firm" replace="string:$firm"/>Support Team.16 <tal:x condition="organization_name" replace="string:$organization_name "/>Support Team. 17 17 18 18 </div>
