<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('添加客户')" />
    <th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form class="form-horizontal m" id="form-customer-edit" th:object="${tCusCustomer}">
        <input name="customerId" th:field="*{customerId}" type="hidden">
        <div class="form-group">
            <label class="col-sm-3 control-label">客户编号：</label>
            <div class="col-sm-8">
                <input name="customerId" th:field="*{customerId}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">客户名称：</label>
            <div class="col-sm-8">
                <input name="customerName" th:field="*{customerName}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">客户简称：</label>
            <div class="col-sm-8">
                <input name="customerShortName" th:field="*{customerShortName}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">拼音简称：</label>
            <div class="col-sm-8">
                <input name="pyName" th:field="*{pyName}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">客户分类编号：</label>
            <div class="col-sm-8">
                <input name="cusTypeId" th:field="*{cusTypeId}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">联系人：</label>
            <div class="col-sm-8">
                <input name="linkman" th:field="*{linkman}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">手机号：</label>
            <div class="col-sm-8">
                <input name="telephone" th:field="*{telephone}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">联系电话：</label>
            <div class="col-sm-8">
                <input name="phone" th:field="*{phone}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">联系传真：</label>
            <div class="col-sm-8">
                <input name="fax" th:field="*{fax}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">联系地址：</label>
            <div class="col-sm-8">
                <input name="email" th:field="*{email}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">省：</label>
            <div class="col-sm-8">
                <input name="province" th:field="*{province}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">市：</label>
            <div class="col-sm-8">
                <input name="city" th:field="*{city}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">邮编：</label>
            <div class="col-sm-8">
                <input name="postcode" th:field="*{postcode}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">地址：</label>
            <div class="col-sm-8">
                <input name="address" th:field="*{address}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">备注：</label>
            <div class="col-sm-8">
                <textarea name="remark" class="form-control">[[*{remark}]]</textarea>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">版本号：</label>
            <div class="col-sm-8">
                <input name="version" th:field="*{version}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">操作人：</label>
            <div class="col-sm-8">
                <input name="operatorid" th:field="*{operatorid}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">操作日期：</label>
            <div class="col-sm-8">
                <div class="input-group date">
                    <input name="operatedate" th:value="${#dates.format(tCusCustomer.operatedate, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
                    <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                </div>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">省编号：</label>
            <div class="col-sm-8">
                <input name="provinceId" th:field="*{provinceId}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">市编号：</label>
            <div class="col-sm-8">
                <input name="cityId" th:field="*{cityId}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">县/区编号：</label>
            <div class="col-sm-8">
                <input name="townId" th:field="*{townId}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">GUID：</label>
            <div class="col-sm-8">
                <input name="guid" th:field="*{guid}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">端口：</label>
            <div class="col-sm-8">
                <input name="port" th:field="*{port}" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">状态：</label>
            <div class="col-sm-8">
                <input name="sts" th:field="*{sts}" class="form-control" type="text">
            </div>
        </div>
    </form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
    var prefix = ctx + "business/customer";
    $("#form-customer-edit").validate({
        focusCleanup: true
    });

    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/edit", $('#form-customer-edit').serialize());
        }
    }

    $("input[name='operatedate']").datetimepicker({
        format: "yyyy-mm-dd",
        minView: "month",
        autoclose: true
    });
</script>
</body>
</html>