Drag-and-drop support
Contents |
A central operating concept in ContentCreator and SiteArchitect is the option to exchange data via a simple drag-and-drop system, e.g., from a report or (Windows) Desktop to a FirstSpirit input component. Data, such as data from reports, can be dragged not only to specific areas of the preview, but also to open forms. This means, for example, that an input component of FS_INDEX type can easily be populated with content from an external product database.
Visualization
Available drop targets are marked during the drag action in SiteArchitect and ContentCreator.
Drag actions on data types that are not compatible with the target are rejected. It is not possible to drop such objects. This is visualized appropriately, too.
In ContentCreator:
In SiteArchitect:
Transfer types
Data exchange via drag-and-drop can only be used with objects of a specific type (“transfer type”). These transfer types are specified for standard FirstSpirit input components, and listed in the table below. If an input component type uses “internal forms” (e.g., FS_CATALOG, FS_DATASET), the internal forms also take account of the relevant transfer type.
Depending on the input component, support for a type may also depend on
- the client used (SiteArchitect or ContentCreator) and/or
- the configuration of the input component.
During a drag-and-drop action, the dropped object is not moved; instead, the action creates a copy or a reference.
Drop Editor
“Drop Editors ” in ContentCreator are a special case with their own specific use rules. These are special input components in a template that can be configured as drop targets. If an element is dropped on an appropriately configured FS_CATALOG, DOM-Editor, or Imagemap, a paragraph, dataset, or link is created that contains the dropped element. The dropped element is saved in the input component defined as the “Drop Editor”. The transfer types for the input components listed in the table are expanded to include the types accepted by the selected Drop Editor.
The Drop Editor can be defined in the following template types:
Drop target | Drop Editor | Template type | Drop element | Result |
---|---|---|---|---|
Link in DOM with dropped element in defined Drop Editor | ||||
See table below | ||||
Text | ||||
Catalog entry with dropped element in defined Drop Editor | ||||
See table below | ||||
Text | ||||
Link template | Link in image map with dropped element in defined Drop Editor | |||
See table below | ||||
Text | ||||
New sections, datasets, and list entries (for FS_CATALOG and FS_INDEX) can also be created by dropping elements on a specially configured FS_BUTTON. For more information, see FS_BUTTON handler classes.
Overview of standard input components
Input component | Permitted transfer types | Restrictions/conditions |
---|---|---|
SiteArchitect only. | ||
Only when using the DatasetDataAccessPlugin | ||
All transfer types allowed in the configured drop editor of the table template (see paragraph Drop Editor). | ContentCreator only. | |
in the referenced DataAccessPlugin defined transfer types | ||
FirstSpirit elements | ||
External files | Uploads must be permitted (upload="yes"). | |
SiteArchitect only. | ||
SiteArchitect only. | ||
Text | ContentCreator: Not supported for forms. | |
Text | ||
ContentCreator: Only when no background image has yet been selected. | ||
SiteArchitect only. | ||
Text | SiteArchitect only. | |
SiteArchitect only. | ||
SiteArchitect only. | ||
Text | ContentCreator: Not supported for forms. | |
SiteArchitect only. | ||
The configuration restrictions/conditions set out in the table are mandatory values and deviations from the standard configuration. Optional configuration parameters may also affect whether or not an input component can be dropped, for example
- FS_DATASET:
- Limited to specific data sources
- Enable or prevent the creation/selection of datasets
- FS_REFERENCE: Limited to specific
- CMS_INPUT_COMBOBOX:
- Enable or prevent editing
- CMS_INPUT_DATE:
- Selection mode only for time, only for date, or for both
- CMS_INPUT_NUMBER:
- Definition of a specific number type,
- Specification of a maximum/minimum numeric value,
- Enable or prevent editing
- CMS_INPUT_TEXT:
- Enable or prevent editing
The dropped element must fit the configuration of the target input components.
Access via API
For further information on the drag-and-drop features of DataAccessPlugins in the FirstSpirit Access API, see also Interfaces
- TransferSupplying<D> (describes the provision of data types from a report)
- TransferHandling<D> (describes the acceptance of data types in the context of an FS_INDEX input component)
For more information, see also the chapter entitled Plug-in development.