Hi Jerem,
On Mar 16, 2012, at 12:37 PM, jerem wrote:
Well, the answer was not so complex.
I took inspiration from the user registration code for this.
I created a distinct page, MySpace.MyObjectCreation, that is in charge of :
- showing the fields in edit mode for the new object to create
(/xwiki/bin/view/MySpace/MyObjectCreation)
- creating the new page and object and saving it
(/xwiki/bin/view/MySpace/MyObjectCreation?save=true). In this case it also
produces some XML output, so I can manage errors upon Ajax call return, and
update the redirectionUrl accordingly. This way the original page can nicely
show what happened, and display the new object.
The result is quite cool, and will be (one day ...) see-able in the Mail
Archive application I'm working on :)
I'm getting more and more eager about this one :)
WDYT about creating a project on xwiki-contrib for example where you could do your
commit?
This would allow us to see what's going on, i.e. slowly learn what you're doing
and possibly help you on some stuff.
If one day we wish to make this feature part of the platform it would be a prerequisite
that xwiki committers know the code.
If you're interested I can create a contrib git repository for you in just a few
minutes!
Thanks!
-Vincent