I would like to build a menu structure such as this (example is simplified - note that the lack of formatting hides indentation of nested menu-items):
<root description="some menu">
<menu-item label="Our Organisation">
<menu-item label="About Us"/>
<menu-item label="Corporate Publications"/>
</menu-item>
<menu-item label="Resources for Employees">
<menu-item label="Induction"/>
<menu-item label="Your Well-Being">
<menu-item label="Staff Care Services"/>
</menu-item>
</menu-item>
</root>
<menu-item> can be nested to arbitrary depth.
I have attempted to build a DCT to capture this structure:
<?xml version="1.0" encoding="UTF-8"?>
<data-capture-requirements dcr-validation="none" name="">
<ruleset name="dct">
<root-container location="root" name="root">
<item name="description" pathid="
@description">
<label>Description</label>
<description/>
<text required="t"/>
</item>
<container location="menu-item" name="menu-item" refid="menu-item" min="0" max="unbounded">
<label>Menu-item</label>
<description/>
<item name="name" pathid="
@name">
<label>Label</label>
<description/>
<text required="t"/>
</item>
<container location="" name="menu-item" min="0" max="unbounded">
<itemref refid="menu-item" min="0" max="unbounded"/>
</container>
</container>
</root-container>
</ruleset>
</data-capture-requirements>
But this does not perform as expected - menu-items cannot be added to the nested container.
I need to minimize the use of containers, because nested menu-items get unwieldy.
I am using datacapture6.0.dtd
There may be a different way to do this kind of thing. Any suggestions would be greatly appreciated.
Thanks
Russell