cy
2022-06-21 129904537f66509f97b285e7eb4f42b3dc349dd0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<!doctype html>
<html class="no-js">
<head>
<meta charset="utf-8">
[#include "/business/pages/include/static.html" /]
<title>巡检配置</title>
 
<script type="text/javascript">
        //点击事件
        function onDialogBtnClick(btnID, dialogID, config){
            if(btnID == "btnSure"){
                if($("#ciList").find("tr:eq(1)").find("td:eq(0)").attr("colspan")!=5){ 
                    var ciJsonList = [];
                    $("#ciList").find("tr").each(function(index){
                        if(index>0){
                            var trval = $(this).find("input[name=itemId]");
                            if(!$.util.isEmpty(trval)){
                                var itemId = $(this).val();
                                var result = $(this).parent().parent().find("input[type=radio]:checked").val();
                                var note = $(this).parent().parent().find("input[name=note]").val();
                                var objitem = {};
                                objitem["itemId"]=itemId;
                                objitem["result"]=result;
                                objitem["note"]=note;
                                ciJsonList.push(objitem);
                            }
                        }
                        
                    });
                    window.parent.addWarnCi(ciJsonList);
                     window.top.hideDialog(dialogID);
                }
            }
            
        }
</script>
 
</head>
 
<body class="fullscreen">
<div class="table_basic">
    <table class="display_form" id="ciList" style="width:95%">
        <tr class="title">
            <td style="width:5%">序号</td>
            <td style="width:15%">配置名称(搜索码)</td>
            <td style="width:25%">巡检项</td>
            <td style="width:20%">巡检结果</td>
            <td width="20%">备注</td>
        </tr>
        [#if ciList??&&ciList?size>0]
            [#list ciList as ci]
            <tr>
                <td [#if ci.rownum??] rowspan="${ci.rownum}" [/#if]>${ci_index+1}<input name="ciId" v="${ci.CINAME}" c="${ci.SEARCHCODE}" type="hidden" value="${ci.ID}"/></td>
                <td [#if ci.rownum??] rowspan="${ci.rownum}" [/#if]><a class="blue_txt lb_button" target="_blank" href="${base}/business/pages/cfg/cfgDetail.html?id=${ci.ID}">${ci.CINAME}(${ci.SEARCHCODE})</a></td>
                [#if ci.xjxlist?? && ci.xjxlist?size > 0]
                [#list ci.xjxlist as xjx]
                [#if xjx_index != 0]
                <tr>
                [/#if]
                <td>${xjx.ITEM_NAME}<input class="${ci.ID}" v="${xjx.ITEM_NAME}" name="itemId" type="hidden" value="${xjx.ID}"/></td>
                <td>
                    <input type="radio" name="result${ci_index}${xjx_index}" [#if xjx.RESULT==1]checked[/#if] value="1"/>正常&nbsp;&nbsp;
                    <input type="radio" name="result${ci_index}${xjx_index}" [#if xjx.RESULT==2]checked[/#if] value="2"/>告警&nbsp;&nbsp;
                    <input type="radio" name="result${ci_index}${xjx_index}" [#if xjx.RESULT==3]checked[/#if] value="3"/>异常&nbsp;&nbsp;
                </td>
                <td>
                    <input maxlength="200" style="width:95%;" name="note" type="text"/>
                </td>
                [#if xjx_index != 0]
                </tr>
                [/#if]
                [/#list]
                [/#if]
            [#if ci_index == 0]
                </tr>
            [/#if]
            [/#list]
        [#else]
            <tr>
                <td colspan="5" align="center">无需要巡检配置</td>
            </tr>
        [/#if]
    </table>
</div>
</body>
</html>