DataConnector
The DataConnectors represent the data that our angular project can manipulate. They exist within a FeatureModule
and have a reference to the relevant DataElement in the backend. Therefor, a DataConnector is added for every
DataElement of which data is needed.
The name of your DataConnector needs to be the same as the referenced DataElement.
DataConnector in Angular Project Structure
DataConnectors are added in the dataConnectors directory or directly in the FeatureModule.
project
├── conf
├── applications
├── angular
. ├── model
├── featureModules
. ├── space
. ├── model
. ├── dataConnectors
. └── StarShip.xml
- Add in directory
- Add in FeatureModule
<dataConnector name="StarShip">
<dataElement component="spaceComp" name="StarShip"/>
</dataConnector>
<featureModule name="space">
<dataConnectors>
<dataConnector name="StarShip">
<dataElement component="spaceComp" name="StarShip"/>
</dataConnector>
</dataConnectors>
</featureModule>
Expanded artifacts
A DataConnector will expand a service and filter, sorting, and data
models. The service contains methods that can be used to retrieve (filter), edit, add and delete data from the desired
DataElement. REST calls are being used that are based on the rest-expanders, this means that the DataElement needs
to expose endpoints using a control layerLayerLogical separation of functionality within a single system/application, focused on code organization..
Filtering options
QuerySearchDefines the default fieldFieldA property of a DataElement expanded to a database column and user interface input element. name to filter on.
<options>
<angular.defaultFilterField>name</angular.defaultFilterField>
</options>