UI Action is not working
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
I have a requirement where :
when only on assess and RCA state reject button should be visible ( working)
and when if clicked on assess then first make the work notes mandatory (its working) it should move back to new state (not working) & if clicked on RCA first it should make the work notes mandatory and then it should move back to assess state. (not working).
here is the code:
onclick: setnotes()
condition :(current.state == 102 || current.state == 103) &&( current.approval == 'not requested');
function setnotes() {
var prbvalue = g_form.getValue('state');
var workvalue = g_form.getValue('work_notes');
if (prbvalue == '102') {
if( workvalue ==''){
g_form.setMandatory('work_notes', true);
}
gsftSubmit(null, g_form.getFormElement(), 'reject_problem');
saveNew();
} else if (prbvalue == '103') {
if( workvalue ==''){
g_form.setMandatory('work_notes', true);
}
gsftSubmit(null, g_form.getFormElement(), 'reject_problem');
saveAssess();
}
}
function saveNew()
{
current.state = 101; // new state
current.update();
action.setRedirectURL(current);
}
function saveAssess()
{
current.state = 102; // Assess state
current.update();
action.setRedirectURL(current);
}
what's the issue here
anything would help!!
thanks!!
5 REPLIES 5
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
Additional - In this solution you have to create only one UI Action which is server callable .
