Insight offers several valuable Post Functions.
Any created post function on the create transition should be placed after the actual creation of the issue. So do not put it first in the list, it will not work.
For the case when one Post Function depends on the result of another in the same transition, please see section: Dependent post functions in the same transition
With the Insight Post Function you'll have the following options:
Change Insight Value into Insight Object
The selected Object will be added, removed or set to the corresponding attribute of the target Object
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the custom field where objects are selected and to be added/removed/set. | |
| Specify the change type. | |
| Specify the custom field where objects should be changed. |
Assign Object based on Jira custom field
The selected user custom field will be used to find Insight Objects that are associated with that user.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the custom field where information (email addresses or Jira users) can be found. | |
| Specify the custom field where objects should be assigned. | |
| Insight Object Type Attribute name: | Optional object type attribute to filter objects on.. |
Set a Jira custom field with the attribute value from a selected object
Select an object attribute value of a selected object and set it to another target custom field. Supported fields are Jira Text fields, Jira User FIelds, Jira Group Fields and Insight custom fields (not reference fields).
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the Insight custom field from where objects attribute should be fetched. | |
| Specify the name of the Object Type Attribute where to fetch the value/s. | |
| Specify the custom field where object attribute should be stored (reference fields can't be selected). |
Assign Issue based on attribute in a selected Insight Object
Select an insight object and specify the attribute where the assignee will be fetched from.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the Insight custom field from where objects attribute should be fetched. | |
| Specify the name of the Object Type Attribute where to fetch the user from. Any type except "User" or "Default / Email" will be ignored |
Email user(s) based on attribute in a selected Insight Object
Select an insight object and specify the "User" or "Default / Email" attribute to which an email will be sent.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the Insight custom field from where objects attribute should be fetched. | |
| Specify the name of the Object Type Attribute where to fetch the user from. Any type except "User" or "Default / Email" will be ignored. | |
| Specify the email subject. Issue placeholders are supported. | |
| Specify the email message. Issue "placeholders" are supported. |
Increase or decrease the value of an object attribute
Increase or decrease an object attribute value (of type Integer) by a set amount.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the Insight custom field from where objects attribute should be fetched. | |
| Specify the name of the Object Type Attribute where to update the value from. Any type except "Default / Integer" will be ignored. | |
| Specify the change type, Increase or Decrease. | |
| Specify the change value. Anything except a number will be set to default (1) . |
Set the value of an object attribute with a predefined value
Selected object(s) will have their specified attribute set to the predetermined value.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the Insight custom field from where objects attribute should be fetched. | |
| Specify the name of the Object Type Attribute where to set the value. | |
| Change value | Specify the value to set. Any value not validated to the attribute will be ignored. Issue "place holders" are supported. Leaving this field empty will set an empty value. |
Run a groovy script within this transition
Write a groovy script when you have some specific requirements that the predefined Insight post functions can't handle. About parameters into the groovy engine, you have all the parameters available as in a normal post function. The most common one is "issue" where you may query as you like. You can read about Insight groovy script examples here.
| Name | Description |
|---|---|
| Enter your groovy code. |
Create an Insight Object from a Jira Issue
Select an Insight Object schema, Object type and configure the attributes to be populated from a Jira Issue.
For example configuration, please see: Create an Insight Object from a Jira Issue
The value of the Issue field mapped to an Object attribute must be data format compatible, otherwise Insight will not be able to create a new object. Example of a mapping that will fail: A Jira URL picker mapped to Object attribute of type Integer.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Assign to Issue | The newly created object is not automatically linked to the issue. To assign it to the issue, select the custom field on the issue to contain the reference. |
| Always create | If checked, then Insight will create the object even if mandatory object attributes have not been mapped correctly. |
| Object Schema: | Specify the object schema that contains the object type of interest. |
| Object type: | Specify the object type that corresponds to the type of object that should be created. |
| Once the object type is selected, the list of attributes will be listed, allowing a mapping against an Issue field. |
Supported Jira Issue fields
| Field | Jira type | Object type attribute type | Expected Object type attribute value |
|---|---|---|---|
| Affected version(s) | Version(s) |
|
|
| Assignee | User |
|
|
| Description | Text |
|
|
| Due date | Date |
|
|
| Fix version(s) | Version(s) |
|
|
| Issue type | Issue type |
|
|
| Key (issue) | Text |
|
|
| Labels | Label(s) |
|
|
| Priority | Priority |
|
|
| Project | Project |
|
|
| Reporter | User |
|
|
| Resolution | Resolution |
|
|
| Resolved | Date |
|
|
| Status (Issue) | Status |
|
|
| Summary | Text |
|
|
| customfield_xxxxx | Undefined |
| The value of the custom field. |
Make sure that when using custom fields that the custom field value is possible to set to the target attribute. If not it will be discarded.
Assign object/s based on an IQL query based on data from an issue
Assign objects to custom fields depending on an configured IQL query. Any issue value is available as place holders. Use the common field definitions for Jira fields. The IQL query will run upon the schema which the Insight custom field belongs.
| Name | Description |
|---|---|
| Condition | Specify the groovy code to use as condition for this post function to execute. Condition ignored on empty value. |
| Specify the IQL to filter the objects to set on the specified custom field in next configuration. The IQL supports placeholders from any Issue Field. | |
| Specify the Insight custom field that the filtered objects should be attached. (Referenced Insight Customfields are not supported) |
