<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:sptg="http://www.thymeleaf.org">
    <head>
        <script th:replace="common/head"></script>
    </head>
    <body>
        <input type="hidden" id="org_id" th:value="${onLineUser.orgId}" />
        <div class="layui-fluid">
            <!-- 下拉树 -->
            <div th:replace="common/org-tree"></div>
            <div class="x-body per-table">
                <div class="layui-card">
                    <div class="layui-form layui-card-header layuiadmin-card-header-auto" style="padding:0;">
                        <div class="layui-form-item border-b">
                            <div class="layui-inline">
                                <label class="layui-form-label">楼盘名称</label>
                                <div class="layui-input-block">
                                    <input type="text" name="residentialName" placeholder="请输入" autocomplete="off" class="layui-input">
                                </div>
                            </div>
                            <div class="layui-inline">
                                <label class="layui-form-label">设备编号</label>
                                <div class="layui-input-block">
                                    <input type="text" name="serialNumber" placeholder="请输入" autocomplete="off" class="layui-input">
                                </div>
                            </div>
                            <div class="layui-inline">
                                <label class="layui-form-label">检测人</label>
                                <div class="layui-input-block">
                                    <input type="text" name="createName" placeholder="请输入" autocomplete="off" class="layui-input">
                                </div>
                            </div>
                            <div class="layui-inline">
                                <div class="layui-form-item">
                                    <label class="layui-form-label">
                                        检测时间
                                    </label>
                                    <div class="layui-input-block">
                                        <input type="text" id="create-date-id" name="createDate" placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                            </div>
                            <div class="layui-inline" style="margin-left: 38px;">
                                <button class="layui-btn layuiadmin-btn-useradmin"  lay-submit lay-filter="query">查询</button>
                                <button class="layui-btn  layui-btn-primary"  lay-submit lay-filter="reset">重置</button>
                            </div>
                        </div>

                        <div class="layui-card-body" style="padding:0;">
                            <!--表格头部按钮-->
                            <div style="padding-bottom: 10px;">
                                <button class="layui-btn layuiadmin-btn-useradmin" lay-submit lay-filter="export" sptg:security="implement:test:export">导出</button>
                            </div>
                            <table id="table_id" lay-filter="table_event"></table>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <script type="text/html" id="table-operation">
            <a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="detail">详情</a>
            {{#  if(d.checkState == 0){ }}
            <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="check" sptg:security="implement:test:audit">审核</a>
            {{# } }}
        </script>
        <!-- 审核状态 -->
        <script type="text/html" id="checkState">
            {{#  if(d.checkState == 0){ }}
            <span style="color: red">待审核</span>
            {{#  }else if(d.checkState == 1){ }}
            <span style="color: green">审核通过</span>
            {{# }else if(d.checkState == 2) { }}
            <span style="color: blue">审核不通过</span>
            {{# } }}
        </script>
        <!-- 设备类型 -->
        <script type="text/html" id="deviceType">
            {{#  if(d.deviceType == 0){ }}
            <span>立柱机</span>
            {{#  }else if(d.deviceType == 1){ }}
            <span>壁挂机</span>
            {{#  }else if(d.deviceType == 2){ }}
            <span>雨罩壁挂机</span>
            {{# } }}
        </script>

        <!-- javascript -->
        <script th:src="@{'/layui/layui.js'}"></script>
        <script>
            layui.config({
                base: '/' //静态资源所在路径
            });
        </script>
        <script th:src="@{'/js/implement/device-test-manage.js'}"></script>
    </body>
</html>