89 views

Description

Build information:
Helsinki
 
Issue Description: 
No popup view available to modify the reference pop-up in Service Portal
By default it uses the view of the form from where the reference field was click on, which is not desirable

Steps to Reproduce

1. Navigate to Service Portal.
2. For any reference field on a form, click on the 'i' icon.
3. Notice the view that opens for the reference popup.
4. Go to the relevant table & compare the view.
 
Expected behavior:
Reference field record should open in sys_popup view just like it does in the native platform UI
 
Actual behavior:
Reference pop-up view defaults to  the view of the form from where the reference field icon was clicked on with no way to set it to any other view

Workaround

This Problem was closed as working by design. The reason is, that in the service portal, when you click on the reference icon, a complete functional form is opened, unlike what happens on the native platform (where we use the popup view). Since the form is a complete functional form, we cannot use the popup view, and the default view is used. 
 
There are also several enhancement requests that are already created for supporting a reference Popup or Service Portal specific view in Service Portal. 
 
Here are a couple of ways to workaround this issue: 
 
Workaround 1: Open the form where the reference field is displayed in the desired view; this will allow the same view to be opened when the reference popup is clicked
 
If you open the record in Default view the reference field will inherit the view as default. 

As a result, you may open the form where the reference field is displayed in the desired view. This will ensure that when the reference field is clicked, the reference field record will also open in the same view as the current form's view.

Here are some general tips on how to force the form to open in a specific view in Service portal. 
 
The JSON below can be added to the 'Additional Options, JSON format' field in the Widget Instance for the form where the view is to be opened:

{
"view": {
"value": "sp",
"displayValue": "sp"
}
}
 
In the above example we are opening the form in 'sp' view. This should make sure that the view in the portal and also in the reference icon is 'sp'.
 
 
Workaround 2: Hide the reference icon from the form
Here is a community article that talks about hiding/disabling the reference icon altogether: https://community.servicenow.com/thread/227140 
 
General Steps to hide the reference popup in Service Portal
 
1) to hide the reference popup, go to Service Portal>Pages> 
2) search for the page where the reference popup is to be hidden ex. ID=bcm_cat_item 
3) then in the Page Specific CSS you could add something like this: 
 
.add-on > button.lookup { 
display:none; 
.field-has-reference .reference { 
display: block; 
 
NOTE: Both of the above workarounds only apply to reference fields on a form. They do not apply to reference type fields for catalog item variables and variable sets as those are rendered differently. 

Related Problem: PRB676928

Seen In

Helsinki
Helsinki Patch 3
Helsinki Patch 5

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2018-09-12 18:22:37
Published:2018-08-27