<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include :: header('证照打印')" />
    <th:block th:include="include :: datetimepicker-css" />
    <style>
        /*.control-label{*/
        /*    margin-bottom: 15px;*/
        /*}*/
    </style>
</head>
<body class="white-bg">

<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <div class="col-md-12">
        <div class="form-group">
            <label class="col-sm-3 control-label">经营者：</label>
            <div class="col-sm-9">
                <input type="text" name="master" class="form-control" placeholder="请输入文本">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">名 称：</label>
            <div class="col-sm-9">
                <input type="text" name="name" class="form-control" placeholder="请输入文本">
            </div>
        </div>

        <div class="form-group">
            <label class="col-sm-3 control-label">统一社会信用代码：</label>
            <div class="col-sm-9">
                <input type="text" name="code" class="form-control" placeholder="请输入文本">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">开业日期：</label>
            <div class="col-sm-9">
                <input type="text" name="date" class="form-control" placeholder="请输入文本">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">组成形式：</label>
            <div class="col-sm-9">
                <input type="text" name="formation" class="form-control" placeholder="请输入文本">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">经营场所：</label>
            <div class="col-sm-9">
                <input type="text" name="address" class="form-control" placeholder="请输入文本">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">经营范围：</label>
            <div class="col-sm-9">
                <input type="text" name="range" class="form-control" placeholder="请输入文本">
            </div>
        </div>
    </div>

</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
    $.modal.loading("正在加载数据，请稍后...");
    var prefix = ctx + "system/cprint";

    var url = [[${url}]];
    // prefix + "/requestInfo"
    $.ajax(
        {
            url:prefix+"/requestInfo",
            data: {toUrl:url},
            type:"post",
            dataType: "json",
            success:function (msg) {
                var data = JSON.parse(msg.msg);
                console.log(data);
                var date = new Date(data.zhucetime);
                var year = date.getFullYear();//年
                var month = (date.getMonth()+1);//月
                var day = date.getDate();//日
                $("[name=master]").val(data.jingyingren);
                $("[name=code]").val(data.xinyongcode);
                $("[name=name]").val(data.zwzh);
                $("[name=date]").val(year+"-"+month+"-"+day);
                $("[name=formation]").val(data.zuchengxingshi);
                $("[name=address]").val(data.jingyingchangsuo);
                $("[name=range]").val(data.jingyingfanwei);
                $.modal.closeLoading();
            },
            error: function (msg) {
                $.modal.closeLoading();
            }
        }
    )






</script>



</body>
</html>
