Configuring an additional attribute in Security Center permits for Pay-by-Plate Sync - Pay-by-Plate Sync 5.7

Pay-by-Plate Sync Plugin Guide 5.7

Product
Pay-by-Plate Sync
Content type
Guides > Plugin and extension guides
Version
5.7
Language
English
Last updated
2024-06-25

Additional attributes are supplied by payment providers to better support digital parking rights management. After you configure the mandatory properties of the permit entity, you can configure additional attributes in Security Center permits.

Before you begin

Configure the mandatory permit attributes Category, PlateState, PlateNumber, and PermitID. For more information, see Configuring a Security Center permit for Pay-by-Plate Sync.

What you should know

This procedure describes only the information required to use permits as containers for parking providers’ permit data. For more information on how to configure permits in Security Center, see Creating parking permits.
NOTE: This feature currently supports additional attributes received only from the Generic REST Service API.

Procedure

  1. Under the Attributes section, click Add an item ().
  2. Enter a Name for the attribute.
    If you want the additional attribute value to be automatically included in the permit, enter the attribute name received from the payment provider. For example, if the configured Generic REST Service returns a digital parking rights with the FirstName attribute, enter FirstName as the attribute name.
  3. If the attribute name in the permit is different from the attribute name received from the payment provider, do the following to link the attributes:
    1. On the Security Center client workstation, browse to the folder C:\Program Files (x86)\Security Center Plugins\MobilePBP.
    2. Open Genetec.Plugins.MobilePBP.dll.config in notepad.
    3. In the section ExtraAttributesMappings, enter the values for the following fields:
      • IdOfProvider
      • ProviderAttributeName
      • PermitAttributeName
      Code
      <?xml version="1.0" encoding="UTF-8"?>
      <configuration>
        <configSections>
          <!-- ************************************ -->
          <!-- ADD / COMMENT OUT THE FOLLOWING LINE -->
          <!-- ************************************ -->
          <section name="ExtraAttributesMappings" type="Genetec.Plugins.MobilePBP.Server.Configuration.ExtraAttributesMappingsSection, Genetec.Plugins.MobilePBP" />
        </configSections>
        ...
        <!--
          Replace the following fields:
              IdOfProvider: 
                ID of the instance of the payment provider.
                - Go to the Properties page of the Plugin;
                - Edit a provider;
                - Click the Copy button next to the name of the provider.
              ProviderAttributeName:
                Name of the attribute as returned by the payment provider.
              PermitAttributeName:
                Name of the attribute as defined in the associated permit.
        -->
        <!-- ************************************* -->
        <!-- ADD / COMMENT OUT THE FOLLOWING LINES -->
        <!-- ************************************* -->
        <ExtraAttributesMappings>
          <Providers>
            <Provider id="IdOfProvider">
              <Attribute fromProvider="ProviderAttributeName" toPermit="PermitAttributeName"/>
            </Provider>
          </Providers>
        </ExtraAttributesMappings>
       ...
      </configuration>
    4. Save and close the file.
    If you want to map an attribute called PersonFirstName, received from the provider to the permit attribute FirstName.
    Code
    <?xml version="1.0" encoding="UTF-8"?>
      ...
      <ExtraAttributesMappings>
        <Providers>
          <Provider id="b5fe8fc3-12f0-4789-a2ce-da25c59882d7">
            <Attribute fromProvider="PersonFirstName" toPermit="FirstName"/>
          </Provider>
        </Providers>
      </ExtraAttributesMappings>
    NOTE: The mapping of attribute names is case-sensitive.
  4. If you want to use a default value for the field, type in the Value option.

    The default value is interpreted differently depending on whether delimiters are used or not.

    • If delimiters are used and you add a default value for this field, the populated field in the source file is overwritten.
    • If delimiters are not used and the field is empty in the source file, the default value you add here is used for the field. However, if the field is populated in the source file, it will not be overwritten.
  5. If you are adding a new attribute and it is mandatory in the source file, turn on the Is mandatory option.
    If you add a mandatory attribute called CarColor, the column for CarColor in the source file must have text in it.
  6. To show additional attribute fields, click .
  7. If the source file uses fixed length data fields instead of delimiters, switch the Fixed length option to ON, set the Start character position of the attribute in the file, and its Length.

    The position of the first character in the source file is zero (0).

  8. If the field contains a date or time value in the source file, specify a Date format.

    All standard date and time format strings used in Windows are accepted. If nothing is specified, the default time format is “yyyy-MM-dd”.

  9. If you want to transform the values read from the data file, click Add an item () under Translate, select a From and To value, and click OK.
    In the following example, the new field is CarColor and B will be translated to Blue and W will be translated to White.

  10. Click OK.

Results

The additional permit attributes are configured to receive permit data from the parking provider.