formcreator icon indicating copy to clipboard operation
formcreator copied to clipboard

When creating a form answer with 3 tickets and validation. The status is accepted and does not show on open tickets but rather as closed tickets.

Open verdanatech-marcio opened this issue 2 years ago • 8 comments

Describe the bug When utilizing a form with multiple targets and implementing validation for these submissions, the form responses are currently displaying under the accepted status and are listed together with closed tickets, rather than appearing as new tickets. To Reproduce Steps to reproduce the behavior:

  1. Create a form with two or more target tickets
  2. Add validation to the Glpi target or ticket rules
  3. Answer the form
  4. View the created ticket in the simplified interface

Expected behavior A clear and concise description of what you expected to happen. Create a new form response with new status

Screenshots If applicable, add screenshots to help explain your problem. image image image

GLPI / Plugins (please complete the following information):

  • GLPI version - 10.0.11
  • list of all plugins with their version (available in GLPI > Setup > General > tab System > bottom of the page)

Desktop (please complete the following information):

  • OS: [e.g. iOS] - Debian 12
  • Browser [e.g. chrome, safari] - Chrome
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context Add any other context about the problem here.

verdanatech-marcio avatar Jan 31 '24 14:01 verdanatech-marcio

Any answer ?

verdanatech-marcio avatar Feb 05 '24 20:02 verdanatech-marcio

Hi

I don't understand the problem : where do you see that the 3 tickets are closed ?

btry avatar Feb 06 '24 07:02 btry

In the simplified interface, the form answer appears with the status accepted, even without any ticket being closed

verdanatech-marcio avatar Feb 06 '24 11:02 verdanatech-marcio

This is normal : a form answer which has "accepted" status allows the creation of the tickets. Once created the tickets are new or azssigned (it depends on the existence of a technician). The status of the form answer will then follow the lifecycle of the 3 tickets. I don't have everything in ming right now, but roughly, the form answer will have the same status of the ticket with the least advanced status in its lifecycle from new to close.

btry avatar Feb 06 '24 11:02 btry

Here is the documentation of the method which computes the status of a form answer when there are several tickets attached to it.

https://github.com/pluginsGLPI/formcreator/blob/support/2.13.0/inc/formanswer.class.php#L1982

btry avatar Feb 06 '24 11:02 btry

But should the accepted status be shown with the tickets closed?

verdanatech-marcio avatar Feb 09 '24 14:02 verdanatech-marcio

hi,

The status "accepted" for a form answer is visible only when the form does not generates any ticket. In your case, the "accepted" status will never be visible because the aggregated status of the tickets takes priority over the approbation status of the form answer.

btry avatar Feb 12 '24 08:02 btry

In my case, three tickets are being created and still the status is shown as accepted.

verdanatech-marcio avatar Feb 14 '24 18:02 verdanatech-marcio