Open VladoTTX opened 1 year ago
Hi,
I agree we should not be able to change the priority of a closed ITIL object.
Being able to link new elements may be legitimate, as sometimes, technician may have forgot to include this item when change was processed and just want to complete the list.
Code of Conduct
Is there an existing issue for this?
Version
10.0.6
Bug description
It is possible to edit several things even on Closed ITIL Objects (Tickets, Changes.. ). On Fields panel it is possible:
Items tab:
Also I think "Save" button should be hidden in case Close tickets. Not sure if this is meant as feature but I think on Closed items, no editing should be possible.
Priority and Linking change needs "Saving" and this is prevented later in code in CommonITILObject::handleTemplateFields() but without warning message. But Unlinking from fields panel succeeds.
Some fixes are possible like changing: https://github.com/glpi-project/glpi/blob/9b141106b8458b0377887e7b25da416f4af195fb/templates/components/itilobject/fields/priority_matrix.html.twig#L78 to
'disabled': (not (canupdate and canpriority)),
Or updating footer.twig to not display Save button but maybe it would be possible to achieve by redefining more can* methods in CommonITILObject and include getClosedStatusArray() checks inside to avoid code repeating.
Relevant log output
No response
Page URL
No response
Steps To reproduce
Your GLPI setup information
No response
Anything else?
No response