Forum OpenACS Development: Re: xowiki 0.47

Collapse
24: Re: xowiki 0.47 (response to 23)
Posted by Gustaf Neumann on
In order to allow only side wide administrators to edit ::xowiki::Object, you can simply use ::xowiki::policy2 instead of ::xowiki::policy1. The policy is a package parameter (called security_policy), so there is no need to edit the source files for such a feature.

For more details, see http://alice.wu-wien.ac.at:8000/xowiki-doc/#security-management

Collapse
25: Re: xowiki 0.47 (response to 24)
Posted by Byron Linares on
I am writing a new policy for my instance of xowiki
I want that only site Wide admin Can Create a ::xowiki::PageTemplate
And xowiki::Object but policy2 only cover the edit part,
In my policy I am try set permission for create this object like this

Policy policyb -contains {

Class Package -array set require_permission {
reindex swa
rss swa
google-sitemap none
google-sitemapindex none
delete {{id admin}}
edit-new {{{has_class ::xowiki::Object} swa} {id create}}
}
.
.
.
.

when I change the security_policy parameter and set my new policy I get and error that i describe in a previous post

http://openacs.org/forums/message-view?message_id=1048796

my question is how can I restrict the creation or edit-new for only site Wide admin for this tow (a ::xowiki::PageTemplate And xowiki::Object)

Other question is :
There is a way for page ordering in wiki 0.47
I have set the parameter display_page_order and fill the section field in creations forms but I can figured a way to order those pages
in the xowiki side menu

thack for you help.

Byron

Collapse
26: Re: xowiki 0.47 (response to 25)
Posted by Gustaf Neumann on
The relevant line in the policy should read

edit-new {{{has_class ::xowiki::Object} swa} {{has_class ::xowiki::PageTemplate} swa} {id create}}

This works with the current versions of xowiki. If you get still an error with this definition, upgrade to a slightly newer version (0.48, version of March 10) where i refactored much of the policy stuff (update both, xowiki and xotcl-core to the version of the same day).

Concerning your question about page ordering: i assume, you have in the edit form the entry field and you provided some values for this. Simply type in the URL .../xowiki/book and you get the pages displayed (book is a prototype page, which is created on demand from the filesystem and is inserted into the content repository where you can edit it etc for every instance).

I have started to make an FAQ about xowiki: http://alice.wu-wien.ac.at:8000/xowiki-faq/

maybe this helps to answer some of the questions.

Collapse
27: Re: xowiki 0.47 (response to 26)
Posted by Byron Linares on
thacks gustaf,
the upgrade worcks for the policy part.