Can a UI Action display a different label after being pressed once?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-26-2013 11:36 AM
I have a weird situation.
I have a client script UI Action 'Re-open Incident' visible for closed incidents.
When pressed, the user is prompted to enter a comment and a field message tells the user to 'Please enter a comment when reopening an Incident and then press 'Submit'.
Is it possible to relabel the UI 'Re-open Incident' to 'Submit' after the button is pressed so I don't need to introduce another UI?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-29-2014 01:10 PM
Thanks very much!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-30-2014 03:20 AM
One of our testers did find a problem this morning with the Client script
It all works, but when he clicked on the Date Selector, the button was fubar.
i could not quite understand as the Client script was only hiding the correct buttons, but disabling it and the dates worked, enabling and they did not. (I must admit I was only looking at the button hiding / showing as expected)
In the end I found out the issue is the variable called "inner"
I changed that to be "ButtonPhrase" and the buttons still hide and the Date selectors are working
you need to update the client script and the UI Action
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-02-2014 01:30 AM
You should be able to accomplish it by putting the following code in the Onclick field of the UI Action record:
var oldName = this.innerHTML; var newName = oldName.replace('Re-open Incident', 'Submit'); this.innerHTML = newName;
Blog: https://sys.properties | Telegram: https://t.me/sys_properties | LinkedIn: https://www.linkedin.com/in/slava-savitsky/