
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-02-2024 06:06 AM - edited 12-02-2024 06:19 AM
Hello!
I need to create ui action next to submit (see below). This ui action will copy the short description and the description from the incident to the current task.
like from INC2847082 to INCTSK0653006
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-02-2024 06:37 AM - edited 12-02-2024 06:58 AM
You can use a script like this in a UI Action with the Client box checked. Uncomment line 6 if you want to also submit/update the task.
function copyFromInc() {
var inc = g_form.getReference('incident', incInfo);
function incInfo(inc){
g_form.setValue('short_description', inc.short_description);
g_form.setValue('description', inc.description);
//gsftSubmit(null, g_form.getFormElement(), "copyinc");
}
}
if (typeof window == 'undefined') {
copyInc();
}
function copyInc() {
current.short_description = current.incident.short_description;
current.description = current.incident.description;
current.update();
}
In this example you want the Action name to be copyinc and Onclick = copyFromInc()
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-02-2024 06:37 AM - edited 12-02-2024 06:58 AM
You can use a script like this in a UI Action with the Client box checked. Uncomment line 6 if you want to also submit/update the task.
function copyFromInc() {
var inc = g_form.getReference('incident', incInfo);
function incInfo(inc){
g_form.setValue('short_description', inc.short_description);
g_form.setValue('description', inc.description);
//gsftSubmit(null, g_form.getFormElement(), "copyinc");
}
}
if (typeof window == 'undefined') {
copyInc();
}
function copyInc() {
current.short_description = current.incident.short_description;
current.description = current.incident.description;
current.update();
}
In this example you want the Action name to be copyinc and Onclick = copyFromInc()

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-02-2024 07:35 AM
Thank you!!!