赣州市洪水风险预警系统三维版本
xiebin
2023-02-22 61e1929fda25f9b332407bed02dbe924e9713b3e
修改风险预警菜单跳转方式、取消23D系统跳转
2 files modified
119 ■■■■■ changed files
index.html 88 ●●●● patch | view | raw | blame | history
themes/FoldableTheme/widgets/HeaderController/Widget.js 31 ●●●● patch | view | raw | blame | history
index.html
@@ -126,50 +126,50 @@
    </head>
    <body class="claro jimu-main-font">
        <style>
            .ss {
                border-radius: 5px;
                height: 32px;
                width: 32px;
                position: fixed;
            }
            .map3d-system {
                background: #303336 url('images/3d-2-03.png');
                border: 1px solid #303336;
                background-size: cover;
                z-index:1;
                cursor:pointer;
                right: 13px;
                bottom: 240px;
            }
            .map3d-system:hover{
                color: #fff;
                fill: #fff;
                background: #48b url('images/3d-2-03.png');
                background-size: cover;
                border-color: #aef;
                box-shadow: 0 0 8px #fff;
            }
            .map3d-2d {
                background: #303336 url('images/2d-2-02.png');
                border: 1px solid #303336;
                background-size: cover;
                z-index:6;
                cursor:pointer;
                right: 50px;
                bottom: 240px;
            }
            .map3d-2d:hover{
                color: #fff;
                fill: #fff;
                background: #48b url('images/2d-2-02.png');
                background-size: cover;
                border-color: #aef;
                box-shadow: 0 0 8px #fff;
            }
        </style>
        <div class="map3d-system ss" id="map3d" title="系统切换" onclick="map3dClick()"></div>
        <div class="map3d-2d ss" id="map2d" title="切换2D" onclick="javascript:window.location='http://localhost:63342/hsyj/index.html'"></div>
<!--        <style>-->
<!--            .ss {-->
<!--                border-radius: 5px;-->
<!--                height: 32px;-->
<!--                width: 32px;-->
<!--                position: fixed;-->
<!--            }-->
<!--            .map3d-system {-->
<!--                background: #303336 url('images/3d-2-03.png');-->
<!--                border: 1px solid #303336;-->
<!--                background-size: cover;-->
<!--                z-index:1;-->
<!--                cursor:pointer;-->
<!--                right: 13px;-->
<!--                bottom: 240px;-->
<!--            }-->
<!--            .map3d-system:hover{-->
<!--                color: #fff;-->
<!--                fill: #fff;-->
<!--                background: #48b url('images/3d-2-03.png');-->
<!--                background-size: cover;-->
<!--                border-color: #aef;-->
<!--                box-shadow: 0 0 8px #fff;-->
<!--            }-->
<!--            .map3d-2d {-->
<!--                background: #303336 url('images/2d-2-02.png');-->
<!--                border: 1px solid #303336;-->
<!--                background-size: cover;-->
<!--                z-index:6;-->
<!--                cursor:pointer;-->
<!--                right: 50px;-->
<!--                bottom: 240px;-->
<!--            }-->
<!--            .map3d-2d:hover{-->
<!--                color: #fff;-->
<!--                fill: #fff;-->
<!--                background: #48b url('images/2d-2-02.png');-->
<!--                background-size: cover;-->
<!--                border-color: #aef;-->
<!--                box-shadow: 0 0 8px #fff;-->
<!--            }-->
<!--        </style>-->
<!--        <div class="map3d-system ss" id="map3d" title="系统切换" onclick="map3dClick()"></div>-->
<!--        <div class="map3d-2d ss" id="map2d" title="切换2D" onclick="javascript:window.location='http://localhost:63342/hsyj/index.html'"></div>-->
        <div id="main-loading">
            <div id="app-loading"></div>
themes/FoldableTheme/widgets/HeaderController/Widget.js
@@ -100,9 +100,9 @@
                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++) {
@@ -776,6 +776,7 @@
                        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', {
@@ -979,28 +980,7 @@
                    }
                }
                // node = html.create('div', {
@@ -1072,6 +1052,11 @@
            },
            _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