"create issue" with post function oncreateTransition does not work in create transition

Irene Espadas October 16, 2014

I try to create an issue when create the first issue in a workflow (default "Create" transition) but this does not work.

 

Transición: Create

  1. Create

esta es la transicióninicialen el flujo de trabajo.

Pantalla: Ninguna - transición incial no tiene una vista.

Añadir función posterior

Lo siguiente se procesará luego de realizada la transición

  1. Create issue 
    Conditions:
    • Condition value: %IssueType%, Regex pattern: Task
    Summary: 
    Description: 
    Project: Original project 
    Issue type: Bug (1) 
    Priority: Parent's priority 
    Reporter: Current user 
    Assignee: Parent issue's assignee 
    Affected versions: None 
    Fixed versions: None 
    Components: Parent issue's components 
    Copy parent issue custom fields: Descripción
    Copy original issue custom fields: Motivo petición
  2. Crea una incidencia de origen.
  3. Reindexar una incidencia para mantener los índices sincronizados con la base de datos.
  4. Disparar un evento Incidencia creada que puede ser procesado por escuchadores.

2 answers

1 vote
Ramiro Pointis
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 16, 2014

I think I got it. This sould work without any problem so my previous comment was wrong. But as I see in the doc you have to move up the 'Creates the issue originally' postfunction. The doc is for the subtasks but is the same:

https://bobswift.atlassian.net/wiki/display/CSOT/How+to+create+subtasks+on+initial+issue+create

Ramiro Pointis
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 16, 2014

And just in case someday you change your postfunction, make sure that you don't create in the postfunction the same issue type that you are creating manually becuase this will create a loop. For example, if you create a task that has a postfunction that creates a task it will result in a loop.

Bob Swift OSS (Bob Swift Atlassian Apps)
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 16, 2014

Good answer and the warning is especially important ;).

Ramiro Pointis
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 16, 2014

Thanks Bob :)

Irene Espadas October 20, 2014

But I want the same issue type in the post function that the one I create manually. Is this not possible? Effectivelly now I have a loop.

Bob Swift OSS (Bob Swift Atlassian Apps)
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 20, 2014

Well it is possible, but, you have to figure out another condition that will prevent the looping as described in https://bobswift.atlassian.net/wiki/display/CSOT/How+to+create+subtasks+on+initial+issue+create

0 votes
Ramiro Pointis
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 16, 2014

Hi, If I remember correctly there was a problem when creating a issue in the create transition, but I can't find the issue created for this. Just to make sure, it's working fine in the other transitions?

Irene Espadas October 16, 2014

Yes, it works fine in the other transitions

Suggest an answer

Log in or Sign up to answer