Authored by xwx

Merge branch 'master' of http://113.200.75.45:82/monitor_v3/hg-monitor-web into master-v32-xwx

... ... @@ -337,30 +337,31 @@ layui.define(['soulTable', 'commonDetail', 'common', 'laytpl', 'view', 'admin',
{field: 'cpuSetRate', title: 'CPU分配率', align: 'center', minWidth: 120, templet: '#cpuSetRateTpl'},
{field: 'memorySetRate', title: '内存分配率', align: 'center', minWidth: 120, templet: '#memorySetRateTpl'},
{field: 'storageSetRate', title: '存储分配率', align: 'center', minWidth: 120, templet: '#storageSetRateTpl'},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'resTypeName', title: '资源类型', minWidth: 101, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: 120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: 120, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: 120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: 120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'hostState', title: '主机状态', align: 'center', minWidth: x_110, templet: '#hostStateTpl', sort: true},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true}
{field: 'clusterState', title: '资源池状态', align: 'center', minWidth: x_120,templet:'#clusterStateTpl'},
//{field: 'hostState', title: '主机状态', align: 'center', minWidth: x_110, templet: '#hostStateTpl', sort: true},
{field: 'lastColTime', title: '最近采集时间', minWidth: 160, align: 'center', sort: true}
],
"HUAWEI_CLOUD_CLUSTER": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'cpuSetRate', title: 'CPU分配率', align: 'center', minWidth: 120, templet: '#cpuSetRateTpl'},
{field: 'memorySetRate', title: '内存分配率', align: 'center', minWidth: 120, templet: '#memorySetRateTpl'},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'cpuSetRate', title: 'CPU分配率', align: 'center', minWidth: x_120, templet: '#cpuSetRateTpl'},
{field: 'memorySetRate', title: '内存分配率', align: 'center', minWidth: x_120, templet: '#memorySetRateTpl'},
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_120, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: 160, align: 'center', sort: true}
// {field: 'linkState', title: '连接状态', align: 'center', minWidth: x_120, templet: '#linkStateTpl', sort: true}
],
"HUAWEI_CLOUD_PHYSICSHOST": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
... ... @@ -400,58 +401,58 @@ layui.define(['soulTable', 'commonDetail', 'common', 'laytpl', 'view', 'admin',
"HUAWEI_CLOUD_STORAGE": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
{field: 'cpuRate', title: 'CPU使用率', align: 'center', minWidth: x_130, templet: '#cpuRateTpl', sort: true},
{field: 'memoryRate', title: '内存使用率', align: 'center', minWidth: x_130, templet: '#memoryRateTpl', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_120, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_160, align: 'center', sort: true},
{field: 'runState', title: '运行状态', minWidth: x_120, align: 'center', sort: true,templet: '#runStateTpl'}
],
"HUAWEI_CLOUD_SWITCHBOARD": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
{field: 'ip', title: 'IP地址', minWidth: x_110, align: 'center', sort: true},
// {field: 'cpuRate', title: 'CPU使用率', align: 'center', minWidth: x_130, templet: '#cpuRateTpl', sort: true},
// {field: 'memoryRate', title: '内存使用率', align: 'center', minWidth: x_130, templet: '#memoryRateTpl', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_120, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWdth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_160, align: 'center', sort: true},
// {field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
],
"HUAWEI_CLOUD_FIREWALL": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
{field: 'ip', title: 'IP地址', minWidth: x_120, align: 'center', sort: true},
// {field: 'cpuRate', title: 'CPU使用率', align: 'center', minWidth: x_130, templet: '#cpuRateTpl', sort: true},
// {field: 'memoryRate', title: '内存使用率', align: 'center', minWidth: x_130, templet: '#memoryRateTpl', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_130, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_160, align: 'center', sort: true}
//{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
],
"ALI_CLOUD_ECS": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
... ... @@ -459,60 +460,61 @@ layui.define(['soulTable', 'commonDetail', 'common', 'laytpl', 'view', 'admin',
{field: 'memorySize', title: '内存大小', align: 'center', minWidth: x_120, sort: true, templet: '<div>{{d.memorySize}} GB</div>'},
{field: 'memoryRate', title: '内存使用率', align: 'center', minWidth: x_130, templet: '#memoryRateTpl', sort: true},
{field: 'ptName', title: '所属平台', minWidth: x_130, align: 'center', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_130, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_160, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', minWidth: x_120, templet: '#linkStateTpl', sort: true}
],
"ALI_CLOUD_RDS": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
{field: 'ip', title: 'IP地址', minWidth: x_130, align: 'center', sort: true},
{field: 'cpuRate', title: 'CPU使用率', align: 'center', minWidth: x_130, templet: '#cpuRateTpl', sort: true},
{field: 'memoryRate', title: '内存使用率', align: 'center', minWidth: x_130, templet: '#memoryRateTpl', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_130, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_160, align: 'center', sort: true},
// {field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
],
"ALI_CLOUD_SLB": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
{field: 'ip', title: 'IP地址', minWidth: x_130, align: 'center', sort: true},
{field: 'resTypeName', title: '资源类型', minWidth: x_120, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_130, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_160, align: 'center', sort: true},
{field: 'runState', title: '运行状态', minWidth: x_120, align: 'center', sort: true,templet: '#runStateTpl'}
//{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
],
"ALI_CLOUD_OSS": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
{
field: 'resName', title: '资源名称', minWidth: 250, sort: true,
field: 'resName', title: '资源名称', minWidth: x_250, sort: true,
templet: '#resindex_resName'
},
{field: 'ip', title: 'IP地址', width: 130, align: 'center', sort: true},
{field: 'resTypeName', title: '资源类型', width: 101, align: 'center'},
{field: 'adminName', title: '负责人', width: 123, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', width: 118, align: 'center', sort: true},
{field: 'state', title: '资源状态', width: 98, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', width: 83, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', width: 161, align: 'center', sort: true},
{field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
// {field: 'ip', title: 'IP地址', minWidth: x_130, align: 'center', sort: true},
{field: 'resTypeName', title: '资源类型', minWidth: x_110, align: 'center'},
{field: 'adminName', title: '负责人', minWidth: x_120, align: 'center', sort: true},
{field: 'adminPhone', title: '负责人电话', minWidth: x_130, align: 'center', sort: true},
{field: 'state', title: '资源状态', minWidth: x_120, align: 'center', sort: true, templet: '#resStateTpl'},
{field: 'health', title: '健康状态', minWidth: x_120, align: 'center', sort: true, templet: '#healthTpl'},
{field: 'lastColTime', title: '最近采集时间', minWidth: x_120, align: 'center', sort: true},
// {field: 'linkState', title: '连接状态', align: 'center', width: 85, templet: '#linkStateTpl', sort: true}
],
"ALI_ARMS": [
//{type: 'numbers', title: '序号', align: 'center', fixed: 'left'},
... ... @@ -2620,9 +2622,9 @@ layui.define(['soulTable', 'commonDetail', 'common', 'laytpl', 'view', 'admin',
return false;
}
// 阿里云,华为云不能点击
if(resType == 'ALI_CLOUD_PLAT' || resType == 'HUAWEI_CLOUD_PLAT'){
return false;
}
// if(resType == 'ALI_CLOUD_PLAT' || resType == 'HUAWEI_CLOUD_PLAT'){
// return false;
// }
return true;
},
... ...
/**
* @desc 华为云集群
* @author joke
* @date 2020/4/12 23:35
**/
layui.define(['commonDetail','common'], function (exports) {
var commonDetail = layui.commonDetail;
var common = layui.common;
//对外暴露的接口
exports('huawei_cloud_plat', function (data) {
var resId = '';
var showFlag = common.getUrlParam("show");
if(showFlag && showFlag == '0'){
resId = common.getUrlParam("resId");
}else{
resId = data.resId;
}
commonDetail.bindTips();
//基本信息
var jbxxKpi = "KPIE13DD9A3,KPI9E5E1B3E,KPIF74D9D2B";
reload()
//渲染页面
function reload() {
//资源状态
commonDetail.renderResHealth("huawei_cloud_plat_state",resId);
//基本信息
commonDetail.renderText("huawei_cloud_plat_baseinfo",resId,jbxxKpi);
// CPU分配率
commonDetail.renderGauge("huawei_cloud_plat_cpu_rate",resId,"KPIBFA3F5CD");
// 内存分配率
commonDetail.renderGauge("huawei_cloud_plat_mem_rate",resId,"KPIC40A80AC");
// CPU使用率走势(12小时)
commonDetail.renderLineCharat("huawei_cloud_plat_cpu_linechart",resId,"KPI7054BC34","CPU使用率","cpu");
// 内存使用率走势(12小时)
commonDetail.renderLineCharat("huawei_cloud_plat_memeryuse_linechart",resId,"KPI31CB8D97","内存使用率","mem");
// CPU分配率走势(12小时)
commonDetail.renderLineCharat("huawei_cloud_plat_cpuset_linechart",resId,"KPIBFA3F5CD","CPU分配率","");
// 内存分配率走势(12小时)
commonDetail.renderLineCharat("huawei_cloud_plat_memeryset_linechart",resId,"KPIC40A80AC","内存分配率","");
//活动告警
commonDetail.renderActiveAlarms("huawei_cloud_plat_alarms",resId);
}
//定时任务
var timer = setInterval(function () {
reload()
},commonDetail.timerTime);
commonDetail.detailTimer.push(timer);
});
});
\ No newline at end of file
... ...
... ... @@ -1031,14 +1031,14 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
noClick($(this));
});
//华为云,阿里云不让点击,并且提示暂无监控信息
var $hds = $('span[data-restype="HUAWEI_CLOUD_PLAT"]');
$.each($hds, function (i, v) {
noClick($(this));
});
var $hds = $('span[data-restype="ALI_CLOUD_PLAT"]');
$.each($hds, function (i, v) {
noClick($(this));
});
// var $hds = $('span[data-restype="HUAWEI_CLOUD_PLAT"]');
// $.each($hds, function (i, v) {
// noClick($(this));
// });
// var $hds = $('span[data-restype="ALI_CLOUD_PLAT"]');
// $.each($hds, function (i, v) {
// noClick($(this));
// });
soulTable.render(this)
... ...
<!--华为云集群-->
<article class="page-container template">
<div class="page-panel">
<div class="main">
<div class="layui-card template_detail_content">
<div class="layui-card-body">
<div class="lay-row">
<div class="lay-row-item">
<h5 class="lay-row-title">资源状态</h5>
<div class="res-state" id="huawei_cloud_plat_state"></div>
</div>
<div class="lay-row-item lay-row-item--auto-width">
<h5 class="lay-row-title">基本信息<i data-id="huawei_cloud_plat_baseinfo" class="iconfont detail_base_info">&#xe61e;</i></h5>
<ul class="info-table" id="huawei_cloud_plat_baseinfo"></ul>
</div>
</div>
<div class="lay-row">
<div class="lay-row-item">
<h5 class="lay-row-title">CPU分配率</h5>
<ul id="huawei_cloud_plat_cpu_rate" class="pie-wrap dasboard">
<li data-degree="0" class="pie-half pie-half-border-color-3">
<div class="pie-half-text">
<b>0%</b>
<span></span>
</div>
</li>
</ul>
</div>
<div class="lay-row-item">
<h5 class="lay-row-title">内存分配率</h5>
<ul id="huawei_cloud_plat_mem_rate" class="pie-wrap dasboard">
<li data-degree="0" class="pie-half pie-half-border-color-3">
<div class="pie-half-text">
<b>0%</b>
<span></span>
</div>
</li>
</ul>
</div>
</div>
<div class="lay-row">
<div class="lay-row-item">
<h5 class="lay-row-title">CPU使用率走势(12小时)</h5>
<div id="huawei_cloud_plat_cpu_linechart" class="detail_line_chart"></div>
</div>
<div class="lay-row-item">
<h5 class="lay-row-title">内存使用率走势(12小时)</h5>
<div id="huawei_cloud_plat_memeryuse_linechart" class="detail_line_chart"></div>
</div>
</div>
<div class="lay-row">
<div class="lay-row-item">
<h5 class="lay-row-title">CPU分配率走势(12小时)</h5>
<div id="huawei_cloud_plat_cpuset_linechart" class="detail_line_chart"></div>
</div>
<div class="lay-row-item">
<h5 class="lay-row-title">内存分配率走势(12小时)</h5>
<div id="huawei_cloud_plat_memeryset_linechart" class="detail_line_chart"></div>
</div>
</div>
<div class="lay-row">
<div class="lay-row-item">
<h5 class="lay-row-title">实时告警动态</h5>
<div id="huawei_cloud_plat_alarms"></div>
</div>
</div>
</div>
</div>
</div>
</div>
</article>
<textarea id="huawei_cloud_plat_param_id" style="display: none;">{{d}}</textarea>
<script>
layui.use('huawei_cloud_plat', function (fn) {
var $ = layui.$;
var parm = $("#huawei_cloud_plat_param_id").val();
if(parm.indexOf('{{d') != -1){
fn();
}else{
fn(JSON.parse(parm));
}
});
</script>
\ No newline at end of file
... ...
... ... @@ -941,6 +941,27 @@
<a class="layui-icon reslist-view-topo hide" data-resid="{{d.resId}}" style="color: #FEB61E; font-size: 14px; margin-left: 10px;" lay-tips="查看资源拓扑"><i class="iconfont">&#XE515;</i></a>
</div>
</script>
<!--资源池状态-->
<script type="text/html" id="clusterStateTpl">
{{# if(d.clusterState === '正常'){ }}
<button type="button" class="layui-btn layui-btn-danger layui-bg-green layui-btn-radius layui-btn-xs p-0-15">正常
</button>
{{# }else{ }}
<button type="button" class="layui-btn layui-btn-radius layui-bg-red layui-btn-xs p-0-15">异常</button>
{{# } }}
</script>
<!--运行状态-->
<script type="text/html" id="runStateTpl">
{{# if(d.runState === '正常'){ }}
<button type="button" class="layui-btn layui-btn-danger layui-bg-green layui-btn-radius layui-btn-xs p-0-15">正常
</button>
{{# }else{ if(d.runState === '运行中'){ }}
<button type="button" class="layui-btn layui-btn-danger layui-bg-green layui-btn-radius layui-btn-xs p-0-15">运行中</button>
{{# }else{ }}
<button type="button" class="layui-btn layui-btn-radius layui-bg-red layui-btn-xs p-0-15">异常</button>
{{# } }}
{{# } }}
</script>
<script type="text/html" id="weblogicIpTpl">
<div>{{d.ip?d.ip:""}}</div>
</script>
... ...