[Zope] Re: verbose Security on 2.6.2?

Chris Withers chrisw at nipltd.com
Thu Sep 25 07:53:01 EDT 2003


Allen wrote:
> Well then what do you suggest as the best way to do this?

Sorry, Dieter was right, you can do what I did, but you'd need to do:

object.your_property.append(your_new_value)
object.your_property._p_changed=1

...which you can't do in protected code like python scripts.

> <dtml-if Submit>
>  <dtml-if textfield>
>   <dtml-call "REQUEST.set('day1',day1)">
>   <dtml-call "day1.append(textfield)">
>   <dtml-call "day1.sort()">
>   <dtml-call expr="jobfair200310.manage_changeProperties({'day1' : day1})">
>     </dtml-if>
> </dtml-if>

This isn't bad, but it'd be a lot neater as a python script ;-)

request=context.REQUEST
if request.get('Submit'):
   textfield = request.textfield
   if textfield:
     day1 = context.day1
     day1.append(textfield)
     day1.sort
     context.jobfair200310.manage_changeProperties(day1=day1)

cheers,

Chris




More information about the Zope mailing list