Opened 12 years ago

Last modified 12 years ago

#393 closed enhancement

Add widgets to workspace — at Version 1

Reported by: pmartin Owned by: adube
Priority: major Milestone: 1.2.0
Component: server Version: trunk
Keywords: bis-1.2.0 Cc:

Description (last modified by adube)

Currently

When using the XMLWorkspaceConfig, widgets that do not need to be linked to resources are always added to the UI. This is not always wanted.

Historical facts

We used to link all widgets to resources, regardless if that was useful or not, thus was a mean to control what we wanted or not.

This was really annoying because you needed to be sure that the resource linking them were always added (ACL read rights) otherwise the widgets were excluded. This was the case for widgets such as the toolbar, zoomslider, measuretools, etc.

An other way to include them was to have a dummy resource for that, but that was really annoying too.

This behavior disappeared when widgets received their "getMandatoryResourceOptionList" method. When it returns NULL, the widget doesn't need to be linked to resources, thus you no longer need to do so in the config. The only drawback is that from that moment on, they were always added to the UI.

Proposed fix

The XMLConfig driver doesn't need to be fixed.

For the XMLWorkspaceConfig driver, we could have a 'widgets' tag added to the workspace. When set, it defines the list of widgets to include. Only the widgets that don't need to be linked to resources would be added that way since those that required to do so are already listed in the resources.

When not set, add all widgets (as currently being done). This would stay the default behavior.

Change History (1)

comment:1 by adube, 12 years ago

Description: modified (diff)
Keywords: bis-1.2.0 added
Note: See TracTickets for help on using tickets.