eSearch - Auto enable BY SHAPE - Point selector on Icon return click

2350
4
Jump to solution
04-11-2016 01:51 AM
RodWoodfordOld
Occasional Contributor III

Hi Robert,

Is it possible at all to auto re enable the BY SHAPE - Point selector when clicking the eSearch widget icon after moving to another widget and then back to the eSearch widget.

Basically on startup I have the BY VALUE tab activated and have set the BY SHAPE - Point selector to be on. This works well as users can do a BY VALUE search with the map zooming and information returned, in addition the user can then click on any other feature within the zoomed map and information is returned without them needing to tab back to the BY SHAPE -point selector to activate it.

The only problem is when the user clicks another widget say the print widget and then moves back to the eSearch widget, the BY VALUE tab displays which is correct, but the BY SHAPE - point selector is deactivated which does make sense as it would interfere with other widgets like the measurement widget if it remained active. To reactivate it the user needs to tab back to the BY SHAPE function. Some users get confused; it would be nice if it could auto re enable on icon click.

I hope thismakes sense. Please try link below to get an idea of what's happening. Any
advice would be helpful.

Map Link

cheers

Rod

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
RodWoodfordOld
Occasional Contributor III

Hi Robert,

Got it to work using the following;

this.drawBox.activate('POINT');

cheers

View solution in original post

0 Kudos
4 Replies
RobertScheitlin__GISP
MVP Emeritus

Rod,

  OK, make this change to the Widget.js (line 10):

      onOpen: function () {
        if (!this.config.bufferDefaults.addtolegend) {
          if (this.graphicsLayerBuffer) {
            this.graphicsLayerBuffer.show();
          }
        }
        if (this.tempResultLayer) {
          this.tempResultLayer.show();
        }
        this.drawBox.activate(this.lastDrawTool);
      },
0 Kudos
RodWoodfordOld
Occasional Contributor III

Thanks Robert,

Added the change, but its not making any difference to the app. BY SHAPE - Point does not re enable.

cheers

0 Kudos
RodWoodfordOld
Occasional Contributor III

Hi Robert,

Got it to work using the following;

this.drawBox.activate('POINT');

cheers

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

Rod,

OK, the lastDrawTool var must be null for some reason then. Glad you got it working. Don't forget to mark this as answered.

0 Kudos