| | |
| | | var reg = new RegExp("(^|&)"+ 'path' +"=([^&]*)(&|$)"); //构造一个含有目标参数的正则表达式对象 |
| | | var r = window.location.search.substr(1).match(reg); //匹配目标参数 |
| | | if (r!=null) //如果有参数跳转洪水淹没分析部件 |
| | | topic.subscribe('runWidgetByName', lang.hitch(this, this._runWidgetByName('FloodAnalysis'))); |
| | | topic.subscribe('runWidgetByName', lang.hitch(this, this._runWidgetByName(unescape(r[2])))); |
| | | else |
| | | topic.subscribe('runWidgetByName', lang.hitch(this, this._runWidgetByName('ComprehensiveSupervise'))); |
| | | topic.subscribe('runWidgetByName', lang.hitch(this, this._runWidgetByName('FloodAnalysis'))); |
| | | }, |
| | | _runWidgetByName: function (name) { |
| | | for (i = 0; i < this.appConfig.widgetPool.widgets.length; i++) { |
| | |
| | | var middleNode = null; |
| | | var lastNode = null; |
| | | var finalNode = null; |
| | | |
| | | for (var i = 0; i < iconNode.length; i++) { |
| | | if (iconNode[i].name == 'AnalysisOfBarrierLake') { |
| | | firstNode = html.create('li', { |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | // node = html.create('div', { |
| | |
| | | }, |
| | | |
| | | _onIconClick: function (node) { |
| | | |
| | | if (node.innerHTML == '风险预警') { |
| | | window.open('http://localhost:8080/hsyj/index.html', '_self') |
| | | return |
| | | } |
| | | if (!node.config.widgets || node.config.widgets.length === 1 || |
| | | node.config.openType === 'openAll') { |
| | | //widget or group with 'openAll' open type |