Skip to main content
Solved

Lookup XML Filter in Web client

  • November 28, 2021
  • 7 replies
  • 370 views

Forum|alt.badge.img+1

Hi All,

 

Good Day!

 I’m Facing Issues in Lookup XML filter is not working in FSM Web client. The same Filter is working fine in Smart Client but which is not working in Web client.

Do we have any other way to filter the dropdown in web client via client script ? or can we have any way to work with lookup xml in web client?

Kindly assist and advise on the same.

Thanks in Advance,

Regards,

Hariharan P

 

 

Best answer by SanjeewaJ

Hi @Hariharan P 

Please see if below conversation helps you. I have given an example client script to filter a dropdown.

https://community.ifs.com/ifs-field-service-management-fsm-employees-partners-only-103/how-to-hide-values-from-dropdown-15819

/Sanjeewa

View original
Did this topic help you find an answer to your question?

7 replies

SanjeewaJ
Superhero (Employee)
Forum|alt.badge.img+12
  • Superhero (Employee)
  • 89 replies
  • Answer
  • November 29, 2021

Hi @Hariharan P 

Please see if below conversation helps you. I have given an example client script to filter a dropdown.

https://community.ifs.com/ifs-field-service-management-fsm-employees-partners-only-103/how-to-hide-values-from-dropdown-15819

/Sanjeewa


JuniSihombing
Hero (Customer)
Forum|alt.badge.img+11
  • Hero (Customer)
  • 133 replies
  • December 9, 2021

Hi @SanjeewaJ,

as the link is not accessible by customer, could you also please share the answer here?

 

Thanks in advance.

~Juni


SanjeewaJ
Superhero (Employee)
Forum|alt.badge.img+12
  • Superhero (Employee)
  • 89 replies
  • December 10, 2021

Please find extracted answer:

Please see if you are looking for something like this. I just created an example with REQUEST entity. Which I am populating request statuses, based on request type.

Note that, this works only for web client. Since screen events are not working in smart client.

  1. Client script Example - SAJGLK_DYNAMIC_STATUS_DROPDOWN

showProgressIndicator();
var reqType = getControlValue('request','req_type');

var emptyOptions = [];
var options = createCodeTableOption('','');
arrayPush(emptyOptions, options);
setControlOptions('request', 'req_status', emptyOptions);

if(reqType == 'FIX') {
    var opt1 = [];
    arrayPush(opt1, createCodeTableOption('INVESTIGATE','Investigate'));
    arrayPush(opt1, createCodeTableOption('HOLD','Hold'));
    setControlOptions('request', 'req_status', opt1);
} else {
    var opt2 = [];
    arrayPush(opt2, createCodeTableOption('CANCELED','Canceled'));
    arrayPush(opt2, createCodeTableOption('CLOSED','Closed'));
    setControlOptions('request', 'req_status', opt2);
}
hideProgressIndicator();

  1. Attach the client script to screen.

UI Designer → Screen Events

 

  1. Test in WEB Client

 

 

 

Few points,

  • You can populate options from code tables using client script sql, rather hard coding
  • You have to handle the “Create New” record also in the script. Otherwise it will show only few options at creation as well.

/Sanjeewa


JuniSihombing
Hero (Customer)
Forum|alt.badge.img+11
  • Hero (Customer)
  • 133 replies
  • December 10, 2021

Thanks @SanjeewaJ ! 


Forum|alt.badge.img+2
  • Do Gooder (Partner)
  • 3 replies
  • January 3, 2022

Hi @SanjeewaJ,

 

Thanks for  Suggestion.

The above Function ”createCodeTableOption” which is working for Code table, Is there any function available for Global Code table for the same Scenarios ? Kindly suggest.

 

Thanks,

Hariharan P


SanjeewaJ
Superhero (Employee)
Forum|alt.badge.img+12
  • Superhero (Employee)
  • 89 replies
  • January 3, 2022
HHP wrote:

Hi @SanjeewaJ,

 

Thanks for  Suggestion.

The above Function ”createCodeTableOption” which is working for Code table, Is there any function available for Global Code table for the same Scenarios ? Kindly suggest.

 

Thanks,

Hariharan P

Hi @Hariharan P 

No. I dont think there is a separate function for global code table. Did you try the same function for global code? I did not get a chance to try. So cannot confirm if it will work.


Forum|alt.badge.img+2
  • Do Gooder (Partner)
  • 3 replies
  • January 3, 2022

Hi @SanjeewaJ ,

 

Thanks for the Update, Yeah the same one is working for global code tables also.

Regards,

Hari


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings