Hi
I am trying to create a simple application that allows users to filter a layer based on a few attributes, allowing the users to select "any" or "all" if they wish. For example if a layer has attributes of Country, Colour and Age they should be able to search for Country = Any, Colour = "Green" and Age is greater than 50.
However, using the default web appbuilder and arcgisonline tools, as my country has a drop down list (which it would need to avoid typos and to pick from a specified list) it is always making the user select a country so users can never say I want to see all green things over 50 without also saying, for example, in France.
Anyone had this issue before and know a way around it?
Thanks
Solved! Go to Solution.
Darryl,
You should look into using the eSearch widget then. The eSearch will add and "all" option for fields that are not configured as required or if there is not a option chosen from the drop down list then that field will not be used in the query (if it is not required).
Darryl,
You should look into using the eSearch widget then. The eSearch will add and "all" option for fields that are not configured as required or if there is not a option chosen from the drop down list then that field will not be used in the query (if it is not required).
Hi Robert
I had already looked at that and thought it didn't do what I needed. Having played around a little longer it does!
Thanks
Darryl,
Glad it works for you. Don't forget to mark my reply as the correct answer.
If anyone has the specific issue I had and reads this. I used the predefined list, entered all choices and set the Value for an 'Any' option as an underscore '_'.
With a query of FIELD LIKE '[Value]%' this brings back all records so essentially is like un-filtering that layer
Hi Robert
One thing, do you know if it is possible to not have this section, I only have one searchable layer and want every selection to be a new one so don;t really need any of that. As this will be seen by members of the public I like to try and make the interface have as few options as poissible. I have tried marking various divs in the code as visibility: hidden or display: none but has no affect
EDIT: Ignore this, I have worked it out