Select to view content in your preferred language

Enhanced Search Widget for FlexViewer 2.1

110079
767
10-25-2010 02:13 PM
RobertScheitlin__GISP
MVP Emeritus
All Here is my next widget in the FlexViewer 2.1 series

Special thanks to Erwan Caradec for contributing to this code.

The Enhanced Search Widget extends the standard search widget with a floating data grid and a new spatial query w/buffering.

http://www.arcgis.com/home/item.html?id=5d4995ccdb99429185dfd8d8fb2a513e
Tags (2)
0 Kudos
767 Replies
LeeAllen
Frequent Contributor
Nice work Robert,
It appears I am missing an image file...when I select the "Graphical Search" option. The far-left icon appears to missing?  I believe I have installed the widget properly.

I have attached a screen shot.
Any help would be appreciated.


In the SearchWidget.mxml, line 1473 refers to "assets/images/i_draw_draw.png".  You either have to change this to match the draw icon you are using (i_draw.png) or have an icon named i_draw_draw.png.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
All,

   Just hang tight with all the issue you are having i.e. the missing png and the results only having the titleField. I have pulled this widget until I get these things fixed and will have a new version fixing all of these issues ASAP.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
All,

   Let's try this again. Version 2.1.1

Here is what was done

* Fixes issue with Search Results not having all the specified fields
* Enhancement made to use fields alias if an alias is not specified in the SearchWidget.xml
* Enhancement made to use the dateformat attribute in the datagrid for date fields also
* Fixed integration issue with the draw widget
* Fixed the issue of the graphics not be clear from the screen when the widget is closed
0 Kudos
MikeHargreaves
Emerging Contributor
Thanks Robert, seems to be working better now.
0 Kudos
AlexJones
Emerging Contributor
Robert using the default config you posted am I correct in that it will not enter into this if statement? Line 1361.
if(!gridFields){
      showMessage("No Datagrid configured for this layer", false);
      return;
     }

It seems to open the datagrid for me even without grid fields defined.

If I check the length I can return the message. Might just be me, but I assume others might run into a similar issue.
if(gridFields.length == 0){...}


Awesome widget. Thanks again.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Alex,

  Thanks for that info. There was so much code to convert and create to get this widget converted to FlexViewer 2.1 and all Spark component and skins that I knew I would miss a couple of things. I will include that change in the next version that I am working on that allows for number and currency formatting of fields in addition to the date formatting.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
All,

   Don't forget to rate and comment on this code here

http://www.arcgis.com/home/item.html?id=5d4995ccdb99429185dfd8d8fb2a513e
0 Kudos
SamBishop
Deactivated User
Thanks for the updated version Robert.  Field alias is now working great.  Just noticed though that I'm not seeing my hyperlink field in the grid anymore - with or without <hyperlinkaliastext> defined.  But it is in the .csv download (minus a column heading)...
0 Kudos
philippschnetzer
Frequent Contributor
Is anyone having the issue I am?:

Clicking on the 'Use Existing Draw Widget Graphics' returns 'There are no graphics available'.  I have included

graphicsLayer.name = "myGraLay";
graphicsLayer.id = "myGraLay";


in the DrawWidget.mxml, all the modules are loaded and I haven't made any other changes.  I am using the enhanced Draw Widget also provided by Robert.

Thank you!
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Phillip,

   I tested this with my enhanced draw widget... In the DrawWidget.mxml make use you have

graphicsLayer = new GraphicsLayer();
    graphicsLayer.id = "myGraLay";
    graphicsLayer.name = "myGraLay";
    graphicsLayer.addEventListener(GraphicEvent.GRAPHIC_ADD,addContextMenu);
    map.addLayer(graphicsLayer);


At the very beginning of the init function.
0 Kudos