Select to view content in your preferred language

Enhanced-Search-Widget-for-FlexViewer Part III

178916
776
04-30-2013 03:58 PM
RobertScheitlin__GISP
MVP Emeritus
All,

   Here is a new thread to post questions and discuss the Enhanched Search Widget. The old thread was getting too long.
Tags (2)
776 Replies
ThanhThai
Emerging Contributor
I promoted the application and therefore, widgets through the upgrade process from 3.3 to 3.6.  Perhaps, that's what broke them, because they were working fine in 3.3.  I will try rebuilding the app again and see if I still have the issue. Thanks for your help, Robert.
0 Kudos
pWHISLER
Emerging Contributor
Hi, I hope I can ask this clearly.

I need to make 3 drop downs, one for jurisdiction, one for cities, and one for counties.  As you select the top one, it would then populate the next drop down of counties in that jurisdiction, and then when you select the county, it would populate the next drop down with the cities. 

This data is coming from the database, and then the user could search the map for layers based on the drop downs selected and a spatial overlay/intersect of the geography.

So, my question is, how can I get started extending your tool to do that?  Do I need FlashBuilder?

thanks!
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
pwhisler,

   The widget is not currently capable of your desired workflow. So yes you would need Flash Builder and a good deal of Flex programming knowledge to be able to accomplish your workflow. You should really consider some much easier flex programming task to cut your teeth on if you have no Flex programming background, because this one will not be simple by any means.
0 Kudos
DarylAnderson
Emerging Contributor
To fix my last posting if anyone has used this yet.

The attached ZIP file contains the compiled versions of the swf files, compiled with Flash Builder 4.7 (64 bit) using the Flex 4.6.0 SDK.

Some warning:  After rigorous testing it was found that the SearchWidgetFixedDG.swf widget broke if compiled with the Apache Flex 4.12.0 FP11.1 AIR4.0 en_US SDK (for other devs trying any enhancements).  Sorry for any inconvenience.
The swf file can now be dropped into the standard Flex Viewer distribution.

Then use the uniquevalsfromfield option and it will not poll the server 1000 (or whatever your setting is) results at a time until done.
This is optimally used with an SDE database backend (tested with Microsoft SQL, Oracle and PostGIS).

I used it against a layer with 270000+ Cadastre land parcels.
0 Kudos
DarylAnderson
Emerging Contributor
I appreciate your code contribution, but your changes to the paging query task to use the returnDistinctValues assumes that a certain version of ArcGIS Server 10 is being used and I want the widget to reach a broader audience.


I hear your concern.  Herewith my suggestion.

To support backward compatibility I suggest you add another configuration tag to your widget xml configuration file.
Something like backwarduniqueness, but I am sure if you implement this you will conjure up an appropriate tag name.
I am not sure if the Flex API exposes the REST version, I did not see when I looked.  If the Flex API exposes the REST version you could perhaps use this.
The way I perceive things you only have to concern yourself about ArcGIS 10.0 services to preserve the backward compatibility.

To assists you in this particular API call change, I have tested the update in the following environments:
ArcGIS 9.3.1 SP2 - The underlying REST API does not support the call.
ArcGIS 10.0 SP5 - 1000 rows are returned.  The rows are not unique, however at least the API call does not crash.
ArcGIS 10.1, 10.2, 10.2.1, 10.2.2 - The Flex API correctly returns a list of unique values in one call.

P.S. Your Identify and eSearch widgets absolutely rock...keep up the excellent work.
0 Kudos
Erickson_Contract_Surveying_
Deactivated User
Robert, Is there a way to make the default graphical button selected even if the graphical search isn't the default search option?
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Derek ,

   Currently no.
0 Kudos
GlennWalters
Deactivated User
Hi Robert,

Wonderful widget and thank you for all your efforts.  I cannot get the sum feature to work.  I've Googled around and cannot find a working example anywhere to see the desired results.

From the service REST end-point, I verified I'm trying to sum a numeric field, I also edited any null values to 0 in the database.
BOOK_COST ( type: esriFieldTypeDouble , alias: BOOK_COST ).

Also, I understand summing a single field but does that mean only 1 field can have a sum?
In other words Can I individually sum a value field and a population field on the datagrid.

I've attached the config and a screenshot of what I'm getting for a result.

Thanks,
Glenn
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Glenn,

    Thanks for reporting this. I seem to have broke the summing code in one of my releases. The fix is simple and I should have a bug fix version out today.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
All,

   A new release is available:

Version 3.6.8 - 6/23/2014
* Fixed a bug with sum field when the format was currency.
* If the selectedgraphicaltool has been specified or you have already used a graphical search tool
  when you switch to the graphical search tab that tool will be selected automatically.
* Uniquevalsfromfield now optimized to use returnDistinctValues if the server version is 10.1 or greater
  (this means no paging and faster unique values). Thanks to Daryl Anderson for this idea.
0 Kudos