The CreatorCon Call for Content is officially open! Get started here.

Service Portal - Catalog item variable reference qualifier not working

shill
Mega Sage

In reviewing the Service Portal, I've noticed that they item widget does not seem to accept a reference qualifier I have on some of my variables on a few items.

The variable is a Lookup Select Box type variable that references another table using the sys id as the lookup value field.

The qualifier is calling a script include to return sys id's for a reference field.

This all works in the base standard catalog, but does not show any selections in the Portal.

Any ideas on what may be the issue?

1 ACCEPTED SOLUTION

I was able to get this working by changing the variable type to Reference.



Not a great UX in the catalog, but from the Service Portal the UI is nearly identical. When it is a reference, it appears the reference qualifier is run when you click on that field rather than just onload as with the Lookup Select variable type.


View solution in original post

16 REPLIES 16

tylerjones
Tera Contributor

Steve - I know this is a bit of an older post but my understanding is that advanced reference qualifiers that call script includes do not function on the Service Portal. This is due to the SP being client side and the script include being server side. Someone please correct me if I am mistaken.


Oh no... That is not good news as I have several end user facing catalog items built this way.


Are there any other options that I could use for the portal?


I am currently using these to configure a 3 layer choice dependency (Choice A reference filters the choice B reference which filters the choice C reference).


BALAJI40
Mega Sage

Hi Steve,



Advanced reference qualifiers also support for the service portal. Though service portal work for browser side means client side only, but server calls from client side will execute.



You are telling that, the type of the variable is lookup select box, check the element of variable element " variable attribute" empty or not?


if it is empty just add "ref_qual_elements='based on what change element reference values will change variable name".


Try the above one and let me know, weather it is working or not.


So I have a variable called 'u_natural_gas' that is a simple select box.



The second choice is 'u_system' and is a lookup select box. Below are the type specifications and attributes:


find_real_file.png


find_real_file.png


The script include getPipelineProduct() queries the u_pipeline_group table where u_product = current.variables.u_natural_gas and returns the list.