[Zope-CMF] Administering CMF discussions

pieter.claerhout@pandora.be pieter.claerhout@pandora.be
Tue 22 Jan 2002 02:59:22 MET


Hi Tres and the others,

I now upgraded to the final version of CMF 1.2 on my server, but I still
can't get the deleteReply thing to work. I tried the script you provided
last time, but that didn't seem to work:

   ## Script (Python) "discitem_delete"
   ## parameters=
   ## title=Delete discussion item
   parent = context.inReplyTo()
   talkback = context.portal_discussion.getDiscussionFor()
   talkback.deleteReply( context.getId() )

   context.REQUEST['RESPONSE'].redirect( parent.absolute_url()
             + '?portal_status_message=Reply+deleted' )

but it fails to get the talkback object, since it requires an argument,
and I'm not sure which argument I should specify. I tried container and
context, but both didn't work. Also the value I get for parernt is weird
since I get the discussion item itself, not the object it was a 
discussion item for.

Am I doing something wrong here? If so, what should I do differently?
Can you please give me instructions where I should could look else, since
I kind of urgently need to have this thing working...

Thanks in advance.


Pieter

------------------------
 Tres Seaver <tseaver@zope.com> wrote:
------------------------
	
>Pieter Claerhout wrote:
>
>> This doesn't seem to work for CMF 1.1, is there a way around?
>
>
>The 'deleteReply' method was added to the talkback object after
>CMF 1.1 was released.  If you truly can't upgrade to CMF 1.2b2
>(which is virtually identical to the 1.2 we will be releasing
>this week), then you might be able to construct an ExternalMethod
>which does the same thing.  The patch for the revision which added
>the 'deleteReply' method is available at:
>
>   http://cvs.zope.org/CMF/CMFDefault/DiscussionItem.py.diff?r1=1.19&r2=1.20
>
>Tres.
>-- 
>===============================================================
>Tres Seaver                                tseaver@zope.com
>Zope Corporation      "Zope Dealers"       http://www.zope.com
>
>
>_______________________________________________
>Zope-CMF maillist  -  Zope-CMF@zope.org
>http://lists.zope.org/mailman/listinfo/zope-cmf
>
>See http://www.zope.org/Products/PTK/Tracker for bug reports and feature requests
>