You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2022-09-02 09:24:20

TB1
Member
Registered: 2022-09-02
Posts: 4

Business Rule problem

Dear Support,

we started to use business rules, and faced some problem.

We set up a rule, what does the following:
In a ticket category if someone changes the status to pending it sends an approval request to an e-mail address.
Thats works fine.

After that we made a new rule that contains the following:

If the approval request was validated, change the ticket status from pending to processing assigned. This one not works.
Here is the export of rule:

<rules>
<rule>
<entities_id>ENTITY</entities_id>
<sub_type>RuleTicket</sub_type>
<ranking>6</ranking>
<name>ChangeStatus</name>
<description/>
<match>AND</match>
<is_active>1</is_active>
<comment/>
<is_recursive>0</is_recursive>
<uuid>c8d8dada-d78aefb4-6311ae476d4e66.46879608</uuid>
<condition>3</condition>
<date_creation>2022-09-02 09:18:31</date_creation>
<rulecriteria>
<criteria>itilcategories_id</criteria>
<condition>11</condition>
<pattern>TestCategory</pattern>
</rulecriteria>
<rulecriteria>
<criteria>global_validation</criteria>
<condition>0</condition>
<pattern>3</pattern>
</rulecriteria>
<ruleaction>
<action_type>assign</action_type>
<field>status</field>
<value>2</value>
</ruleaction>
</rule>
</rules>

Any suggestion what should we do?

GLPI version 10.0.2

Thanks in advance!

Last edited by TB1 (2022-09-02 13:00:31)

Offline

#2 2022-09-02 19:53:24

cconard96
Moderator
Registered: 2018-07-31
Posts: 2,813
Website

Re: Business Rule problem

Business rules that trigger on an update evaluate the changes being made and do not typically account for the current state.
For this example, it would probably only work if the ticket where to be approved and have the category changed within the same update action.


GLPI Collaborator and Plugin Developer.
My non-English comments are automated translations. Sorry for any confusion that causes.
Mes commentaires non anglais sont des traductions automatiques. Désolé pour toute confusion qui cause.
Mis comentarios que no están en inglés son traducciones automáticas. Perdón por cualquier confusión que cause.

Offline

Board footer

Powered by FluxBB