I have just upgraded our xWiki from 6.4.2 to 6.4.3 and noticed a change in
how group rights are handled. We have a main wiki with 6 subwikis. All
users are members of the main wiki. In order to allow users rights to a
subwiki, we add them into a group in the main wiki and then give that group
access on the subwiki. This worked great in 6.4.2, however with the upgrade
to 6.4.3, we get the following error when a user logs into a subwiki, even
though the user is in a group that has access to the subwiki.
(I have truncated the error message since it is long, but if you need more
of it I can include it)
Failed to execute the [include] macro. Click on this message for details.
org.xwiki.rendering.macro.MacroExecutionException: Current user
[xwiki:XWiki.TestUser] doesn't have view rights on document
[test:WikiManager.Dashboard]
at
org.xwiki.rendering.internal.macro.include.IncludeMacro.execute(IncludeMacro
.java:151)
at
org.xwiki.rendering.internal.macro.include.IncludeMacro.execute(IncludeMacro
.java:55)
at
org.xwiki.rendering.internal.transformation.macro.MacroTransformation.transf
orm(MacroTransformation.java:252)
at
org.xwiki.rendering.internal.transformation.DefaultRenderingContext.transfor
mInContext(DefaultRenderingContext.java:183)
at
org.xwiki.rendering.internal.transformation.DefaultTransformationManager.per
formTransformations(DefaultTransformationManager.java:94)
at
org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentD
isplayer.java:252)
at
org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentD
isplayer.java:125)
at
org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentD
isplayer.java:55)
at
org.xwiki.display.internal.DefaultDocumentDisplayer.display(DefaultDocumentD
isplayer.java:96)
at
org.xwiki.display.internal.DefaultDocumentDisplayer.display(DefaultDocumentD
isplayer.java:39)
at
org.xwiki.sheet.internal.SheetDocumentDisplayer.display(SheetDocumentDisplay
er.java:113).
Attempting to access a page within the subwiki gives this error:
Error
You are not allowed to view this document or perform this action.
Is the use of groups to give access to subwikis no longer allowed, or is
this an issue with 6.4.3? In our test environment, I took our 6.4.3 XWiki
and switched back to the 6.4.2 deployment and things worked as expected,
however that really isn't an option as all of the extensions have been
upgraded to 6.4.3.
If this isn't an issue with 6.4.3, then what is the best way to handle
delegating rights for users in our setup?
Thanks!
Charlie
---------- Forwarded message ----------
From: Marius Dumitru Florea <mariusdumitru.florea(a)xwiki.com>
Date: Wed, Mar 25, 2015 at 10:49 AM
Subject: Re: Fw : [xwiki-users] Fw : Re: ajax example
To: Pascal BASTIEN <pbasnews-xwiki(a)yahoo.fr>
On Tue, Mar 24, 2015 at 7:34 PM, Pascal BASTIEN <pbasnews-xwiki(a)yahoo.fr> wrote:
>
>> > For step 1: Don't print
>> > the JSON directly. You'll have escaping
>> > issues. In order to ensure the generated JSON
>> > is valid you should
>> > build the JSON in memory
>> > (using Velocity/Java maps, arrays and basic
>> > types) and then serialize it:
>> >
>> > $jsontool.serialize({
>> > "greeting": "Hello",
>> > "location": "World"
>> > })
>>
>> I agree but one* purpose was to use Vincent example on
>> this page: http://extensions.xwiki.org/xwiki/bin/view/Extension/Output+JSON
>> Perhaps we (who?) need to modify both pages?
>
> Anyway, do you prefer this code?
>
> {{velocity wiki="false"}}
> ## If AJAX call
> #if("$!request.outputSyntax" != '')
> $response.setContentType('application/json')
> #end
> #set($MyJsonData = {'greeting': 'Hello', 'location': 'World'})
> $jsontool.serialize($MyJsonData)
>
> {{/velocity}}
Definitely.
Thanks,
Marius
>
>
>>
>>
>> >
>> > For step 4:
>> > Don't hard-code the page URL and use the 'get'
>> > action
>> > instead of 'view' to avoid
>> > adding view statistics entries.
>> >
>> > var url = new
>> > XWiki.Document('JsonHello',
>> > 'Sandbox').getURL('get');
>>
>> Thxs I was too lazy to take too long time to find JS
>> function. :-)
>>
>> >
>> > Also, to avoid the need to
>> > URL-encode the request parameters you
>> > should
>> > pass them using an object not a string.
>> >
>> > var params = {
>> >
>> > 'xpage': 'plain',
>> >
>> > 'outputSyntax': 'plain'
>> > };
>> > $.get(url, params,
>> > function(data) {
>> > ...
>> > });
>>
>> Yes thxs you
>> => I uploaded/update my page
>>
>> (The worst is that I hate JS) :-)
>>
>>
>>
>> Pascal B
>>
>> >
>> > Hope this
>> > helps,
>> > Marius
>> >
>> >
>> > On Fri, Mar 20, 2015 at 8:26 PM, Pascal BASTIEN
>> > <pbasnews-xwiki(a)yahoo.fr>
>> > wrote:
>> > > Hello,
>> > >
>> > > Here, I provided an simple Ajax example to
>> > use in xwiki application:
>> > > http://extensions.xwiki.org/xwiki/bin/view/Extension/AJAX+example#Attachmen…
>> > > This mail on this list to validate that
>> > what I wrote is the best way (like suggest Vincent)
>> > >
>> > > Thxs.
>> > >
>> > > Pascal
>> > BASTIEN
>> > >
>> > >
>> > _______________________________________________
>> > > users mailing list
>> > > users(a)xwiki.org
>> > > http://lists.xwiki.org/mailman/listinfo/users
>> >
>> _______________________________________________
>> users mailing list
>> users(a)xwiki.org
>> http://lists.xwiki.org/mailman/listinfo/users
> > Do you mean $xwiki.activitystream. API is
> broken?
>
> I don't
> remember talking about the activity stream API :) I
probably because you didn't talk about it :-))
> don't
> really know it well enough to give
> advices on it.
Finally, I used another method who's working like I want:
{{velocity}}
#set ($MonStream=$xwiki.activitystream.getStreamName("Sandbox"))
##foreach ($MonEvent in $xwiki.activitystream.getEventsForUser("XWiki.Admin", false, 1500, 0))
#foreach ($MonEvent in $xwiki.activitystream.getEvents($MonStream, false, 1500, 0))
1. $MonEvent.getPage() - $MonEvent.getDisplayDate() - $MonEvent.getDate() - $MonEvent.getType() - $MonEvent.getPriority()
#if ($MonEvent.getPage() == "Sandbox.test3")
* Je supprime l'event
$xwiki.activitystream.deleteActivityEvent($MonEvent)
#end
#end
{{/velocity}}
Like I chatted with Vincent I know groovy is powerfull (except the fact that "With great power comes great responsibility" ;-) ), full example application in groovy missing (because required PR) and templates contains tons of nice velocity code. :-)
Thxs for your help / works :-)
> > For step 1: Don't print
> > the JSON directly. You'll have escaping
> > issues. In order to ensure the generated JSON
> > is valid you should
> > build the JSON in memory
> > (using Velocity/Java maps, arrays and basic
> > types) and then serialize it:
> >
> > $jsontool.serialize({
> > Â "greeting": "Hello",
> > Â "location": "World"
> > })
>
> I agree but one* purpose was to use Vincent example on
> this page: http://extensions.xwiki.org/xwiki/bin/view/Extension/Output+JSON
> Perhaps we (who?) need to modify both pages?
Anyway, do you prefer this code?
{{velocity wiki="false"}}
## If AJAX call
#if("$!request.outputSyntax" != '')
$response.setContentType('application/json')
#end
#set($MyJsonData = {'greeting': 'Hello', 'location': 'World'})
$jsontool.serialize($MyJsonData)
{{/velocity}}
>
>
> >
> > For step 4:
> > Don't hard-code the page URL and use the 'get'
> > action
> > instead of 'view' to avoid
> > adding view statistics entries.
> >
> > var url = new
> > XWiki.Document('JsonHello',
> > 'Sandbox').getURL('get');
>
> Thxs I was too lazy to take too long time to find JS
> function. :-)
>
> >
> > Also, to avoid the need to
> > URL-encode the request parameters you
> > should
> > pass them using an object not a string.
> >
> > var params = {
> > Â
> > 'xpage': 'plain',
> > Â
> > 'outputSyntax': 'plain'
> > };
> > $.get(url, params,
> > function(data) {
> > Â ...
> > });
>
> Yes thxs you
> => I uploaded/update my page
>
> (The worst is that I hate JS) :-)
>
>
>
> Pascal B
>
> >
> > Hope this
> > helps,
> > Marius
> >
> >
> > On Fri, Mar 20, 2015 at 8:26 PM, Pascal BASTIEN
> > <pbasnews-xwiki(a)yahoo.fr>
> > wrote:
> > > Hello,
> > >
> > > Here, I provided an simple Ajax example to
> > use in xwiki application:
> > > http://extensions.xwiki.org/xwiki/bin/view/Extension/AJAX+example#Attachmen…
> > > This mail on this list to validate that
> > what I wrote is the best way (like suggest Vincent)
> > >
> > > Thxs.
> > >
> > > Pascal
> > BASTIEN
> > >
> > >
> > _______________________________________________
> > > users mailing list
> > > users(a)xwiki.org
> > > http://lists.xwiki.org/mailman/listinfo/users
> >
> _______________________________________________
> users mailing list
> users(a)xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users
> Some comments:
Thxs
>
> For step 1: Don't print
> the JSON directly. You'll have escaping
> issues. In order to ensure the generated JSON
> is valid you should
> build the JSON in memory
> (using Velocity/Java maps, arrays and basic
> types) and then serialize it:
>
> $jsontool.serialize({
> Â "greeting": "Hello",
> Â "location": "World"
> })
I agree but the purpose was to use Vincent example on this page: http://extensions.xwiki.org/xwiki/bin/view/Extension/Output+JSON
Perhaps we (who?) need to modify both pages?
>
> For step 4:
> Don't hard-code the page URL and use the 'get'
> action
> instead of 'view' to avoid
> adding view statistics entries.
>
> var url = new
> XWiki.Document('JsonHello',
> 'Sandbox').getURL('get');
Thxs I was too lazy to take too long time to find JS function. :-)
>
> Also, to avoid the need to
> URL-encode the request parameters you
> should
> pass them using an object not a string.
>
> var params = {
> Â
> 'xpage': 'plain',
> Â
> 'outputSyntax': 'plain'
> };
> $.get(url, params,
> function(data) {
> Â ...
> });
Yes thxs you
=> I uploaded/update my page
(The worst is that I hate JS) :-)
Pascal B
>
> Hope this
> helps,
> Marius
>
>
> On Fri, Mar 20, 2015 at 8:26 PM, Pascal BASTIEN
> <pbasnews-xwiki(a)yahoo.fr>
> wrote:
> > Hello,
> >
> > Here, I provided an simple Ajax example to
> use in xwiki application:
> > http://extensions.xwiki.org/xwiki/bin/view/Extension/AJAX+example#Attachmen…
> > This mail on this list to validate that
> what I wrote is the best way (like suggest Vincent)
> >
> > Thxs.
> >
> > Pascal
> BASTIEN
> >
> >
> _______________________________________________
> > users mailing list
> > users(a)xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
>
The XWiki development team is proud to announce the availability of
XWiki 7.0 Release Candidate 1.
The version is mostly about stabilization before 7.0 final. It
contains diff UI improvements, Extension Repository improvements, a
new component based watchlist module, a new application to edit wiki
skins. XWiki also moved to Servlet 3.0.1 which means various old
application servers versions are not supported anymore.
You can download it here: http://www.xwiki.org/xwiki/bin/view/Main/Download
Make sure to review the release notes:
http://www.xwiki.org/xwiki/bin/view/ReleaseNotes/ReleaseNotesXWiki70RC1
Thanks
-The XWiki dev team
I would like to create a Javascript application in XWiki.
My precise goal is to go get some content from Jenkins (build status)
and render it over a static image using d3.js or any other rich
rendering framework.
I suppose the only way to implement that is to write my webpage as HTML.
But, then, how will I use external frameworks ? (typically d3.js)
Thanks
--
Nicolas Delsaux
Hi,
I'm in organization where we have 3 unsynchronized wikis, implemented
using the software named in subject (ie JSPWiki/DokuWiki/mediawiki).
I would like to merge their content in one unique wiki, obviously
implemented using XWiki (due to the excellent interview Vincent Massol
and Ludovic Dubost gave to the castcodeurs podcast).
I have seen there are extensions to have content of those legacy wiki
imported into XWiki.
However, i'm not sure I understand how they work.
1 - JSPWiki to XWiki
There seems to be an old (?) extension at
http://extensions.xwiki.org/xwiki/bin/view/Extension/JSPWiki+To+XWiki+Conve…,
documented by Vincent Massol. From what I understand, the Java code in
this extension has to be compiled independently, and run as a
stand-alone program on the machine hosting the JSPWiki server. It will
generate a XAR that can be injected into XWiki. Am I right ? If so, it
is hardly an extension of XWiki, but rather a companion program (but I'm
nitpicking). However, as a stand-alone program, isn't it available as an
executable JAR somewhere ?
2 - Dokuwiki to XWiki
This time, it's a valid XWiki extension :
http://extensions.xwiki.org/xwiki/bin/view/Extension/Import+DokuWiki+into+X…
which is easily installable using Extension manager (cool !). However, I
wonder how it will work with XWiki 6.4.2 ...
3 - mediawiki to XWiki
This time ... it seems like there is no extension. or is it ?
bonus - xwiki-OLD to xwiki
We also have some content in an old (5.0.1) version of XWiki. How do I
migrate ?
Conclusion - cheers
I must confess I had never tried before XWiki, and my first impression
is that it's a robust and perfectly usable wiki solution. The XWiki team
did a really impressive work.
--
Nicolas Delsaux