How to get rid of the Busy indicator on the top of my custom widget in Developer mode?

2387
3
Jump to solution
11-18-2015 08:03 AM
HoriaTudosie
Occasional Contributor II

I have very basic widget which display just a logo image, with a very, very simple code:

<body>
  <center>
    <img src="CanadaMapComunityLogo.png" alt="Canada Map Comunity Logo"/>
  </center>
</body>

It works fine, and the browser shows it ok, but in 'Dev Mode' I see a never-ending busy indicator on the top.

The debugger console shows it as part of the html tag, but not part of the body tag!

Is this an indication that the widget is missing some scripts, declarations, etc?

(Is it another way to display this logo on an Operation Dashboard View? (Anywhere?))

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
HoriaTudosie
Occasional Contributor II

Solved:

Although very simple (just a logo,) it still need to run a script that register it as a widget, even without template:

define([

  "dojo/_base/declare",

  "dojo/_base/lang",

  "dijit/_WidgetBase",

  //"dijit/_TemplatedMixin",

  "esri/opsdashboard/WidgetProxy"

], function (declare, lang, _WidgetBase,

            //_TemplatedMixin,

             WidgetProxy, templateString) {

    return declare("LogoWidget", [

      _WidgetBase,

      //_TemplatedMixin,

      WidgetProxy

      ], {

  });

});

View solution in original post

3 Replies
NoppadonHimananto
New Contributor II

this was happened to me. Busy indicator never end because there are something wrong in code but it don't inform any error out and it get stuck in somewhere or some part of code.

I solved this by, rewrite code or rebuild new one from sample widget that work fine.

0 Kudos
HoriaTudosie
Occasional Contributor II

Solved:

Although very simple (just a logo,) it still need to run a script that register it as a widget, even without template:

define([

  "dojo/_base/declare",

  "dojo/_base/lang",

  "dijit/_WidgetBase",

  //"dijit/_TemplatedMixin",

  "esri/opsdashboard/WidgetProxy"

], function (declare, lang, _WidgetBase,

            //_TemplatedMixin,

             WidgetProxy, templateString) {

    return declare("LogoWidget", [

      _WidgetBase,

      //_TemplatedMixin,

      WidgetProxy

      ], {

  });

});

TifPun
by
Occasional Contributor II

Thanks for sharing your solution with us, Horia. I learned something new today!

Noppadon, when you start Operations Dashboard in dev mode while you're developing and testing your extension, you can use the debug tool (see the image below) to walk through the code and check the console for any error. Very often I found that the busy indicator is caused by some resources not loaded correctly, and those information can be found from the Network tab or the Console tab). Sometimes other web debugging tools such as Fiddler can also give you clues about what went wrong.

Hope that helps,

Tif

debugTool.png

0 Kudos