<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('新增涉密网络登记')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-netinfo-add">
            <input name="netId" class="form-control" th:value="${netId}" type="hidden">
            <div class="row">
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">设备种类：</label>
                        <div class="col-sm-8">
                            <select name="netName" required class="form-control" th:with="type=${@dict.getType('sys_net_type')}">
                                <option value="">---请选择---</option>
                                <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                            </select>
                        </div>
                    </div>
                </div>
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label">IP地址：</label>
                        <div class="col-sm-8">
                            <input name="netIp" class="form-control" type="text">
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">设备型号：</label>
                        <div class="col-sm-8">
                            <input name="netNo" required class="form-control" type="text">
                        </div>
                    </div>
                </div>
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">序列号：</label>
                        <div class="col-sm-8">
                            <input name="netSn" required class="form-control" type="text">
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label">登记人员：</label>
                        <div class="col-sm-8">
                            <input name="netname" class="form-control" readonly th:value="${sysuser.userName}" type="text">
                        </div>
                    </div>
                </div>
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">责任人：</label>
                        <div class="col-sm-8">
                            <input name="netManager" required class="form-control" type="text">
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">单位名称：</label>
                        <div class="col-sm-8">
                            <input name="depart" required class="form-control" type="text">
                        </div>
                    </div>
                </div>
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">密级：</label>
                        <div class="col-sm-8">
                            <select name="netMiji"  required class="form-control m-b" th:with="type=${@dict.getType('sys_file_miji')}">
                                <option value="">---请选择---</option>
                                <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                            </select>
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">网络设备品牌：</label>
                        <div class="col-sm-8">
                            <input name="netBrand" required class="form-control" type="text">
                        </div>
                    </div>
                </div>
                <div class="col-sm-6">
                    <div class="form-group">
                        <label class="col-sm-4 control-label is-required">涉密网络名称：</label>
                        <div class="col-sm-8">
                            <input name="netsmname" required class="form-control" type="text">
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-12">
                    <div class="form-group">
                        <label class="col-sm-2 control-label is-required">是否属于要害部门部位：</label>
                        <div class="col-sm-10">
                            <div class="radio-box" th:each="dict : ${@dict.getType('sys_yes_no')}">
                                <input type="radio" required th:id="${'isCurcial_' + dict.dictCode}" name="isCurcial" th:value="${dict.dictValue}" th:checked="${dict.default}">
                                <label th:for="${'isCurcial_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-12">
                    <div class="form-group">
                        <label class="col-sm-2 control-label">备注：</label>
                        <div class="col-sm-10">
                            <textarea name="remark" class="form-control" type="text"></textarea>
                        </div>
                    </div>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "system/network/netinfo"
        $("#form-netinfo-add").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/add", $('#form-netinfo-add').serialize());
            }
        }
    </script>
</body>
</html>
