[opencms-dev] Nested placable content-objects, similar to group containers: which is the best/recommended way?

János Fekete jan at fjan.eu
Tue May 7 10:46:24 CEST 2013


Hi everyone!

I'm new to OpenCms and even to Java-based web development. I spent the past
few month to learn both, but still novice, so my questions may be trivial
for you.

So for the current tasks, I'm not really sure anymore that it's doable with
OpenCms (I mean OpenCms and not doing it in Java+js/gwt than make it
compatible with OpenCms. I want to use purely OpenCms for creating dialogs,
saving/showing/placing contents by their xsd/formatter.)

I need to create 2 placeable types: LinkArea and LinkTabArea. Same content
may/will come up multiple times on the same page with different formatting.
(right-navigation columns, dialog layers, navigation toolbar as multi-level
menus)

LinkArea and LinkTabArea have Title and formatting settings. (show title,
box-type)
LinkAreas contain at least one LinkGroup. LinkTabArea contain 2-4 tabs
(each having a Label as title and formatting setting which is the default
open) also the tab-content contains at least one LinkGroup (which have
different formatter for this placement).
LinkGroup contains at least one Link, and can contain Label or Separator,
but nothing else.
Link and Label are the atomic types, they have title (and for Link:
url/type/traget) which have multiple locale variants.
The content-admin must be able to drag-and-drop LinkGroups to
LinkTabArea>tabs / LinkAreas, and Labels/Links to LinkGroups. -- Or
something equally easy and trivial to use.

The localization: the page needs to have at least two full locale, a third
partial locale and the option to add any number of new locales. The page
must be the exact same for each locale, if a content-type don't have
content for the current locale, than defaults back to English. -- This is
so far ready with setting OpenCms to always show the English content, and
creating a taglib, which can switch the language inside the formatters.
(Also overridden bundle system for static texts.)

The content-administration must be trivial and intuitive: without training
the admin needs to know/figure out how to do tasks.  (Opening the editor
must only be for the purpose to change the "strings" in locales.)

So far I tried several methods already, none of them seems to be a right
way to follow:
- Creating nested xsd -> you need to edit the contents, unusable for
multiple locales, can't place same linkgroups/links to multiple places.
- Creating containers in formatters (container id is the CMSUUID)-> needs
page reload for each new type, can't place the same content with different
formatter on same page, can't place same content to other page.
- Formatters create a group-element: can't open it for edit.
- Overriding group-containers: Well, 'groupcontainer'/'inheritancegroup'
types are hardcoded by type-name, and not extendable. When i tried to add a
new type  even the original element-groups became unusable. (I tried by
updating the isGroupContainer / similar methods in a bunch of classes and
extending classes from original GroupContainer classes. Also adding this
kind of support for OpenCms is way more than my job description.)
- Using Iframes to create-subpages for each contents: can't found a way to
dynamically add/remove/fill container areas to the responder iframe-pages.
Without that the editor won't load, so can't drag/edit elements in
LinkGroups.
- Creating a gallery for LinkGroups, and add it on editing the
LinkTabArea/LinkArea with editor: drag-n-drop concept broken,
previews/selecting content is very confusing. Also can't create new
LinkGroups this way, can't open LinkGroups to edit (so fill it with
Links/Lables/Separators the same way)
- Adding Pure JS handlers and simply place an original group container and
add the extended funtionalities by JS: Gwt is unsuable for that. (there is
no way to know what to send/expect in an rcp request inited from simply JS.
- There are no native funcions for OpenCms and the rest is obfuscated.)
- Creating JS/Java sub-servlet to handle these functionalities: again,
adding an alternative editor for OpenCms is not my job.

So what is the ideal (and easiest) way to do this in OpenCms?
Is this a task even doable with OpenCms (without/minimal core-file changes)?
I read some blurry post somewhere, that Alkacon promises group-container
support in the upcoming releases, but the sources on git are hardly touched
in the past few month - so should I wait for those releases? (Or maybe I
misunderstood it, and they only meant 8.x's group container support and
nothing else.)

Best regards,
Jan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20130507/9d50c35d/attachment.htm>


More information about the opencms-dev mailing list