Hi Marius,
On 3 Oct 2014 at 10:43:59, Marius Dumitru Florea
(mariusdumitru.florea@xwiki.com(mailto:mariusdumitru.florea@xwiki.com)) wrote:
Hi devs,
Following the vote on
http://lists.xwiki.org/pipermail/devs/2014-September/057560.html I
started working on a generic tree widget based on jsTree. I'm almost
done now and I'm wondering where's the best place to commit my work.
There are 3 parts:
(1) A generic JavaScript tree widget (used by all trees)
The common practice so far was to put the new JavaScript code in
xwiki-platform-web (resources/uicomponents). But since we started
using webjars I'm wondering if it's not better to create a webjar. The
advantage is that the applications will be able to explicitly declare
a dependency on the tree widget. The downside is that the JavaScript
code is a bit harder to modify. Another option is to put the tree
widget in a JSX object but we may need to use it in Velocity templates
also (e.g. the report step of the DW).
I prefer the webjar.
I also prefer the webjar option.
(2) A couple of wiki pages that define specific
trees:
* One page for the All Docs Tree (space-page-child)
* One page for the XWiki Entity Tree
(wiki-space-page-[translations|attachments|objects|properties|sections])
* One page for the Hierarchy Tree (page-child)
* One page for the XAR import tree (space-page)
* others later maybe
I'm hesitating between creating a dedicated module
(xwiki-platform-tree-ui) and putting them in existing modules like the
xwiki-platform-index.
I prefer a lot to have them in the existing modules where they are used. We’ve been trying
to organize our modules by functional domains instead of technical domains.
(3) A couple of jobs (Java code) to perform tree
operations that can
take time, like deleting or renaming a space.
For these I could use the xwiki-platform-refactoring module since they
are generic operations, not limited to trees. We have a Delete space
entry in the top menu and we probably want a Rename space one.
Indeed that could be a good idea (for now).
Thanks
-Vincent
WDYT?
Thanks,
Marius