# Creating a job

Creating a job in a back office application that removes rekeying on behalf of officers without any technical coding etc. is the holy grail for product development.&#x20;

It's because enabling the complex to be made simple is remarkably hard to do. But with this plugin we have enabled non-technical users to map the content from eDesigner forms directly into Symology.&#x20;

Within the map set up for Symology, click on 'Push Jobs To Symology' as shown below:

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FmrgW0wLbhaBZ57A3LErK%2FScreenshot%202021-12-13%20at%2021.21.43.png?alt=media\&token=e48017d7-4bfd-42ad-964b-8fa65dc92763)

### Mapping the Form content to the Symology API

When you do so you will be presented within the following UI:

![Symology Job Creation Set up](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FO29xOAsYkBxFA3Iv8Em1%2FScreenshot%202021-12-13%20at%2021.23.55.png?alt=media\&token=327c6784-479a-49b2-87bf-bda1a09b4665)

{% hint style="warning" %}
**Important**

The request type that we send can only come from one question's answer. Originally, it was thought that you could filter right down via multiple questions. However, as the Request Type has a 1 to 1 relationship with the question in the form you can only really have a single question providing the answer to the type of request.
{% endhint %}

The purpose of the above screen is to enable non-technical users to pass the content that the Symology API - **SendRequestAdditionalGroupAuthenticated**- requires to create a job in the back office application.&#x20;

{% hint style="info" %}
Not all of the fields are mandatory!&#x20;
{% endhint %}

The following illustrates this screen populated to provide context when we walk through each of the different fields:

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2Fh2yuHMg3CrxtJ2oj1HsP%2FScreenshot%202021-12-13%20at%2021.22.57.png?alt=media\&token=da2601cc-9e08-4c28-9c0a-ce6a413fe8af)

We will walk through each now:

**User name**

The 'User name' is the user name that should be used for the update audit in the back office

**Service Code**

This tells the back office the service area to which it relates. I.e. HIGH means Highways

### User Entry Fields

Notice how the rest of the fields have a label (in blue e.g. Request Type) followed by two fields. This is because, RequestType is the thing that needs to be sent to Symology. But the form needs to know which page and question will provide it. It needs to know this because you could build a 100 different forms with different pages and questions and we need to cater for that.&#x20;

So for each item in blue you have one drop down on the left to say the page it will come from and another to say which question/answer will provide it.&#x20;

**Request Type**

This is the type of incident/issue being reported.&#x20;

{% hint style="info" %}
In this form there is a page called 'My first page' and on that page a question with a field id of 'reportedRequestType' which captures the type of issue they're reporting. This same way of mapping works the same for all of these items mapped from the form.
{% endhint %}

**Location**

A text based description of the location. Can be used to help with pinpointing the location. E.g. Outside number 20 on the high street.

**Geo Location**

The geo-location i.e. physical coordinates in Easting/Northing measurement.

**Description**

Any more specifics or details relating to the issue in question&#x20;

**Customer Firstname**

The customer's first name (if provided)

**Customer Surname**

The customer's surname (if provided)

**Customer Email**

The customer's email address (if provided)

Once you've added all of these you're ready to set up the trigger to create a job.&#x20;



### Adding an Action

To add an 'action' to a form, i.e. trigger something when the form is submitted, one needs to go to form details in Form Management:

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FKdEliqOT2lMBMLxc7z8B%2Fimage.png?alt=media\&token=50f50723-c3eb-4078-9ec7-2ce456638461)

Once you've clicked on that click the Advanced Create link and you will see the following:

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FSIUUnbTvYyppiyrS9TdL%2FScreenshot%202021-12-13%20at%2021.36.26.png?alt=media\&token=81f0cab5-227b-409e-9deb-7615ff0ee2ab)



Once done, the only thing you need to do is give the action a name.&#x20;

{% hint style="info" %}
This name will appear in the Forms Portal's integration tab so try to make it clear as possible as to what it is.
{% endhint %}

![Naming the Symology Create Job action](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2F6JkJmispneCNfxPY1CfR%2FScreenshot%202021-12-13%20at%2021.42.09.png?alt=media\&token=6defb442-0889-4a76-956b-64d2b2c87eb5)

Whatever you name, it will also shown in the screen below once you've saved it:

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FiT1k97dxsKUj1kdgSkHI%2FScreenshot%202021-12-13%20at%2021.43.16.png?alt=media\&token=b904ca21-2a6e-4770-bfb8-5a8c03017d55)

Now you can test submitting the form and seeing the updates in Symology.&#x20;

### Integration outcomes

When a form is submitted it can be viewed within the [**Forms Portal**](../../../shared-features/forms-portal). Importantly, you can click on the 'Integration' tab and see the outcome of it.

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FVfVOxXwMewThnalVf3dr%2FScreenshot%202021-12-13%20at%2021.46.17.png?alt=media\&token=5cef858f-eff9-4ede-b0b6-cc5440f89725)

Plus, on the 'Documents' tab there is a document called: api-input.json as shown below, which holds the details that were passed to Symology.&#x20;

![](https://2446085776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Xv5e5CMqZNlA8r5Exkm%2Fuploads%2FcVW0hJcvjGD1D6LbP0PF%2FScreenshot%202021-12-13%20at%2021.48.50.png?alt=media\&token=ccfeefe7-c6aa-4522-9eab-ccc3430f333e)

A sample file is shown below where one can see the fields mapped in creating a job - user entry fields are present.&#x20;

```
{
  "TextFields": [
    {
      "Id": "Request.UserName",
      "Value": "CAC"
    },
    {
      "Id": "Request.ServiceCode",
      "Value": "HIGH"
    },
    {
      "Id": "Request.RequestType",
      "Value": "BLDM"
    },
    {
      "Id": "Request.Description",
      "Value": "There's a huge issue"
    }
  ],
  "LocationField": {
    "latitude": "51.49068560236329",
    "longitude": "-0.11641360221279928",
    "id": null
  },
  "Documents": [],
  "CreatedOn": "2021-12-13T17:08:36.067",
  "Reference": "KZXFWJNK"
}
```

