feature request: change permissions of selected objects
Dear zope, I would be grateful if somebody could help me with a problem: I want to be able to change the permissions of several zope objects at the same time. I am a medic and run a wiki under zope (mathis.heydtmann.de/WikiLiver) which has some pages I want my students to edit (I use the same Wiki as presentation tool, as lecturenotes and as alternative of handouts). But there are also some pages (for example drug dosages) which I don't want people to edit. I have now about 100 pages which I want to write protect in that way. An elegant solution would be being able to click on the pages, then have a button at the botton (like the one "rename") which leads to the normal Zope Security display to set the permissions for all of the selected pages. (In my context a button for print selected pages would also be useful.) I suppose other people would like to do similar things and I would be grateful if somebody could help me with it. Thanks for your help. Mathis
Hi, Is there any method which can restore the HTML-form tags from the REQUEST.form? I mean if REQUETS.form = {'key1': value1, 'key2':[value2-1, value2-2]} I can get: <input name="key1" type=hidden value="value1"> <input name="key2:list" type=hidden value="value2-1"> <input name="key2:list" type=hidden value="value2-2"> It's convenient for me to pass data between several forms , such like the steps in a "wizard". Thanks. Iap, Singuan
there is no automatic way to do it, you would have to create those tags manually. obviously that sounds like a bad kludge. use the sessioning functionality in zope instead. grab the session associated with the current user and store data in there. when the last form has been submitted read them all back out of the session for processing. jens On Tuesday, Aug 27, 2002, at 03:26 US/Eastern, <iap@y2fun.com> wrote:
Hi, Is there any method which can restore the HTML-form tags from the REQUEST.form? I mean if REQUETS.form = {'key1': value1, 'key2':[value2-1, value2-2]} I can get: <input name="key1" type=hidden value="value1"> <input name="key2:list" type=hidden value="value2-1"> <input name="key2:list" type=hidden value="value2-2">
It's convenient for me to pass data between several forms , such like the steps in a "wizard".
Thanks. Iap, Singuan
M HEYDTMANN writes:
... I have now about 100 pages which I want to write protect in that way. An elegant solution would be being able to click on the pages, then have a button at the botton (like the one "rename") which leads to the normal Zope Security display to set the permissions for all of the selected pages. Then do it:
The source for the page with the "rename" button in "OFS/dtml/main.dtml". Copy and customize it, give it an additional "change_access" button (or, better, replace all existing buttons with the "change_access"). Use a Python Script as the forms action. It iterates through the selected objects and sets their permission. How to do this, you can learn by looking at "AccessControl/DTM/access.dtml".
(In my context a button for print selected pages would also be useful.) I expect, you mean printing at your desktop, not the server?
This can only be prepared by Zope (it does not control your desktop printer). You form action would build a composite view of all selected objects and send it to the browser. There, you can press "print". Dieter
participants (4)
-
Dieter Maurer -
iap@y2fun.com -
Jens Vagelpohl -
M HEYDTMANN