You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

In this example, a custom identifier "Approval Code" is added to issues by using a project property and different custom fields.

The code that will be created is a combination of a specific number (sequence number), the fiscal year (custom field), and the abbreviation of a department.

Configuration items needed:

  • Project property "sequenceNumber"
  • Custom Text Field "Department"
  • Custom Text Field "Fiscal Year"
  • Custom Text Field "Approval Code"

Configuration

Setting the project property

Setting a project property can be done from project settings → Details

Give it a proper Name*, Key*, and Project type*

Set the Description with a valid expression, in this example we used the following expression: {sequenceNumber=0}

Adding multiple fields

When executing the transition, the current value of "sequenceNumber" is stored in an ephemeral field with the Read a project property post function.

Ephemeral fields are temporary fields that can be used within a transition, e.g. to cache temporary values. They're cleared when the transition is completed, unless a Inhibit ephemeral fields auto-clearance post function is added to the transition.

Increment the "sequenceNumber" by 1 by using the following formula:

Formula
{00058} + 1

{00058} is the field code for Ephermeral Number 1

To achieve this, the following post function is used:

Format the "sequenceNumber" by using the Update fields post function. The setting rules are:

  • [length(%{00058}) = 1]00%{00058}
  • [length(%{00058}) = 2]0%{00058}
  • [true]%{00058}

Using the Update fields post function ensures that the sequence number is always a 3 digit number, e.g. "3" is formatted to "003".

Compose the "Approval Code" with the Update fields post function.

Use the following expression in advanced mode:

Source Value
%{00061} + "/" + %{10420} + "/" + toUpperCase(substring(%{10421}, 0, 3))
  • %{00061} is the field code for Ephermeral string 1

  • %{10420} is the field code for custom text field "Fiscal Year" (this field code might differ on your instance)
  • %{10421} is the field code for custom text field "Department" (this field code might differ on your instance)

In Target Issues select Current issue for Issue Selection Mode.

Finally add the Set or create project property post function, to keep the "sequenceNumber" in sync.

Set the Property Name to sequenceNumber

Set the Value to be written to %{00058}

Check the option Create the property and assign the value option.

Once configured, the transition will look like this:


If you still have questions, feel free to refer to our support team.