Re: API for setting/getting values on Dexterity content
Robert Niederreiter <rnix-vzgNpXZZ1Rwgm7i/[email protected]>
| Newsgroups | gmane.comp.web.zope.plone.devel |
|---|---|
| Message-ID | <[email protected]> |
Am 2014-10-22 um 14:10 schrieb Robert Niederreiter:
>
> Am 2014-10-22 um 14:07 schrieb Andreas Jung:
>> plone.api.content.set_value(obj, fieldname, value,
>>> behavior='behavior_name')
> and this looks better than
>
> obj.behaviors('name').attr = value
>
> ?
to complete my thought. Instead of extending plone.api and include
andreas concerns a getter/setter object could be implemented living on
the content object under ``attrs``. Inside this object schema
introscection might be computed and the behaviors iterated. the above
lokks then
obj.attrs.title = value
robert
>
>
> ------------------------------------------------------------------------------
> Comprehensive Server Monitoring with Site24x7.
> Monitor 10 servers for $9/Month.
> Get alerted through email, SMS, voice calls or mobile push notifications.
> Take corrective actions from your mobile device.
> http://p.sf.net/sfu/Zoho
> _______________________________________________
> Plone-developers mailing list
> Plone-developers-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> https://lists.sourceforge.net/lists/listinfo/plone-developers
------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho