The content of the entity needs to be shown in a Map view. How can this be done in Origam ?
- Create a field in your entity with a data type Geography
- There should also be a text field in your entity which will describe the map point somehow
- Create a screen with a screen section configured like this:
- IsMapSupported = True
- MapLocationMember = a name of your geography field
- MapTextMember = a name of your description field
- MapLayers = a name of a map profile – see below
- Create a map profile so that a user can configure how the maps behave by himself. The map profile is stored in a system table AsapMap. Use the following example SQL statement in your deployment script.
- Use the Screens > __system > AsapMapLayer screen to set up a layer – use Mapnik (that is OpenStreetMaps)
- Use the Screens > __system > AsapMap to connect the layer to your map profile
- Now the map view should be set up.
A script for creating a map profile:
INSERT INTO AsapMap (Id, ReferenceCode, Description, RecordCreated) VALUES (newid(), 'MapProfileName', 'User Description', getdate())