Please, could you share the report query you are using?
Usually I use like this, taking into consideration you doesn't have any variable in the first field:
On the First Lookup Field:
Report/Plug-in ID: id_from_my_report
OnChange: ca_fdFetchSelectData(ca_fd.formId,'second_field_id')
On the second lookup Field
Report/Plug-in ID: id_from_my_second_report
Report/Plug-in Variables: $('variable_2nd_field':ca_fdGetSelectedOptionValues(ca_fd.formId,'first_field_id')[0]})
That's all you have to do.
Sometimes I had problem testing those on Form Design Screen and it only worked after I added the form to a Service Offering, you could try that as well if loading... message still appearing, but in my experience, it still like loading... it's because it's not finding the variable, so, your information from OnChange from first field or/and the information from report/plug-in Variables are wrong. You could try as well to force a value you know is correct like:
Add to Report/Plug-in Variables: $('variable_2nd_field':Integer). It should force the second lookup to display the values once you are providing the variable a number.
Original Message:
Sent: 12-16-2019 08:24 PM
From: Douglas Molina
Subject: Drop down list in Catalog
I think have two errors:
I modify my code like this:
First drop down list: ca_fdFetchSelectData(ca_fd.aperturaClaves,'cmbComponente');
Second drop down list: $({'INTEGER':ca_fdGetSelectedOptionValues(ca_fd.aperturaClaves,'cmbSistema')[0]})
Where aperturaClaves is the _id name of my form, now..........In the first drop down list load nice, but when i press the second drop down list only say Loading.... but not appear nothing.
Original Message:
Sent: 12-16-2019 02:35 PM
From: Douglas Molina
Subject: Drop down list in Catalog
Ok Pier, i try this and this is the result loaded in my enviroment
The first drop down list is ok, but the second drop down list not work. i attached a .doc whit the screenshot and code.
Original Message:
Sent: 12-16-2019 08:12 AM
From: Pier-Olivier Tremblay
Subject: Drop down list in Catalog
Say I have two tables defined as follow
table_1 :
id
Name
table_2 :
id
name
id_from_tbl_1
First report object has a query looking something like :
select id as value, name as label from table_1
Second report object has a query looking something like :
select id as value, name as label from table_2 where id_from_tbl_1 = %INTEGER%
First dropdown is a standard one with first report object as report object ID.
First dropdown : attribute onChange : ca_fdFetchSelectData(ca_fd.formId,'dropdown_2');
Second dropdown is a standard one with second repport object as report object ID.
Second dropdown : attribute Report variables : $({'INTEGER':ca_fdGetSelectedOptionValues(ca_fd.formId,'dropdown_1')[0]})
Have fun
Original Message:
Sent: 12-13-2019 03:44 PM
From: Douglas Molina
Subject: Drop down list in Catalog
Hello community!!
I need obtain from a list of arguments by example:
First drop down list contain 10 arguments.(Disable = false)
Second drop down list contain 100 arguments. (Disable =true)
After to select the option in the first drop down list (Disable =false) and show in the second drop down list only the arguments corresponding to the one selected in the first drop down list.
I create two data objects in Report Builder to obtain the list in every dropdown list but i dont have idea what more do. I think i need add an script in the form but this new for me.
Thanks to all