<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8" />
    <title>详细</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <meta name="decorator" content="base" />
    <link rel="stylesheet" type="text/css" href="${ctxPlugin}/static/css/font-awesome.min.css" />
    <link rel="stylesheet" type="text/css" href="${ctxPlugin}/static/css/commentstyle.css" />
    <link rel="stylesheet" type="text/css" href="${ctxPlugin}/static/css/mobile.css" />
    <script type="text/javascript" src="${ctxPlugin}/static/js/jquery-3.3.1.min.js"></script>
    <style>
        .suggxiala{font-size:26px; margin-top:10px; display:none; line-height:45px;}
        html{
            background: #fff;}
    </style>
</head>
<body>
<div style="height:20px;"></div>
<div class="gaoconent"> 
    <span class="gaojtit">告警详细</span>
    <table class="gaotable">
        <tr>
            <td class="name">故障名称</td>
            <td>${map.fault_name}</td>
        </tr>
        <tr>
            <td class="name">设备</td>
            <td>${map.device_name}</td>
        </tr>
        <tr>
            <td class="name">设备型号</td>
            <td>${map.device_model}</td>
        </tr>
        <tr>
            <td class="name">设备类型</td>
            <td>${map.device_type_name}</td>
        </tr>
        <tr>
            <td class="name">告警时间</td>
            <td>${map.fault_time}</td>
        </tr>
        <tr>
            <td class="name">告警描述</td>
            <td>${map.fault_desc}</td>
        </tr>
    </table>
    <div>
        <span class="suggest">修复建议</span>
        <ul class="suggul">
            <li>
                <a href="#">
                    <i>+</i>
                    <span>告警原因条件</span>
                </a>
                <div class="suggxiala">
                    &emsp;&emsp;${map.reason}
                </div>
            </li>
            <li>
                <a href="#">
                    <i>+</i>
                    <span>是否可自动恢复</span>
                </a>
                <div class="suggxiala">
                    &emsp;&emsp;${map.restore}
                </div>
            </li>
            <li>
                <a href="#">
                    <i>+</i>
                    <span>修复建议</span>
                </a>
                <div class="suggxiala">
                    &emsp;&emsp;${map.suggest}
                </div>
            </li>
        </ul>
    </div>
</div>
<script src="${ctxPlugin}/lib/layuiAdmin/dist/layuiadmin/layui/layui.js"></script>
<script type="text/javascript">
    $(".suggul li a").click(function(){
        $(this).next().slideDown().parent().siblings().find("div").slideUp();
    })

    window.addEventListener('pagehide', function(e) {
        var $body = $(document.body);
        $body.children().remove();
        // 要等到回调函数完成，用户按返回才执行script标签的代码
        setTimeout(function() {
            $body.append("<script type='text/javascript'>window.location.reload();<\/script>");
        });
    });

    var phoneWidth = parseInt(window.screen.width);
    var phoneScale = phoneWidth / 750;
    var ua = navigator.userAgent;
    if(/Android (\d+\.\d+)/.test(ua)) {
        var version = parseFloat(RegExp.$1);
        if(version > 2.3) {
            document.write('<meta name="viewport" content="width=750, minimum-scale =' + phoneScale + ', maximum-scale =' + phoneScale + ', target-densitydpi=device-dpi">');
        } else {
            document.write('<meta name="viewport" content="width=750, target-densitydpi=device-dpi">');
        }
    } else {
        document.write('<meta name="viewport" content="width=750, user-scalable=no, target-densitydpi=device-dpi">');
    }


</script>
</body>
</html>