Hi,
I'm trying to force a contentbox to list documents using some local
metadata vocabulary ('Local Vocabularies Container' under CPS).
I have some trouble accessing the local vocabulary in
"contentbox_edit_form".
'Themes' is a property of my documents' metadata. It uses a local
vocabulary.
I tried to recycle some code used in the "advanced search form" but of
course it's using the locale 'here'.
<tr> <b>Choose some themes</b>
<select size="5" name="Themes:list" multiple="multiple"
tal:define="themes_set python:request.get('Themes', ());
all_themes python:here.getListFromVocabulary('themes_voc')">
<option value="" tal:attributes="selected not:themes_set"
i18n:translate="label_all">All</option>
<option
tal:repeat="item all_themes/items"
tal:attributes="value python:item[0];
selected python:item[0] in themes_set or None"
tal:content="python:item[1]"
i18n:translate=""></option>
</select>
</tr>
I need this chunk to use as context the folder I have chosen in
'contentbox_edit_form.' .
I tried modifying this to :
all_themes
python:box['box'].getListFromVocabulary('themes_voc')">
but it still lists the global vocabulary.
Any lead ?
Patrick CHAILLOUX
_______________________________________________
cps-devel mailing list
http://lists.nuxeo.com/mailman/listinfo/cps-devel