FieldMetadataInfo objects are used in 2 areas of Erp Sync:
-
Populate a set of configuration controls for setting up a sync connection. The connector will supply a set of
FieldMetadataInfoobjects that describe the set of configuration data needed to set up a working sync connection. When synchronizing/sending data between SuperOffice and a sync connection, Erp Sync will need to know the details of each field on the ERP side to avoid errors related to things like data type parsing and field length overruns. The Sync Connection will supplyFieldMetadataInfoobjects for each field it supports (through theGetAvailableActorFieldsmethod). Erp Sync will store these details locally for all fields the customer elects to use (for either sync mapping, showing in the GUI and/or setting up for default values. See section “ERP field setup”). When an ERP field is set up for use in Erp Sync, the values in the correspondingFieldMetadataInfoobject are stored locally in the SuperOffice database.
- Setting up a new connection (requires that a Connector URL has already been set up). The grey area is dynamically showing the configuration fields that the connector has indicated that it needs to define a connection.
FieldMetadataInfo members
DefaultValue will vary a bit depending on the type:
- If the field is a label, text or password, then the text is used (obviously)
- If the field is an int or double, we will try to convert the string into a number. (If the conversion fails, we shall use zero or 0.00 as the default value.)
- If the field is a list, we shall try to find a list item where the fields default value matches the lists item’s
ListItemKey.