Foro pra discusão de ProcessMaker
#20794
Olá

Estou precisanso executar uma derivação n vezes, porém se chamo a PMFDerivateCase 3 vezes, ocorre somente uma vez.

coloquei uma trigger no evento ' Before Assignment ' da tarefas

o código é o seguinte:

@@x = @@APPLICATION;
@%y = @%INDEX;
PMfDerivateCase(@@x, @%y);
PMfDerivateCase(@@x, @%y);

PMfDerivateCase(@@x, @%y);


O objetivo é executar 3 vezes, mas gera apenas uma tarefa a mais.

o que está errado ?
#22490
Estimado lbrandao

A maneira de contornar isso, você está indo bem ..
o erro é da derivação 2 ..

Ou seja .. se você estiver na tarefa 1 e quer se referir a Tarefa 4..

T1 -> [Derivacion 1] -> T2 -> [Derivacion 2] -> T3 -> [Derivacion 3] -> T4

La [Derivacion 1] funcionara bien.. porque el index es 1
La [Derivacion 2] no funcionara.. porque el index ya es 2
La [Derivacion 3] no funcionara.. porque el index ya es 3

entonces.. lo que deberias colocar para q funcione el codigo es...
Code: Select all
@@x = @@APPLICATION;
$index = @%INDEX;
PMfDerivateCase(@@x, $index);
$index++;
PMfDerivateCase(@@x, $index);
$index++;
PMfDerivateCase(@@x, $index);

Isto leva funcionar bem.
Espero que ajude, se você tiver quaisquer dúvidas ou obter mais informações, gostaria de ajudar.

Thanks for the link, amosbatto! I was searching fo[…]

Hello Please can you help me with the place where […]

Hi there, I have 3.5.7, 3.8.1 and 3.8.2 versi[…]

AI bot development involves creating intelligent b[…]