Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cmszMonitorAnalysis
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liuna
cmszMonitorAnalysis
Commits
4a7df7e1
Commit
4a7df7e1
authored
Dec 24, 2017
by
莫林毅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
监控运营 ->告警关联诊断 '创建'&'修改'关联配置 界面
修改 '数值控制' bug
parent
a1e0ac68
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
55 additions
and
54 deletions
+55
-54
AssociateDiagosisDetailController.java
...b/monitoroperation/AssociateDiagosisDetailController.java
+1
-3
AssociateDiagosisConfiguration.jsp
...views/MonitorOperation/AssociateDiagosisConfiguration.jsp
+1
-6
CreateDiagosis.jsp
.../webapp/WEB-INF/views/MonitorOperation/CreateDiagosis.jsp
+26
-23
UpdateAnaInfo.jsp
...n/webapp/WEB-INF/views/MonitorOperation/UpdateAnaInfo.jsp
+26
-21
associatediagosisconfiguration.js
src/main/webapp/static/js/associatediagosisconfiguration.js
+1
-1
No files found.
src/main/java/com/hp/cmsz/web/monitoroperation/AssociateDiagosisDetailController.java
View file @
4a7df7e1
...
...
@@ -137,7 +137,6 @@ public class AssociateDiagosisDetailController {
format
.
parse
(
warnEndTime
);
}
catch
(
Exception
e
)
{
e
.
getMessage
();
System
.
out
.
println
(
e
.
getMessage
());
return
str
;
}
List
<
AssociateDiagosisDetail
>
diagosisDetails
=
associateDiagosisDetailService
.
...
...
@@ -192,8 +191,7 @@ public class AssociateDiagosisDetailController {
findXcdWorkingOrderInfoByEventHappenTimeAndBusinessRecoveryTimeAndProvinceId
(
eventHappenTime
,
businessRecoveryTime
,
provinceId
);
List
<
XcdChangeOrder
>
xcdChangeOrders
=
xcdChangeOrderDao
.
findXcdChangeOrderListByChangeStartTimeAndChangeEndTimeAndProvinceId
(
eventHappenTime
,
businessRecoveryTime
,
provinceId
);
System
.
out
.
println
(
"xcdChangeOrders len ="
+
xcdChangeOrders
.
size
());
System
.
out
.
println
(
"xcdWorkingOrderInfos len ="
+
xcdWorkingOrderInfos
.
size
());
map
.
put
(
"xcdWorkingOrderInfos"
,
xcdWorkingOrderInfos
);
map
.
put
(
"xcdChangeOrders"
,
xcdChangeOrders
);
...
...
src/main/webapp/WEB-INF/views/MonitorOperation/AssociateDiagosisConfiguration.jsp
View file @
4a7df7e1
...
...
@@ -100,12 +100,7 @@
data-placement=
"bottom"
></span>
</div>
<
%
--
<
div
class=
"bt-list-import"
>
<a
href=
"#"
id=
"downloadEecel"
class=
""
>
<span
class=
"glyphicon glyphicon-import"
></span>
<span
class=
"glyphicon-class"
>
导出Excel
</span>
</a>
</div>
--%>
</div>
<div
class=
"row"
>
...
...
src/main/webapp/WEB-INF/views/MonitorOperation/CreateDiagosis.jsp
View file @
4a7df7e1
...
...
@@ -383,8 +383,8 @@
//修改一条参数
function
updateRow
(
e
)
{
var
pro
=
prompt
(
"请输入"
,
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
);
var
initK
=
Number
(
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
);
var
pro
=
prompt
(
"请输入 0~"
+
initK
,
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
);
pro
=
$
.
trim
(
pro
);
if
(
$
.
isNumeric
(
pro
))
{
pro
=
parseFloat
(
pro
);
...
...
@@ -392,21 +392,27 @@
if
(
pro
>
0
)
{
if
(
initK
>=
pro
)
{
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
=
parseFloat
(
pro
);
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
=
parseFloat
(
pro
)
.
toFixed
(
2
)
;
sumkpiWeightTdVal
-=
initK
;
sumkpiWeightTdVal
+=
pro
;
var
maxV
=
(
1
-
Number
(
sumkpiWeightTdVal
)).
toFixed
(
2
);
$
(
"#kpiWeightTd"
).
val
(
maxV
);
}
else
{
$
(
"#kpiWeightTd"
).
val
(
maxV
===
'0.00'
?
''
:
maxV
);
}
else
{
var
k
=
sumkpiWeightTdVal
-
initK
+
pro
;
if
(
k
<=
1.00
)
{
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
=
parseFloat
(
pro
);
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
=
parseFloat
(
pro
)
.
toFixed
(
2
)
;
sumkpiWeightTdVal
-=
initK
;
sumkpiWeightTdVal
+=
pro
;
var
maxV
=
(
1
-
Number
(
sumkpiWeightTdVal
)).
toFixed
(
2
);
$
(
"#kpiWeightTd"
).
val
(
maxV
);
$
(
"#kpiWeightTd"
).
val
(
maxV
===
'0.00'
?
''
:
maxV
);
}
else
{
$
.
alert
(
"输入值过大,请输入0~"
+
initK
);
}
}
}
else
{
$
.
alert
(
"请输入 大于 0 的值"
);
}
}
}
...
...
@@ -415,7 +421,7 @@
function
deleteRow
(
e
)
{
var
v
=
$
(
e
).
parent
().
prev
().
text
();
sumkpiWeightTdVal
=
sumkpiWeightTdVal
-
v
;
$
(
"#kpiWeightTd"
).
val
((
1.00
-
sumkpiWeightTdVal
).
toFixed
(
2
));
$
(
"#kpiWeightTd"
).
val
((
1.00
-
sumkpiWeightTdVal
)
===
0
?
''
:
parseFloat
(
1.00
-
sumkpiWeightTdVal
)
.
toFixed
(
2
));
var
id
=
Number
(
e
.
title
);
dimKpiSelected
.
splice
(
$
.
inArray
(
id
,
dimKpiSelected
),
1
);
$
(
e
).
parent
().
parent
().
remove
();
...
...
@@ -442,8 +448,11 @@
//form表单提交
$
(
"#modelSubmit"
).
click
(
function
()
{
//sumkpiWeightTdVal=sumkpiWeightTdVal.toFixed(2);
sumkpiWeightTdVal
=
parseFloat
(
2
);
/*sumkpiWeightTdVal=sumkpiWeightTdVal.toFixed(2);
sumkpiWeightTdVal =parseFloat(sumkpiWeightTdVal);*/
// alert("sumkpiWeightTdVal "+sumkpiWeightTdVal);
// alert("sumkpiWeightTdVal "+typeof sumkpiWeightTdVal);
// return;
if
(
sumkpiWeightTdVal
<
1.00
)
{
$
.
alert
(
"权限总和需 为 1"
);
return
;
...
...
@@ -633,7 +642,7 @@
// 业务 复选框 点击事件
function
BusinessCheckClick
()
{
//$("#dimKpiListTd").empty();
// 重置 指标 一栏 筛选保留原有的 和已选择的 指标
$
(
"input[name='dimKpiCheck']"
).
each
(
function
(
e
)
{
if
(
!
$
(
this
).
attr
(
"checked"
))
{
...
...
@@ -731,12 +740,14 @@
var
kpiWeightTdVal
=
$
.
trim
(
$
(
"#kpiWeightTd"
).
val
());
if
(
kpiWeightTdVal
==
""
||
kpiWeightTdVal
==
0
)
{
$
.
alert
(
"权重不能为空"
);
var
mmm_1
=
(
1
-
Number
(
sumkpiWeightTdVal
)).
toFixed
(
2
);
$
(
"#kpiWeightTd"
).
val
(
mmm_1
===
'0.00'
?
''
:
mmm_1
);
return
;
}
if
(
kpiWeightTdVal
<
0
)
{
$
.
alert
(
"权重不能为负"
);
var
mmm
=
(
1
-
Number
(
sumkpiWeightTdVal
)).
toFixed
(
2
);
$
(
"#kpiWeightTd"
).
val
(
mmm
);
$
(
"#kpiWeightTd"
).
val
(
mmm
===
'0.00'
?
''
:
mmm
);
return
;
}
if
(
kpiWeightTdVal
>
1.00
)
{
...
...
@@ -761,6 +772,7 @@
var
arrDimKpiidAndNameChecked
=
getArrDimKpiidAndNameChecked
();
//向 已添加指标 添加
kpiWeightTdVal
=
Number
(
kpiWeightTdVal
).
toFixed
(
2
);
for
(
var
i
=
0
;
i
<
arrDimKpiidAndNameChecked
.
length
;
i
++
)
{
var
id_name
=
arrDimKpiidAndNameChecked
[
i
];
var
addRow
=
$
(
"<tr class='"
+
id_name
.
split
(
"_"
)[
0
]
+
"_"
+
kpiWeightTdVal
+
"'><td>"
+
id_name
.
split
(
"_"
)[
1
]
+
"</td><td>"
+
kpiWeightTdVal
+
"</td><td><a href='javascript:;' title='"
+
id_name
.
split
(
"_"
)[
0
]
+
"' onclick='deleteRow(this)'>删除</a> <a href='javascript:;' onclick='updateRow(this)'>修改</a></td></tr>"
);
...
...
@@ -779,11 +791,9 @@
}
});
//sumkpiWeightTdVal+=Number(kpiWeightTdVal);
sumkpiWeightTdVal
+=
tt
;
var
maxV
=
(
1
-
Number
(
sumkpiWeightTdVal
)).
toFixed
(
2
);
$
(
"#kpiWeightTd"
).
val
(
maxV
);
//$("#kpiWeightTd").attr("max",maxV);
var
maxV
=
1
-
Number
(
sumkpiWeightTdVal
);
$
(
"#kpiWeightTd"
).
val
(
maxV
===
0
?
''
:
maxV
.
toFixed
(
2
));
});
dimKpiSelected
=
new
Array
();
...
...
@@ -797,14 +807,7 @@
return
anainfoShallSaveArr
;
}
/*curTotlakpiWeigh=0.00;
function getCurTotlakpiWeight(){
$("#addTr").find("tr").each(function(){
var weight=$(this).children().eq(1);
alert('weight'+weight);
alert('type weight'+typeof weight);
});
}*/
// 获取勾选指标的 数据 格式 id_名称
function
getArrDimKpiidAndNameChecked
()
{
...
...
src/main/webapp/WEB-INF/views/MonitorOperation/UpdateAnaInfo.jsp
View file @
4a7df7e1
...
...
@@ -276,7 +276,7 @@
$
(
"#updateAnaInf"
).
click
(
function
()
{
//跟新指标按钮
$
(
this
).
hide
();
// $("#kpiWeightTd").val(1-Number(sumkpiWeightTdVal));
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)));
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
===
0
?
''
:
parseFloat
(
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)
);
$
(
"#tr_id_dimkpi"
).
show
();
$
(
"#tr_id_weight"
).
show
();
$
(
"#addAnaInfo"
).
show
();
...
...
@@ -317,7 +317,7 @@
var
jsonDa
=
eval
(
'('
+
data
+
')'
);
var
strcheckBox
=
""
;
for
(
var
i
=
0
;
i
<
jsonDa
.
length
;
i
++
)
{
var
strInput
=
"<input type='checkbox' id=BusinessCheck_"
+
jsonDa
[
i
].
businessId
+
" name='BusinessCheck' onClick='BusinessCheckClick()' class='provinceDetail' title='"
+
jsonDa
[
i
].
businessName
+
"
value='
"
+
jsonDa
[
i
].
businessId
+
"'/><font>"
+
jsonDa
[
i
].
businessName
+
"</font>"
;
var
strInput
=
"<input type='checkbox' id=BusinessCheck_"
+
jsonDa
[
i
].
businessId
+
" name='BusinessCheck' onClick='BusinessCheckClick()' class='provinceDetail' title='"
+
jsonDa
[
i
].
businessName
+
"
' value=
"
+
jsonDa
[
i
].
businessId
+
"'/><font>"
+
jsonDa
[
i
].
businessName
+
"</font>"
;
strcheckBox
+=
strInput
;
}
...
...
@@ -436,7 +436,6 @@
}
});
},
okValue
:
"确定"
,
cancel
:
function
()
{
...
...
@@ -553,7 +552,7 @@
if
(
arrdimKpiChecked
.
indexOf
(
jsonDa
[
i
].
kpiId
)
>=
0
){
continue
;
}
var
strInput
=
"<input type='checkbox' id=dimKpiCheck_"
+
jsonDa
[
i
].
kpiId
+
" name='dimKpiCheck' class='provinceDetail' title='"
+
jsonDa
[
i
].
name
+
"' value="
+
jsonDa
[
i
].
kpiId
+
"'/><font>"
+
jsonDa
[
i
].
name
+
"</font>"
;
var
strInput
=
"<input type='checkbox' id=dimKpiCheck_"
+
jsonDa
[
i
].
kpiId
+
" name='dimKpiCheck' class='provinceDetail' title='"
+
jsonDa
[
i
].
name
+
" "
+
jsonDa
[
i
].
code
+
"' value="
+
jsonDa
[
i
].
kpiId
+
"'/><font>"
+
jsonDa
[
i
].
name
+
"</font>"
;
$
(
"#dimKpiListTd"
).
append
(
strInput
);
}
}
...
...
@@ -629,7 +628,7 @@
var
jsonDa
=
eval
(
'('
+
data
+
')'
);
var
strcheckBox
=
""
;
for
(
var
i
=
0
;
i
<
jsonDa
.
length
;
i
++
)
{
var
strInput
=
"<input type='checkbox' id=BusinessCheck_"
+
jsonDa
[
i
].
businessId
+
" name='BusinessCheck' onClick='BusinessCheckClick()' class='provinceDetail' title='"
+
jsonDa
[
i
].
businessName
+
"
value='
"
+
jsonDa
[
i
].
businessId
+
"'/>"
+
jsonDa
[
i
].
businessName
;
var
strInput
=
"<input type='checkbox' id=BusinessCheck_"
+
jsonDa
[
i
].
businessId
+
" name='BusinessCheck' onClick='BusinessCheckClick()' class='provinceDetail' title='"
+
jsonDa
[
i
].
businessName
+
"
' value=
"
+
jsonDa
[
i
].
businessId
+
"'/>"
+
jsonDa
[
i
].
businessName
;
strcheckBox
+=
strInput
;
}
$
(
"#businessActivedListTd"
).
append
(
strcheckBox
);
...
...
@@ -672,7 +671,7 @@
var
jsonDa
=
eval
(
'('
+
data
+
')'
);
var
strcheckBox
=
""
;
for
(
var
i
=
0
;
i
<
jsonDa
.
length
;
i
++
)
{
var
strInput
=
"<input type='checkbox' id=BusinessCheck_"
+
jsonDa
[
i
].
businessId
+
" name='BusinessCheck' onClick='BusinessCheckClick()' class='provinceDetail' title='"
+
jsonDa
[
i
].
businessName
+
"
value='
"
+
jsonDa
[
i
].
businessId
+
"'/>"
+
jsonDa
[
i
].
businessName
;
var
strInput
=
"<input type='checkbox' id=BusinessCheck_"
+
jsonDa
[
i
].
businessId
+
" name='BusinessCheck' onClick='BusinessCheckClick()' class='provinceDetail' title='"
+
jsonDa
[
i
].
businessName
+
"
' value=
"
+
jsonDa
[
i
].
businessId
+
"'/>"
+
jsonDa
[
i
].
businessName
;
strcheckBox
+=
strInput
;
}
$
(
"#businessActivedListTd"
).
append
(
strcheckBox
);
...
...
@@ -685,14 +684,13 @@
function
deleteRow
(
e
)
{
var
initK
=
Number
(
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
).
toFixed
(
2
);
sumkpiWeightTdVal
-=
initK
;
// $("#kpiWeightTd").val(1-Number(sumkpiWeightTdVal));
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)));
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
===
0
?
''
:
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)).
toFixed
(
2
));
$
(
e
).
parent
().
parent
().
remove
();
}
// sumkpiWeightTdVal=1.00;
function
updateRow
(
e
){
var
initK
=
Number
(
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
).
toFixed
(
2
);
var
pro
=
prompt
(
"请输入
"
,
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
);
var
pro
=
prompt
(
"请输入
0~"
+
initK
,
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
);
pro
=
$
.
trim
(
pro
);
if
(
$
.
isNumeric
(
pro
)){
pro
=
Number
(
pro
);
...
...
@@ -700,13 +698,16 @@
var
k
=
sumkpiWeightTdVal
-
initK
;
k
=
k
+
pro
;
if
(
k
<=
1.00
){
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
=
parseFloat
(
pro
);
$
(
e
).
parent
().
prev
()[
0
].
innerHTML
=
pro
.
toFixed
(
2
);
// alert("---"+pro.toFixed(2));
sumkpiWeightTdVal
-=
initK
;
sumkpiWeightTdVal
+=
pro
;
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)));
//$("#kpiWeightTd").text((1-Number(sumkpiWeightTdVal)).toFixed(2));
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
===
0
?
''
:
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)).
toFixed
(
2
)
);
}
else
{
$
.
alert
(
"输入值过大,请输入0~"
+
initK
);
}
}
else
{
$
.
alert
(
"请输入 大于 0 的值"
);
}
}
...
...
@@ -722,14 +723,18 @@
}
id_kpiWeightTd_value
=
getValueBykpiWeightTd
();
if
(
id_kpiWeightTd_value
==
0
){
$
.
alert
(
"权值不能为空"
);
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)));
if
(
id_kpiWeightTd_value
==
0
||
isNaN
(
id_kpiWeightTd_value
)
){
$
.
alert
(
"权值不能为空
或 0
"
);
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
===
0
?
''
:
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
);
return
;
}
if
(
id_kpiWeightTd_value
<
0
){
$
.
alert
(
"权值不能 小于 0"
);
return
;
}
//id_kpiWeightTd_value=Number(id_kpiWeightTd_value);
var
curm01
=
0.00
;
for
(
var
jj
=
0
;
jj
<
arrdimKpiChecked
.
length
;
jj
++
){
curm01
+=
Number
(
id_kpiWeightTd_value
);
...
...
@@ -739,22 +744,22 @@
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)));
return
;
}
id_kpiWeightTd_value
=
id_kpiWeightTd_value
.
toFixed
(
2
);
var
kpiId_Name
=
getkpiid_NameOfNamedimKpiCheck
();
for
(
var
i
=
0
;
i
<
kpiId_Name
.
length
;
i
++
){
var
id_name
=
kpiId_Name
[
i
];
var
addRow
=
$
(
"<tr class='"
+
id_name
.
split
(
"_"
)[
0
]
+
"' id='dimKpiCheck_"
+
id_name
.
split
(
"_"
)[
0
]
+
"'><td>"
+
id_name
.
split
(
"_"
)[
1
]
+
"</td><td>"
+
id_kpiWeightTd_value
+
"</td><td><a href='javascript:;' onclick='deleteRow(this)'>删除</a> <a href='javascript:;' onclick='updateRow(this)'>修改</a></td></tr>"
);
//alert("id_name "+id_name);
var
addRow
=
$
(
"<tr class='"
+
id_name
.
split
(
"_"
)[
0
]
+
"' id='dimKpiCheck_"
+
id_name
.
split
(
"_"
)[
0
]
+
"'><td>"
+
id_name
.
split
(
"_"
)[
1
].
split
(
" "
)[
0
]
+
"</td><td>"
+
id_kpiWeightTd_value
+
"</td><td><a href='javascript:;' onclick='deleteRow(this)'>删除</a> <a href='javascript:;' onclick='updateRow(this)'>修改</a></td></tr>"
);
$
(
"#addTr"
).
append
(
addRow
);
$
(
"input[name='dimKpiCheck']"
).
each
(
function
(
e
)
{
if
(
$
(
this
).
attr
(
"checked"
))
{
$
(
this
).
next
().
remove
();
$
(
this
).
remove
();
}
});
}
sumkpiWeightTdVal
=
curm01
+
Number
(
sumkpiWeightTdVal
);
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
)));
$
(
"#kpiWeightTd"
).
val
(
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
===
0
?
''
:
parseFloat
((
1
-
sumkpiWeightTdVal
).
toFixed
(
2
))
);
});
...
...
src/main/webapp/static/js/associatediagosisconfiguration.js
View file @
4a7df7e1
...
...
@@ -244,7 +244,7 @@ table_pagging.prototype={
if
(
k
==
4
){
var
items
=
this
.
getData
(
this
.
objectlist
[
i
],
this
.
header
[
k
][
1
]);
// alert(items);
tdContext
=
"<a name='"
+
this
.
getData
(
this
.
objectlist
[
i
],
this
.
header
[
0
][
1
])
+
"' onclick='aClick(this)'>详情</a>"
;
tdContext
=
"<a name='"
+
this
.
getData
(
this
.
objectlist
[
i
],
this
.
header
[
0
][
1
])
+
"' onclick='aClick(this)'>详
-
情</a>"
;
}
}
else
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment