Authored by 鲁尚清

Merge branch 'master' of http://192.168.1.136:82/monitor_v3/hg-monitor-web into …

…master-v32-lushangqing
@@ -376,7 +376,8 @@ layui.define(['soulTable', 'commonDetail', 'common', 'laytpl', 'view', 'admin', @@ -376,7 +376,8 @@ layui.define(['soulTable', 'commonDetail', 'common', 'laytpl', 'view', 'admin',
376 {field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'}, 376 {field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
377 {field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'}, 377 {field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
378 {field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true}, 378 {field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
379 - {field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true} 379 + // 2021-11-22 徐毫杰 连接状态无数据改成展示主机状态
  380 + {field: 'hostState', title: '主机状态', align: 'center', minWidth: x_110, templet: '#hostStateTpl', sort: true}
380 ], 381 ],
381 "HUAWEI_CLOUD_VIRTUALHOST": [ 382 "HUAWEI_CLOUD_VIRTUALHOST": [
382 //{type: 'numbers', title: '序号', align: 'center', fixed: 'left'}, 383 //{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
@@ -197,7 +197,7 @@ layui.define(['common', 'admin', 'echarts', 'common', 'table', 'sessions'], func @@ -197,7 +197,7 @@ layui.define(['common', 'admin', 'echarts', 'common', 'table', 'sessions'], func
197 series: [ 197 series: [
198 { 198 {
199 type: 'bar', 199 type: 'bar',
200 - barWidth: '60%', 200 + barWidth: '40%',
201 data: line, 201 data: line,
202 itemStyle: { 202 itemStyle: {
203 normal: { 203 normal: {
@@ -9,7 +9,11 @@ @@ -9,7 +9,11 @@
9 var arr = []; 9 var arr = [];
10 window.location.hash.split('/').forEach(function (v, i) { 10 window.location.hash.split('/').forEach(function (v, i) {
11 if (v.indexOf('=') != -1 && v.indexOf('reportCode') != -1) { 11 if (v.indexOf('=') != -1 && v.indexOf('reportCode') != -1) {
12 - viewURL = viewURL.replaceAll('reportCode',v.split('=')[1]) 12 + try {
  13 + viewURL = viewURL.replaceAll('reportCode',v.split('=')[1])
  14 + } catch (e) {
  15 + viewURL = viewURL.replace('reportCode',v.split('=')[1])
  16 + }
13 } 17 }
14 }); 18 });
15 19
@@ -74,7 +74,7 @@ @@ -74,7 +74,7 @@
74 <dd layadmin-event="toDZSWJScreen" style="text-align: left;"><a><img src="/src/style/img/icon-dianzishuiwuju.png" style="width: 16px;height: 16px">&nbsp;&nbsp;电子税务大屏</a></dd> 74 <dd layadmin-event="toDZSWJScreen" style="text-align: left;"><a><img src="/src/style/img/icon-dianzishuiwuju.png" style="width: 16px;height: 16px">&nbsp;&nbsp;电子税务大屏</a></dd>
75 <dd layadmin-event="toYTHViewScreen" style="text-align: left;"><a><img src="/src/style/img/icon-yitihuadaping.png" style="width: 16px;height: 16px">&nbsp;&nbsp;一体化视图</a></dd> 75 <dd layadmin-event="toYTHViewScreen" style="text-align: left;"><a><img src="/src/style/img/icon-yitihuadaping.png" style="width: 16px;height: 16px">&nbsp;&nbsp;一体化视图</a></dd>
76 <dd layadmin-event="toBiZhEalZhSYS" style="text-align: left;"><a><img src="/src/style/img/icon-YWJKD.png" style="width: 16px;height: 16px">&nbsp;&nbsp;业务健康度</a></dd> 76 <dd layadmin-event="toBiZhEalZhSYS" style="text-align: left;"><a><img src="/src/style/img/icon-YWJKD.png" style="width: 16px;height: 16px">&nbsp;&nbsp;业务健康度</a></dd>
77 - <dd layadmin-event="toCMDB" style="text-align: left;"><a><img src="/src/style/img/loading-mj.png" style="width: 16px;height: 16px">&nbsp;&nbsp;CMDB</a></dd> 77 + <dd layadmin-event="toCMDB" style="text-align: left;"><a><img src="/src/style/img/icon-CMDB.png" style="width: 16px;height: 16px">&nbsp;&nbsp;CMDB</a></dd>
78 </dl> 78 </dl>
79 </script> 79 </script>
80 </li> 80 </li>
@@ -810,6 +810,10 @@ @@ -810,6 +810,10 @@
810 <button type="button" class="layui-btn layui-bg-red layui-btn-radius layui-btn-xs p-0-15 cant-click"> 810 <button type="button" class="layui-btn layui-bg-red layui-btn-radius layui-btn-xs p-0-15 cant-click">
811 断开连接 811 断开连接
812 </button> 812 </button>
  813 + {{# }else if(d.hostState != null && d.hostState == '正常'){ }}
  814 + <button type="button" class="layui-btn layui-bg-green layui-btn-radius layui-btn-xs p-0-15 cant-click">
  815 + 正常
  816 + </button>
813 {{# }else{ }} 817 {{# }else{ }}
814 <button type="button" 818 <button type="button"
815 class="layui-btn layui-btn-radius layui-bg-gray layui-btn-xs p-0-15 cant-click">{{ 819 class="layui-btn layui-btn-radius layui-bg-gray layui-btn-xs p-0-15 cant-click">{{
@@ -273,7 +273,12 @@ export default { @@ -273,7 +273,12 @@ export default {
273 273
274 let getChartData = () => { 274 let getChartData = () => {
275 275
276 - let timeScope = form.value.scene.timeScope.replaceAll("time_scope_", "") 276 + let timeScope = '';
  277 + try {
  278 + timeScope = form.value.scene.timeScope.replaceAll("time_scope_", "")
  279 + }catch (e) {
  280 + timeScope = form.value.scene.timeScope.replace("time_scope_", "")
  281 + }
277 if (timeScope == '') { 282 if (timeScope == '') {
278 proxy.$global.showMsg("请选择时间范围!", "warning"); 283 proxy.$global.showMsg("请选择时间范围!", "warning");
279 return; 284 return;
@@ -7,9 +7,8 @@ @@ -7,9 +7,8 @@
7 <div class="analysis-index-container" style="display: grid;"> 7 <div class="analysis-index-container" style="display: grid;">
8 <img src="/vue3/src/assets/images/analysis/icon-add.png" style="margin-left: 20px;"></img> 8 <img src="/vue3/src/assets/images/analysis/icon-add.png" style="margin-left: 20px;"></img>
9 <span style="text-align: center;line-height: 50px;color: #0C4493">点击添加对比分析</span> 9 <span style="text-align: center;line-height: 50px;color: #0C4493">点击添加对比分析</span>
10 -  
11 </div> 10 </div>
12 </router-link> 11 </router-link>
13 12
14 </div> 13 </div>
15 -</div>  
  14 +</div>