Query Widget - Spatial Filter to filter input results to drop down queries

728
1
05-23-2018 02:44 AM
IonutAlixandroae3
New Contributor II

Hi all,

I am trying to modify the Query Widget (WAB for Dev 2.8) and I`m trying to bind the draw functionality with the drop down queries created when creating the widget.

Structure:

The widget will have The Draw Widget at the top (A spatial filter)

Other attributes drop downs below defined as expressions (Attribute filtering)

The workflow should be like this:

1. The user is using the Draw widget to draw a polygon on the map

2. The drew polygon is querying the layer in the map and only the data that is contained in the polygon is available (shown in the map)

3. The following expressions to have only the data that is available after the spatial filtering.

4. Click Apply to filter (The above 3 steps should be happening before clicking Apply filter button)

At the moment in the Query Widget, the expressions are not updating based on spatial filtering (what the user is drawing). (See image below, instead of all those values in the drop down, after spatial filter, only 1 value shold be availabe in the drop down)

I have customized the widget to have the Spatial Filter UI at the top and to filter the layer but I`m not really sure how to make the widget to re-read what data is available to populate the expressions..

Thanks a lot in advance,

Ionut

0 Kudos
1 Reply
IonutAlixandroae3
New Contributor II

LE: I have advanced into modifying  the widget but cannot modify the text values from the drop-downs;

Doing a new query on the operational layer in the map I could obtain the new values and update the drop downs with the most recent values, the problem is that I cannot acces the values from the drop downs so I could do the replacing

0 Kudos