Service Portal Pop up
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-09-2023 11:35 AM
I have a requirement, there is a button that changes the state of the ticket to critical, but I want to allow the end user to change the state of the ticket only once, and if the end user clicks on that button again after changing the state then I want to tell end-user that the state of the ticket has already been changed to critical. How to achieve this?
Thank you for helping
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-09-2023 11:35 AM
Any modal message or an alert message will also do.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-09-2023 02:52 PM - edited ‎11-09-2023 02:53 PM
Hi @aditya174
You can use ng-if in your HTML code to check if the incident state is already Critical (store state value in a variable on server script to use with ng-if). If it is already critical you can disable or hide the button.
Alternate Solution:
Create a flag (field) on the incident table and change it to true if the user already changed the priority to Critical once.
Check this flag with ng-if in the HTML tag of the button.
Thanks!
Mark it as helpful if it works for you 🙂