Set a field as function of group

Issue #303 resolved
Mark Huey created an issue

I am trying to use the "Set a field as a function of other fields" function however what I want to set the field to be is based on the group name of the user account.

We have a custom field called "Customer" that is an abbreviation for the client company name. We also group customer users in groups by their company. We have several reports and other things tied to the custom field "Customer" and I want this to be set automatically based on the group that the creator belongs.

So the creator group would be ABC, I need to have the custom field "Customer" set to ABC upon issue creation.

Is there a way to do this?

Comments (3)

  1. Fidel Castro Armario repo owner

    Hi Mark,

    You can do it using "Set a field as a function of other fields" post-function with a configuration similar to this one:

    Captura de pantalla 2016-04-22 a las 23.51.32.png

    Setting rules in the example are:

    [isInGroup(%{00006}, "ABC")]ABC
    [isInGroup(%{00006}, "Exxon Mobil")]Exxon Mobil
    [isInGroup(%{00006}, "Apple")]Apple
    [isInGroup(%{00006}, "group_name")]option_name
    

    Note that:

    • Value selected at "Field to be checked..." parameter doesn't matter, since we are only using type 2 setting rules.
    • %{00006} is field code for "Reporter".
  2. Log in to comment