UI Page: Attachment - add info for incidents

MT247
Tera Expert

Hi,

i need to add a message for the ui action "attachment" to get displayed only on the incident form.

So for change, task whatever it needs to be the ootb message/functionality and only if the ui action is clicked in the incident form, i need to display a popup or even an additional message inside the add attachment form.

find_real_file.png

Anyone has a clue on how to do this?

 

The message must not be part of the above screenshot, it can be an alert message also, but need to be displayed when the user in the incident form clicks on the attachment button (paperclip) on top of the screen.

1 ACCEPTED SOLUTION

Hi,

So when user clicks on attachment icon an alert needs to be show

use below approach

1) go to UI pages

2) search for name as attachment

in the html section add this code as below; just in the beginning

since this should only work for incident table and not for all other tables use this logic which checks the table name & the message will only appear for incident table:

<j:if test="${JS:RP.getWindowProperties().get('target_table') == 'incident'}">
	<script>
$j( document ).ready(function() {
alert("Attachment Icon Clicked Disclaimer");
});
</script>
</j:if>

screenshot below

1) for table which is not incident message is not shown when paper icon is clicked

2) for incident table it is showing the message once paper clip icon is clicked

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

5 REPLIES 5

Viraj Hudlikar
Giga Sage

Hi

Please find this LINK.

Mark Correct if this solves your issue and also hit Like and Helpful if you find my response worthy based on the impact.

Thanks & Regards,
Viraj Hudlikar.

Hi Viraj,

yes, but this would change the message for all tables not only for incident. I need to limit the additional message only for the incident table. 

Hi,

So when user clicks on attachment icon an alert needs to be show

use below approach

1) go to UI pages

2) search for name as attachment

in the html section add this code as below; just in the beginning

since this should only work for incident table and not for all other tables use this logic which checks the table name & the message will only appear for incident table:

<j:if test="${JS:RP.getWindowProperties().get('target_table') == 'incident'}">
	<script>
$j( document ).ready(function() {
alert("Attachment Icon Clicked Disclaimer");
});
</script>
</j:if>

screenshot below

1) for table which is not incident message is not shown when paper icon is clicked

2) for incident table it is showing the message once paper clip icon is clicked

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Thanks - you saved my day! 🙂