UI Action visible only in the bottom of the form

developer18
Tera Contributor

Hii,

 

One of the UI action is visible only in the bottom of the form and while loading it just comes and disappears at the Top of the form, but not in Bottom of the form, How can i hide that in form. Its one custom application form not any OOB form

 

I could see one script for this is 

function onLoad() {
//To autopopulate the Error message when condition 
var owns = g_form.getValue('owns_manages_item_s');
if(owns == 'no'){
$$("button[id='submit_for_review']").each(function(item){
item.hide();
});

g_form.showFieldMsg('owns_manages_item_s',getMessage('owns/manages item(s)'),'error');
}else{
$$("button[id='submit_for_review']").each(function(item){
item.show();
});

}
}

 

UI action is submit_for_review

Thanks

1 ACCEPTED SOLUTION
13 REPLIES 13

Tell me this

1. In your UI action do you have conditions? If yes as per those conditions, should the button that you see at the bottom be visible or not?

2. can you share the screenshot of the UI action.

3. The button at the top may be getting hidden due to css and not because of conditions.

Hi Asif,

3. The button at the top may be getting hidden due to css and not because of conditions. : If so where i can check that,,

 

 

1. In your UI action do you have conditions? If yes as per those conditions, should the button that you see at the bottom be visible or not? 

As its custom app, it should be visible in different views so in condition it may not possible

 2. can you share the screenshot of the UI action. 

 

try with ootb functionality .

Hide button on specific view 

 

Doc link for further details. 

 

https://docs.servicenow.com/bundle/helsinki-platform-administration/page/administer/list-administrat...