<!doctype html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>设立</title>
    <th:block th:include="include :: header('修改待审核')"/>
    <link rel="stylesheet" type="text/css" href="/YtjCommon/css/bootstrap.min.css">
    <link rel="stylesheet" type="text/css" href="/YtjCommon/css/f_css.css">
    <link rel="stylesheet" type="text/css" href="/YtjCommon/css/style.css">
    <link href="/YtjCommon/css/chuan.css" rel="stylesheet"/><!--材料上传样式-->
    <link href="/YtjCommon/css/big-window.css" rel="stylesheet"/>
    <link href="/YtjCommon/css/alert.css" rel="stylesheet"/>
    <link href="/YtjCommon/css/qh.css" rel="stylesheet"/>
    <link href="/YtjCommon/css/checkbox_radio_font.css" rel="stylesheet"/><!--单选按钮、多选按钮-->
    <script src="/YtjCommon/js/jquery-1.8.2.min.js"></script>
    <script src="/YtjCommon/js/jQuery.md5.js"></script>
    <script src="/YtjCommon/js/jquery.cookie.js"></script>
    <script src="/YtjCommon/js/main.js"></script>
    <script src="/YtjCommon/js/public.js"></script>
    <script src="/YtjCommon/js/position.data.min.js"></script>
    <script src="/YtjCommon/js/jquery.position.select.js" type="text/javascript"></script>
    <script src="/YtjCommon/js/layer.js"></script>
    <script src="/YtjCommon/js/Face.js"></script><!--人脸识别函数-->
    <script src="/YtjCommon/js/Hand.js"></script><!--手写签名函数-->
    <script src="/YtjCommon/js/Camera.js"></script><!--拍照-->
    <script src="/YtjCommon/js/Sound_1.js"></script><!--语音-->
    <script src="/YtjCommon/js/rzdb.js"></script><!--人证对比div-->
    <script src="/YtjCommon/js/sccl.js"></script><!--上传材料div-->
    <script src="/YtjCommon/js/sound.js"></script>
    <script src="/YtjCommon/js/numkeyboard.js"></script><!--数字键盘-->
    <script src="/YtjCommon/js/alert.min.js"></script><!--弹出提示-->
    <style>
        .sbxxtl .input_right5 {
            width: 1050px;
        }

        .weui_mask {
            position: fixed;
            z-index: 1;
            width: 100%;
            height: 780px;
            top: 240px;
            left: 0;
            background: rgba(0, 0, 0, .6);
        }

        .weui_toast {
            position: fixed;
            z-index: 3;
            width: 15em;
            min-height: 150px;
            top: 556px;
            left: 50%;
            margin-left: -7em;
            background: rgba(40, 40, 40, 0.75);
            text-align: center;
            border-radius: 5px;
            color: #FFFFFF;
            padding-top: 30px;
        }

        .weui_toast_content {
            margin: 15px 0 15px;
        }

        input:-ms-input-placeholder {
            color: #bdbdbd;
        }

        .table-rzdb > tbody > tr > td {
            padding: 6px;
            line-height: 1;
            vertical-align: middle;
        }
    </style>
</head>
<script>

    var prefix = "/Ytj/GsYw/";
    var city1 = "[[${city}]]";
    var scity = "[[${scity}]]";
    var socre = [[${rzdbsocre}]]
    $(function () {
        qhyw("0");
        GetHangYe();//获取行业信息
        ////------------读取身份证信息---------------//
        function readInfo() {
            m_info = read_info();
            if (m_info) {
                var idInfo = JSON.parse(m_info);//读取身份证
                $('#jyzxm').val(idInfo.name);//姓名
                $("#jyzxb").val(idInfo.sex);//性别
                $("#jyzmz").val(idInfo.nation);//民族
                $("#jyztx").val(idInfo.idImg);
                $("#jyzzz").val(idInfo.address);
                $("#sfzjg").val(idInfo.grantdept);
                $('#jyzsfz').val(idInfo.idCardNo);
                $("#rzdb_SFZ").attr('src', "data:image/jpeg;base64," + idInfo.idImg);//认证对比-身份证
            }
        }

        readInfo();
        GetCardUser();
        GetXzqh();//获取行政区划



        //
        var info = Get_PCinfo();//获取设备信息
        info = JSON.parse(info);
        $("#xxly").val(info.M_Tag);
        //alert(info.M_Tag);

        //------------------------------//
        //注册资金数字键盘行业
        $("#zczb").numkeyboard({
            keyboardRadix: 600,//键盘大小基数
            mainbackground: '#C8BFE7', //主背景色
            menubackground: '#4A81B0', //头背景色
            exitbackground: '#4376A0', //关闭按钮背景色
            buttonbackground: '#ff730e', //键盘背景色
            clickeve: true//是否绑定元素click事件
        });
        //从业人数数字键盘
        $("#cyrs").numkeyboard({
            keyboardRadix: 600,//键盘大小基数
            mainbackground: '#C8BFE7', //主背景色
            menubackground: '#4A81B0', //头背景色
            exitbackground: '#4376A0', //关闭按钮背景色
            buttonbackground: '#ff730e', //键盘背景色
            clickeve: true//是否绑定元素click事件
        });
        //sjh数数字键盘
        $("#jyzdh").numkeyboard({
            keyboardRadix: 600,//键盘大小基数
            mainbackground: '#C8BFE7', //主背景色
            menubackground: '#4A81B0', //头背景色
            exitbackground: '#4376A0', //关闭按钮背景色
            buttonbackground: '#ff730e', //键盘背景色
            clickeve: true//是否绑定元素click事件
        });

    });

    function GetCardUser() {
        var url = prefix + "GetUserCard";
        var data = {"hm": $('#jyzsfz').val()};
        //var data={"hm":"130723198301053519"};
        $.ajax({
            url: url,
            type: "get",
            dataType: 'json',
            data: data,
            cache: false,
            success: function (data) {

                if (data != "" && data != null) {
                    if (data.djry.length > 0) {
                        $("#jyzdh").val(data.djry[0].sjhm);
                    }
                    if (data.tjsj.length > 0 && data.tjsj[0].Flg == 2) {
                        $("#xgflg").val(data.tjsj[0].Flg);
                        $("#zwzh1").val(data.tjsj[0].Zwzh1);
                        $("#zwzh2").val(data.tjsj[0].Zwzh2);
                        $("#zwzh3").val(data.tjsj[0].Zwzh3);
                        $("#zwzh4").val(data.tjsj[0].Zwzh4);
                        for (var i = 1; i < 5; i++) {
                            if ($("#zwzh" + i + "").val() == data.tjsj[0].Zwzh) {
                                $("#xyzh").val("zwzh" + i + "");
                                $("#xzzh" + i + "").addClass("btn-xuan");
                            } else {
                                $("#xzzh" + i + "").removeClass("btn-xuan");
                            }
                        }
                        $("#HY1").find("option:contains('" + data.tjsj[0].HangYe + "')").attr("selected", true);
                        $("#result").val(data.tjsj[0].HangYe1 + "," + data.tjsj[0].HangYe3+","+data.tjsj[0].HangYe2);
                        $("#hymcdiv").show();
                        $("#hymc").val(data.tjsj[0].MingChengHangYe);
                        $("#zzxxdiv").show();
                        $("#zzxx").val(data.tjsj[0].ZuZhiXingShi);
                        $("#hmc").val(city1 + data.tjsj[0].Zwzh + data.tjsj[0].MingChengHangYe + data.tjsj[0].ZuZhiXingShi);
                        $("#ncmc").html(city1 + data.tjsj[0].Zwzh + data.tjsj[0].MingChengHangYe + data.tjsj[0].ZuZhiXingShi);
                        if (data.tjsj[0].Zwzh == "***") {
                            qhyw("1");
                        } else {
                            qhyw("0");
                        }
                        $("#nsqmc").val(city1 + data.tjsj[0].Zwzh + data.tjsj[0].MingChengHangYe + data.tjsj[0].ZuZhiXingShi);
                        $("#zczb").val(data.tjsj[0].ZiJinShuE);
                        $("#jyfw").html(data.tjsj[0].JingYingFanWei.replace("（依法须经批准的项目，经相关部门批准后方可开展经营活动）", ""));
                        $("#jycsz").find("option:contains('" + data.tjsj[0].NsdXj + "')").attr("selected", true);
                        $("#jycsc").append("<option value=\"" + data.tjsj[0].NsdXc + "\">" + data.tjsj[0].NsdXc + "</option>");
                        $("#jycsc").find("option:contains('" + data.tjsj[0].NsdXc + "')").attr("selected", true);
                        var cs = data.tjsj[0].JingYingChangSuo.replace(scity, "");
                        cs = cs.replace(city1, "");
                        cs = cs.replace(data.tjsj[0].NsdXj, "");
                        cs = cs.replace(data.tjsj[0].NsdXc, "");
                        $("#xxdz").val(cs);
                        $("#cyrs").val(data.tjsj[0].CongYeRenShu);

                    }
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '数据加载失败',
                    'closeTime': 4000,
                })
            }
        });
    }

    function GetXzqh() {
        var url = prefix + "QhList";
        $.ajax({
            url: url,
            type: "get",
            success: function (data) {
                if (data != "" && data != null) {
                    $.each(data, function (i, item) {
                        $("#jycsz").append("<option value=\"" + item.DataDictionaryDetailId + "\">" + item.FullName + "</option>");
                    })
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '数据加载失败',
                    'closeTime': 4000,
                })
            }
        });
    }

    function GetXc(obj) {
        var url = prefix + "GetQu";
        var data = {"pid": obj};
        $.ajax({
            url: url,
            type: "get",
            data: data,
            success: function (data) {
                if (data != "" && data != null) {
                    $("#jycsc").empty();
                    $("#jycsc").append("<option value=\"\">请选择</option>");
                    $.each(data, function (i, item) {
                        $("#jycsc").append("<option value=\"" + item.DataDictionaryDetailId + "\">" + item.FullName + "</option>");
                    })
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '数据加载失败',
                    'closeTime': 4000,
                })
            }
        });
    }

    function GetHangYe() {
        var url = prefix + "GetHy";
        $.ajax({
            url: url,
            type: "get",
            success: function (data) {
                if (data != "" && data != null) {
                    $.each(data, function (i, item) {
                        $("#HY1").append("<option value=\"" + item.DataDictionaryDetailId + "\">" + item.FullName + "</option>");
                    })
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '数据加载失败',
                    'closeTime': 4000,
                })
            }
        });
    }

    function GetHangYe2(obj) {
        $("#result").val("");
        $("#ccbj").val("0");
        $("#yxmc").html("");
        var url = prefix + "GetChildHy";
        var data = {"pid": obj};
        $.ajax({
            url: url,
            type: "get",
            dataType: 'text',
            data: data,
            success: function (data) {
                $("#positionDiv").empty();
                if (data != "" && data != null) {
                    positiondata = data;
                    if ($("#qhzh").val() == "0") {
                        $("#positionDiv").css("margin", "-280px 0 0 -490px");
                    } else {
                        $("#positionDiv").css("margin", "-280px 0 0 -490px");
                    }
                    $("#result").positionSelect({
                        containerId: "positionDiv",
                        className: "big-window",
                        nameId: "result"
                    });
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '数据加载失败',
                    'closeTime': 4000,
                })
            }
        });
    }

    function GetHangYe3() {
        if ($("#HY1").val() != "") {
            GetHangYe2($("#HY1").val());
        } else {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请先选择行业分类',
                'closeTime': 4000,
            })
        }
    }

    function GetXx(obj) {
        if ($("#result").val() != "") {
            var url = prefix + "GetZzxx";
            var data = {"name": encodeURI($("#result").val())};
            $.ajax({
                url: url,
                type: "get",
                dataType: 'json',
                data: data,
                success: function (data) {
                    if (data != "" && data != null) {
                        $("#zzxxdiv").show();
                        $("#zzxx").val("");
                        var str = "<div id=\"blk3\" class=\"blk\">";
                        str += "<div class=\"head\"><div class=\"head-right\"></div></div>";
                        str += "<div class=\"main\">";
                        str += "<ul id=\"zzxxlist\">";
                        $.each(data, function (i, item) {
                            str += "<li><a href=\"javascript:GetName1('" + item.fullName + "')\">" + item.fullName + "</a></li>";
                        });
                        str += "</ul>";
                        str += "</div>";
                        str += "<div class=\"foot\"><div class=\"foot-right\"></div></div>";
                        str += "</div>";
                        layer.open({
                            type: 1,
                            title: "请选择组织形式",
                            area: ['800px', '400px'],
                            shade: 0,
                            shadeClose: true, //点击遮罩关闭
                            closeBtn: 0,
                            btn: ['关闭'], //只是为了演示
                            yes: function () {
                                layer.close(layer.index);
                            },
                            content: str
                        });
                    }
                },
                error: function (XMLHttpRequest, textStatus, errorThrown) {
                    jqueryAlert({
                        'icon': '/YtjCommon/img/warning.png',
                        'content': '数据加载失败',
                        'closeTime': 4000,
                    })
                }
            });
        } else {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择行业分类子项',
                'closeTime': 4000,
            })
        }
    }

    function MName() //默认字号输入
    {
        var na = $("#zwzh1").val();
        var hm = $("#hymc").val(); //行业名称
        if (hm == "请选择") {
            hm = "";
        }
        var zz = $("#zzxx").val();
        if (zz == "请选择") {
            zz = "";
        }
        $("#hmc").val(city1 + na + hm + zz);
        $("#ncmc").html(city1 + na + hm + zz);
    }

    function AutoName() {
        var na = $("#" + $("#xyzh").val() + "").val();
        var hm = $("#hymc").val(); //行业名称
        if (hm == "请选择") {
            hm = "";
        }
        var zz = $("#zzxx").val();
        if (zz == "请选择") {
            zz = "";
        }
        $("#hmc").val(city1 + na + hm + zz);
        $("#ncmc").html(city1 + na + hm + zz);
    }

    function ChooseName(obj, n) //选择名称
    {
        var na = $("#" + obj + "").val();
        var hm = $("#hymc").val(); //行业名称
        if (hm == "请选择") {
            hm = "";
        }
        var zz = $("#zzxx").val();
        if (zz == "请选择") {
            zz = "";
        }
        var myReg = /^[\u4e00-\u9fa5]+$/;
        if ($("#" + obj + "").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '您所选的中文字号为空',
                'closeTime': 4000,
            });
            return false;
        } else if (!myReg.test($("#" + obj + "").val())) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号只能是汉字',
                'closeTime': 4000,
            });
            return false;
        } else if ($("#" + obj + "").val().length < 2 || $("#" + obj + "").val().length > 5) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号长度为2-5个汉字',
                'closeTime': 4000,
            });
            return false;
        } else {
            $("#xyzh").val(obj);
            $("#hmc").val(city1 + na + hm + zz);
            $("#ncmc").html(city1 + na + hm + zz);
        }
        //选择后改变选择样式
        for (var i = 1; i < 5; i++) {
            if (i == n) {
                $("#xzzh" + i + "").addClass("btn-xuan");
            } else {
                $("#xzzh" + i + "").removeClass("btn-xuan");
            }
        }
        //
        $("#ccbj").val("0");
        $("#yxmc").html("");
    }

    //检查字号是否有相同的
    function IsTongMing() {
        var n = 0;
        if ($("#zwzh1").val() != "" && $("#zwzh2").val() != "") {
            if ($("#zwzh1").val() == $("#zwzh2").val()) {
                n++;
            }
            if ($("#zwzh1").val() == $("#zwzh3").val()) {
                n++;
            }
            if ($("#zwzh2").val() == $("#zwzh3").val()) {
                n++;
            }
        }
        if (n > 0) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号不能重复',
                'closeTime': 4000,
            });
            return false;
        }
        return true;
    }

    function InitName() {
        //选择后改变选择样式
        var na = $("#" + $("#xyzh").val() + "").val();
        var hm = $("#hymc").val(); //行业名称
        var zz = $("#zzxx").val();
        if ($("#zzxx").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择组织形式',
                'closeTime': 4000,
            })
        } else {
            $("#hmc").val(city1 + na + hm + zz);
            $("#ncmc").html(city1 + na + hm + zz);
        }
        $("#ccbj").val("0");
        $("#yxmc").html("");
    }

    function CheckStep() {
        var myReg = /^[\u4e00-\u9fa5]+$/;
        if ($("#hmc").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请先填写中文字号（默认），并选择行业分类',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#zwzh1").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '默认中文字号不能为空',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#zwzh1").val().length < 2 || $("#zwzh1").val().length > 5) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '默认字号长度为2-5个汉字',
                'closeTime': 4000,
            });
            return false;
        }
        /*     if ($("#zwzh2").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号（备选1）不能为空',
                'closeTime': 4000,
            })
            return false;
        }
   if ($("#zwzh2").val().length < 2 || $("#zwzh2").val().length > 5) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号（备选1）长度为2-5个汉字',
                'closeTime': 4000,
            })
            return false;
        }
        if ($("#zwzh3").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号（备选2）不能为空',
                'closeTime': 4000,
            })
            return false;
        }
        if ($("#zwzh3").val().length < 2 || $("#zwzh3").val().length > 5) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号（备选2）长度为2-5个汉字',
                'closeTime': 4000,
            })
            return false;
        }*/
        if (!myReg.test($("#zwzh1").val())) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '中文字号（默认）只能是汉字',
                'closeTime': 4000,
            });
            return false;
        }
        /*     if (!myReg.test($("#zwzh2").val())) {
                 jqueryAlert({
                     'icon': '/YtjCommon/img/warning.png',
                     'content': '中文字号（备选1）只能是汉字',
                     'closeTime': 4000,
                 })
                 return false;
             }
             if (!myReg.test($("#zwzh3").val())) {
                 jqueryAlert({
                     'icon': '/YtjCommon/img/warning.png',
                     'content': '中文字号（备选2）只能是汉字',
                     'closeTime': 4000,
                 })
                 return false;
             }*/

        if (!IsTongMing()) {
            return false;
        }
        if ($("#HY1").val() == "" || $("#result").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择行业分类',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#hymc").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择名称行业',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#zzxx").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择组织形式',
                'closeTime': 4000,
            });
            return false;
        }
        return true;
    }

    function CheckName() //名称查重
    {
        if (CheckStep()) {
            try {
                //voicezdyStr('名称查重中，请等待');
                $("#toast p.weui_toast_content").html("名称查重中，请等待");
                $("#toast").show();
                var url = prefix + "Check";
                $.post(url,
                    $("#form1").serialize(),
                    function (rtnData) {
                        var ts = rtnData.split(",");
                        if (rtnData[0] == "0") {
                            $("#ccbj").val("1");
                            $("#yxmc").html($("#ncmc").html());
                            $("#nsqmc").val($("#ncmc").html());
                            $("#toast").hide();
                            voicezdyStr('名称查重通过，请点击下一步');
                        } else {
                            $("#toast").hide();
                            $("#yxmc").html("");
                            $("#ccbj").val("0");
                            jqueryAlert({
                                'icon': '/YtjCommon/img/warning.png',
                                'content': '中文字号【' + ts[1] + '】已使用，请选择其他字号',
                                'closeTime': 4000,
                            })
                        }
                    });
            } catch (e) {
                $("#toast").hide();
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '查重失败',
                    'closeTime': 4000,
                });
                return false;
            }
        }
    }

    function ChooseFw() {
        var a = $("#result").val();
        a = a.split(",");
        var url = prefix + "GetFw";
        var data = {"a": encodeURI(a[1])};
        $.ajax({
            url: url,
            type: "get",
            dataType: 'text',
            data: data,
            success: function (data) {
                if (data != "" && data != null) {
                    $("#positionDiv1").empty();
                    if (data != "1") {
                        positiondata = data;
                        $("#jyfw").positionSelect({
                            containerId: "positionDiv1",
                            className: "big-window",
                            nameId: "jyfw",
                            maxCount: 99
                        });
                    } else {
                        jqueryAlert({
                            'icon': '/YtjCommon/img/warning.png',
                            'content': '未配置经营范围，请手动填写',
                            'closeTime': 4000,
                        })
                    }
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '数据加载失败',
                    'closeTime': 4000,
                })
            }
        });
    }

    function go_step(flg) {
        if (flg != "3" && flg != "4") {
            $("#returnSY").removeAttr("onclick");
            $("#returnSY").attr("href", "/Ytj/GsYw");
        }
        if (flg == "1") {
            $("#tpmcxx").addClass("selected");
            $("#mcxzdiv").show();
            $("#mcxxdiv").show();
            $("#tpqyxx").removeClass("selected");
            $("#qyxxdiv").hide();
        }
        if (flg == "2") {
            if ($("#ccbj").val() != "0") {
                $("#tpmcxx").removeClass("selected");
                $("#mcxzdiv").hide();
                $("#mcxxdiv").hide();
                $("#tprzbd").removeClass("selected");
                $("#rzbddiv").hide();
                $("#tpqyxx").addClass("selected");
                $("#qyxxdiv").show();
            } else {
                if ($("#qhzh").val() == "0") {
                    if (CheckStep()) {
                        jqueryAlert({
                            'icon': '/YtjCommon/img/warning.png',
                            'content': '请进行【名称查重】，再进行下一步操作',
                            'closeTime': 4000,
                        })
                    }
                } else {
                    $("#tpmcxx").removeClass("selected");
                    $("#mcxzdiv").hide();
                    $("#mcxxdiv").hide();
                    $("#tprzbd").removeClass("selected");
                    $("#rzbddiv").hide();
                    $("#tpqyxx").addClass("selected");
                    $("#qyxxdiv").show();
                    voicezdyStr('请完善商户信息');
                }
            }
        }
        if (flg == "3") {
            if (CheckForm()) {
                $("#tpqyxx").removeClass("selected");
                $("#qyxxdiv").hide();
                $("#tpclsc").removeClass("selected");
                $("#qrtjdiv").hide();
                $("#tprzbd").addClass("selected");
                $("#rzbddiv").show();
                $("#clscdiv").hide();

                $('#opencamearbutton').hide();
                $("#writeopenButton").hide();
                //人证对比 这一步 加上 关闭摄像头、签字关闭判断
                $("#returnSY").attr("href", "#");
                $("#returnSY").attr("onclick", "rzdbReturnSY(3);");

                //自动打开摄像头
                if ($("#rzdb_pai").attr("src") == "/YtjCommon/img/pai.png") {
                    rzdbCamera(0);
                } else {
                    $('#opencamearbutton').attr("onclick", "javascript:rzdbCamera(0);");
                    $('#opencamearbutton').val("重新拍照");
                    $('#opencamearbutton').show();

                    if ($("#rzduibiScore").val() != "") {
                        if ($("#sxqianming").attr("src") == "/YtjCommon/img/qian.png") {
                            open_PenSigner();//打开签字板
                            voicezdyStr('请拿起面板上的手写笔进行签名，签名完成后单击屏幕上的确认按钮');
                        } else {
                            //确认、清除按钮隐藏，显示重签打开按钮
                            $("#writeokButton").hide();
                            $("#writeclearButton").hide();
                            $("#writeopenButton").val("重签");
                            $("#writeopenButton").show();
                        }
                        //}
                    }
                }
            }
        }
        if (flg == "4") {
            getcllist();
            $("#rzbddiv").hide();
            $("#qrtjdiv").hide();
            $("#clscdiv").show();
            $("#tprzbd").removeClass("selected");
            $("#tpqrtj").removeClass("selected");
            $("#tpclsc").addClass("selected");

            //上传材料 这一步 加上 关闭摄像头判断
            $("#returnSY").attr("href", "#");
            $("#returnSY").attr("onclick", "rzdbReturnSY(4);");
        }
        if (flg == "5") {
            $("#tpclsc").removeClass("selected");
            $("#clscdiv").hide();
            $("#tpqrtj").addClass("selected");
            $("#qrtjdiv").show();

            $("#tjmc").html($("#nsqmc").val());
            if ($("#nsqmc").val() == "") {
                $("#tjmc").html("***");
            }
            $("#tjje").html($("#zczb").val() + "万元");
            var a = $("#result").val();


            a = a.split(",");
            $("#tjhy").html(a[1]);
            if ($("#jyfw").val().length > 120) {
                $("#tjfw").css("font-size", "18px");
                $("#tjfw").css("line-height", "25px");
            }
            if ($("#jyfw").val().length > 160) {
                $("#tjfw").css("font-size", "14px");
            }
            $("#tjfw").html($("#jyfw").val());
            if ($("#jycsc").find("option:selected").text() != "请选择") {
                /*  $("#tjdz").html("石家庄市" + $("#jycsz").find("option:selected").text() + $("#jycsc").find("option:selected").text() + $("#xxdz").val());  */
                // $("#tjdz").html(scity+city1 +$("#xxdz").val());
                $("#tjdz").html($("#jycsq").val() + $("#xxdz").val());
            } else {
                //有上级城市的
                // $("#tjdz").html(scity+city1 + $("#xxdz").val());
                $("#tjdz").html($("#jycsq").val() + $("#xxdz").val());
            }
            $("#tjxm").html($("#jyzxm").val());
            $("#tjdh").html($("#jyzdh").val());
            $("#tjsfz").html($("#jyzsfz").val());
            //getzhengzhaolist();
        }
    }

    function CheckForm() //表单提交验证
    {
        var reg = /^[0-9]+(\.[0-9]+)?$/;
        if ($("#zczb").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请填写资金数额',
                'closeTime': 4000,
            });
            return false;
        }
        if (!reg.test($("#zczb").val())) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '资金数额只能输入数字',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#zczb").val() == "0") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '资金数额不能为0',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#jyfw").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '经营范围不能为空',
                'closeTime': 4000,
            });
            return false;
        }
        /* if ($("#jycsz").val() == "")
         {
             jqueryAlert({
                 'icon': '/YtjCommon/img/warning.png',
                 'content': '请选择经营场所所在乡镇',
                 'closeTime': 4000,
             })
             return false;
         }
         if ($("#jycsc").val() == "") {
             jqueryAlert({
                 'icon': '/YtjCommon/img/warning.png',
                 'content': '请选择经营场所所在村街',
                 'closeTime': 4000,
             })
             return false;
         }*/
        if ($("#xxdz").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请填写详细地址',
                'closeTime': 2000,
            });
            return false;
        }
        if ($("#cyrs").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请输入从业人数',
                'closeTime': 4000,
            });
            return false;
        }
        if (!reg.test($("#cyrs").val())) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '从业人数只能输入数字',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#jyzxm").val() == "") {
            alert("请填写经营者姓名！");
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请填写经营者姓名',
                'closeTime': 4000,
            });
            return false;
        }
        var regphone = /^(13[0-9]|14[5-9]|15[012356789]|166|17[0-8]|18[0-9]|19[8-9])[0-9]{8}$/;
        if ($("#jyzdh").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请填写经营者手机号',
                'closeTime': 4000,
            });
            return false;
        }
        if (regphone.test($("#jyzdh").val()) == false) {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请填写正确的手机号码',
                'closeTime': 4000,
            });
            return false;
        }
        if ($("#jyzsfz").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请填写经营者身份证号码',
                'closeTime': 4000,
            });
            return false;
        }
        return true;
    }

    var lock = true;

    function SubMit() //提交数据
    {
        if (lock) {
            lock = false;
            var url = prefix + "SubmitForm";
            if (CheckForm()) {
                voicezdyStr('提交中，请等待');
                $("#toast p.weui_toast_content").html("提交中，请等待");
                $("#toast").show();
                try {

                    $.post(url,
                        $("#form1").serialize(),
                        function (rtnData) {
                            if (rtnData == "1") {
                                $("#toast").hide();
                                window.location.href = "/Ytj/GsYw/sl6";
                            } else {
                                lock = true;
                                $("#toast").hide();
                                jqueryAlert({
                                    'icon': '/YtjCommon/img/warning.png',
                                    'content': '提交失败，请联系技术支持，手机:18830910706',
                                    'closeTime': 4000,
                                })
                            }
                        });

            }  catch  (e)
            {
                lock = true;
                $("#toast").hide();
                jqueryAlert({
                    'icon': '/YtjCommon/img/warning.png',
                    'content': '提交失败，请联系技术支持，手机:18830910706',
                    'closeTime': 4000,
                });
                return false;
            }
        }
        }
        else
        {
            $("#toast").hide();
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请勿重复提交',
                'closeTime': 4000,
            })
        }
    }

    //获取输入法
    function imeOpen(eleID) {
        var info = document.getElementById(eleID).value;
        var test = {'info': info, 'ispassword': 0};
        var data = JSON.stringify(test);
        send_command(
            "imewrite",
            data,
            function (receivedData) {
                var data = JSON.parse(receivedData);
                if (eleID == "hymc") {
                    $("#hymc").val("");
                }
                if (eleID == "zzxx") {
                    $("#zzxx").val("");
                }
                document.getElementById(eleID).value = data.msg;
                if (eleID == "zwzh1" && $("#xyzh").val() == "zwzh1") {
                    MName();
                } else {
                    AutoName();
                }
            }
        );
    }

    //获取数字键
    function numbOpen(eleID) {
        var info = document.getElementById(eleID).value;
        var test = {'info': info, 'ispassword': 0};
        var data = JSON.stringify(test);
        send_command(
            "ime_number",
            data,
            function (receivedData) {
                var data = JSON.parse(receivedData);
                if (eleID == "hymc") {
                    $("#hymc").val("");
                }
                if (eleID == "zzxx") {
                    $("#zzxx").val("");
                }
                document.getElementById(eleID).value = data.msg;
                if (eleID == "zwzh1" && $("#xyzh").val() == "zwzh1") {
                    MName();
                } else {
                    AutoName();
                }
            }
        );
    }

    function CloseDive(did) {
        $("#" + did + "").hide();
    }

    function GetGet() {
        if ($("#result").val() != "") {
            $("#ccbj").val("0");
            $("#yxmc").html("");
            var url = prefix + "GetHymc";
            var data = {"name": encodeURI($("#result").val())};
            $.ajax({
                url: url,
                type: "get",
                dataType: 'json',
                data: data,
                success: function (data) {
                    if (data != "" && data != null) {
                        $("#hymcdiv").show();
                        $("#hymc").val("");
                        var str = "<div id=\"blk2\" class=\"blk\">";
                        str += "<div class=\"head\"><div class=\"head-right\"></div></div>";
                        str += "<div class=\"main\">";
                        str += "<ul id=\"hymclist\">";
                        $.each(data, function (i, item) {
                            str += "<li><a href=\"javascript:GetName('" + item.fullName + "')\">" + item.fullName + "</a></li>";
                        });
                        str += "</ul>";
                        str += "</div>";
                        str += "<div class=\"foot\"><div class=\"foot-right\"></div></div>";
                        str += "</div>";
                        layer.open({
                            type: 1,
                            title: "请选择名称行业",
                            area: ['800px', '400px'],
                            shade: 0,
                            shadeClose: true, //点击遮罩关闭
                            closeBtn: 0,
                            btn: ['关闭'], //只是为了演示
                            yes: function () {
                                layer.close(layer.index);
                            },
                            content: str
                        });
                    }
                },
                error: function (XMLHttpRequest, textStatus, errorThrown) {
                    alert("数据加载失败")
                }
            });
        } else {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择行业分类子项',
                'closeTime': 4000,
            })
        }
    }

    function GetName(obj) {
        $("#hymc").val(obj);

        layer.close(layer.index);
        AutoName();
    }

    function GetName1(obj) {
        $("#zzxx").val(obj);
        layer.close(layer.index);
        AutoName();
    }

    //没有字号时下一步
    function no_step() {
        if ($("#HY1").val() == "" || $("#result").val() == "") {
            jqueryAlert({
                'icon': '/YtjCommon/img/warning.png',
                'content': '请选择行业分类',
                'closeTime': 4000,
            });
            return false;
        } else {
            $("#tpmcxx").removeClass("selected");
            $("#mcxzdiv").hide();
            $("#mcxxdiv").hide();
            $("#tprzbd").removeClass("selected");
            $("#rzbddiv").hide();
            $("#tpqyxx").addClass("selected");
            $("#qyxxdiv").show();
            $("#nsqmc").val("***");
            voicezdyStr('请完善商户信息');
        }
    }

    //切换有无字号
    function qhyw(flg) {
        if (flg == "0") {
            //$("#yzh").attr("class", "li-o");
            $('.li-mask').css("top", "0px");
            // voicezdyStr('请参考右侧示例进行填报');
            $("#zwzh1").focus();
            $("#qhzh").val("0");
            $("#txzh").show();
            $("#wxts").show();
            $("#yzhxyb").show();
            $("#djd").hide();
            $("#wzhxyb").hide();
            $("#ncdiv").show();
            $("#yxdiv").show();
            $("#sldiv").show();
            if ($("#result").val() != "") {
                $("#hymcdiv").show();
                $("#zzxxdiv").show();
            }
            //$("#positionDiv").css("margin", "-280px 0 0 -490px");
        } else {
            //$("#wzh").attr("class", "li-o");
            $('.li-mask').css("top", "185px");
            $("#qhzh").val("1");
            $("#txzh").hide();
            $("#wxts").hide();
            $("#djd").show();
            $("#hymcdiv").hide();
            $("#zzxxdiv").hide();
            $("#yzhxyb").show();
            $("#wzhxyb").show();
            $("#ncdiv").hide();
            $("#yxdiv").hide();
            $("#sldiv").hide();
            //删除字号
            $("#zwzh1").val("");
            $("#zwzh2").val("");
            $("#zwzh3").val("");
            $("#hymc").val("");
            $("#zzxx").val("")


            //$("#positionDiv").css("margin", "-160px 0 0 -490px");
        }
    }
</script>
<body onload="initPage()">
<header>
    <h2 style="    font-weight: bold;" class="title fl tit-con" th:text="${city}+'个体企业执照自助打印终端'"></h2>
    <a id="returnSY" class="fr fan" href="/Ytj/GsYw">返回首页</a></header>
<div class="content">
    <div class="bg_white">
        <div class="step_section" style="width:1600px;">
            <div class="step_item " style="width:190px;">
                <div class="step_item_icon_arrow"></div>
                办理须知
            </div>
            <div class="step_item selected" style="width:189px;" id="tpmcxx">
                <div class="step_item_icon_arrow"></div>
                名称信息
            </div>
            <div class="step_item  " style="width:189px;" id="tpqyxx">
                <div class="step_item_icon_arrow"></div>
                商户信息
            </div>
            <div class="step_item" style="width:189px;" id="tprzbd">
                <div class="step_item_icon_arrow"></div>
                人证对比
            </div>
            <div class="step_item" style="width:189px;" id="tpclsc">
                <div class="step_item_icon_arrow"></div>
                材料上传
            </div>
            <div class="step_item" style="width:190px;" id="tpqrtj">
                <div class="step_item_icon_arrow"></div>
                确认提交
            </div>
            <div class="step_item " style="width:200px;"> 办理完成</div>
        </div>
        <form id="form1" name="form1">
            <input id="bsid" name="bsid" type="hidden" th:value="${BSID}"/>
            <input id="xxly" name="xxly" type="hidden"/>
            <input id="xgflg" name="xgflg" type="hidden" value="0"/>
            <input id="qhzh" name="qhzh" type="hidden" value="0"/>
            <!--            @*名称信息div*@-->
            <div class="ul-t">
                <div class="content_960_b" style=" border-top:none;" id="mcxxdiv">
                    <div class="con_900">
                        <div class="sbxxtl">
                            <div class="con_840" style="position:relative">
                                <div id="sldiv" style="position:absolute;right:100px;top:80px;"><img
                                        src="/YtjCommon/img/li.png"/></div>
                                <div class="sbxxtl_title mb20">拟申报名称基本信息</div>
                                <div class="o-m" style="margin-top: 10px; height:680px;" id="mcxzdiv">
                                    <div class="ul-o">
                                        <ul>

                                            <li class="li-t" onclick="qhyw('0')" id="yzh"><span></span>
                                                <p style="padding-left:20px;">有名称个体户</p>
                                                <div class="clear"></div>
                                                <b></b>
                                                <div style="background: #fff; height: 5px"></div>
                                            </li>

                                            <li class="li-o" onclick="qhyw('1')" id="wzh"><span></span>
                                                <p style="padding-left:20px;">无名称个体户</p>
                                                <div class="clear"></div>
                                                <b></b></li>


                                            <div class="li-mask"></div>
                                        </ul>
                                    </div>
                                    <div class="form_item" style=" margin-top:50px;">
                                        <label class="input_label">行政区划：</label>
                                        <div class="input_right">
                                            <input type="text" class="txt" name="xzq" id="xzq" readonly="readonly"
                                                   th:value="${city}">
                                        </div>
                                    </div>
                                    <div class="form_item" id="qyztlx" style="display:none">
                                        <label class="input_label">市场主体类型：</label>
                                        <div class="input_right">
                                            <select name="sczt" id="sczt" checktitle="市场主体类型~!" style="width:257px">
                                                <option value="个体工商户" title="个体工商户">个体工商户</option>
                                            </select>
                                            <br>
                                        </div>
                                    </div>
                                    <div class="form_item" id="txzh">
                                        <label class="input_label">中文字号：</label>
                                        <div class="input_right">
                                            <ul class="zihao">
                                                <li><input type="text" name="zwzh1" id="zwzh1"
                                                           onclick="imeOpen('zwzh1')" onblur="MName()" maxlength="20"
                                                           class="txt" style="width:257px;">（默&nbsp;&nbsp;认）必&nbsp;&nbsp;&nbsp;填
                                                    <button class="btn-chong btn-xuan" style="margin-left: 22px;"
                                                            type="button" id="xzzh1" onclick="ChooseName('zwzh1','1')">
                                                        <a href="#">选择</a></button>
                                                </li>
                                                <li><input type="text" name="zwzh2" id="zwzh2"
                                                           onclick="imeOpen('zwzh2')" value="" maxlength="20"
                                                           class="txt" style="width:257px;">（备选1）非必填
                                                    <button class="btn-chong" type="button" id="xzzh2"
                                                            onclick="ChooseName('zwzh2','2')"><a href="#">选择</a>
                                                    </button>
                                                </li>
                                                <li><input type="text" name="zwzh3" id="zwzh3"
                                                           onclick="imeOpen('zwzh3')" value="" maxlength="20"
                                                           class="txt" style="width:257px;">（备选2）非必填
                                                    <button class="btn-chong" type="button" id="xzzh3"
                                                            onclick="ChooseName('zwzh3','3')"><a href="#">选择</a>
                                                    </button>
                                                </li>
                                                <li style="display:none"><input type="text" name="zwzh4" id="zwzh4"
                                                                                onclick="imeOpen('zwzh4')" value=""
                                                                                maxlength="20" class="txt"
                                                                                style="width:257px;">（备选3）
                                                    <button class="btn-chong" type="button" id="xzzh4"
                                                            onclick="ChooseName('zwzh4','4')"><a href="#">选择</a>
                                                    </button>
                                                </li>
                                            </ul>
                                        </div>
                                    </div>
                                    <div class="form_item" id="wxts">
                                        <font color="red">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;温馨提示：中文字号名称后台按照默认、备选进行依次查重，结果以后台核准通过为准。</font>
                                    </div>
                                    <div class="form_item">
                                        <label class="input_label">行业分类：</label>
                                        <div class="input_right">
                                            <select name="HY1" id="HY1" checktitle="行业大类~!"
                                                    style="width:357px;height:44px;" onchange="GetHangYe2(this.value)">
                                                <option value="">请选择</option>
                                            </select>&nbsp;
                                            <input type="text" name="result" id="result" value="" checktitle=""
                                                   maxlength="100" class="txt" style="width:457px;"
                                                   onclick="GetHangYe3()" readonly="true">
                                            <div id="positionDiv">
                                            </div>
                                        </div>
                                    </div>
                                    <div class="form_item" id="djd" style="display:none;height:385px;"><br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font
                                            color="red">注：如选择“无名称个体户”营业执照名称为“***”。</font></div>
                                    <div class="form_item" style="display:none" id="hymcdiv">
                                        <label class="input_label">名称行业：</label>
                                        <div class="input_right">
                                            <input type="text" name="hymc" id="hymc" onclick="imeOpen('hymc')" value=""
                                                   maxlength="20" class="txt" style="width:257px;">
                                            <button class="btn-chong" type="button" id="mchyxz" onclick="GetGet()"><a
                                                    href="javascript:void(0)">快捷选择</a></button>
                                        </div>
                                    </div>
                                    <div class="form_item" style="display: none; margin-left:55px;" id="zzxxdiv">
                                        <label class="input_label" style=" margin-left:40px;">组织形式：</label>
                                        <div class="input_right">
                                            <input type="text" name="zzxx" id="zzxx" onclick="imeOpen('zzxx')" value=""
                                                   maxlength="20" class="txt" style="width: 257px;"
                                                   placeholder="如：店、厂、中心、铺">
                                            <button class="btn-chong" type="button" id="zzxxxz" onclick="GetXx()"><a
                                                    href="javascript:void(0)">快捷选择</a></button>
                                        </div>
                                    </div>
                                    <div class="form_item" style="display:none">
                                        <label class="input_label">组成形式：</label>
                                        <div class="input_right">
                                            <select style="width:118px;" name="zcxx" id="zcxx">
                                                <option>个人经营</option>
                                                <option>家庭经营</option>
                                            </select>
                                        </div>
                                    </div>
                                    <div class="form_item">
                                        <label class="input_label" style=" margin-left:95px;">门店类型：</label>
                                        <div class="col-sm-4">
                                            <label class="radio-box"><input type="radio" checked="" value="实体店" onchange="changeType(1)" id="type" name="type">实体店</label>
                                            <label class="radio-box"><input type="radio" value="网店" id="type1"onchange="changeType(2)"  name="type">网店</label>
                                        </div>
                                    </div>
                                    <input name="xzqhwz" id="xzqhwz" type="hidden" value="0">
                                    <div class="remindBox" id="ncdiv">拟查重名称：<b class="t_ccmc" id="ncmc"></b><input
                                            type="hidden" name="hmc" id="hmc"/> <input type="hidden" name="xyzh"
                                                                                       id="xyzh" value="zwzh1"/> <input
                                            type="hidden" name="ccbj" id="ccbj" value="0"/>
                                        <button class="btn-chong" type="button" id="Mccc" onclick="CheckName()"
                                                style="height:40px;line-height:40px;"><a href="#">名称查重</a></button>
                                    </div>
                                    <div class="sbmc_list" id="yxdiv">
                                        <div class="sbmc_title">已选名称</div>
                                        <ul class="sortablelist" id="yxmc">
                                        </ul>
                                    </div>
                                    <div class="solid_line_top mb30" style="margin-top:5px;"></div>
                                    <div class="form_item" id="yzhxyb" style="margin-top:-45px;">
                                        <label class="input_label" style="width:40%">&nbsp;</label>
                                        <a href="#">
                                            <button class="btn btn-fan fl" type="button" onclick="goBack()">上一步</button>
                                        </a>
                                        <button class="btn_b btn fl" type="button" onclick="go_step('2');">下一步</button>
                                    </div>
                                </div>
                                <br>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="clear"></div>
            </div>
            <!--            @*企业信息div*@-->
            <div class="content_960_b" style="display:none;border-top:none;" id="qyxxdiv">
                <div class="con_900">
                    <div class="sbxxtl">
                        <div class="sbxxtl_title mb20">拟申请名称</div>
                        <div class="form_item">
                            <label class="input_label">名称：</label>
                            <div class="input_right" style="height:auto;">
                                <input type="text" class="txt" name="nsqmc" id="nsqmc" disabled="" style="width:400px;">
                            </div>
                        </div>
                        <div class="sbxxtl_title mb20">其它资料完善</div>
                        <div class="form_item">
                            <label class="input_label"><span class="fred">*</span> 资金数额：</label>
                            <div class="input_right">
                                <input name="zczb" id="zczb" checktitle="注册资本~:isMoney_wy2!" type="text" class="txt"
                                       style="width:180px;">
                                <b>万元</b> <span id="regcap_a" class="input_info"
                                                style="clear:both;display:none; left:395px; top:0px;">注册资本币种为人民币，单位为<b>万元</b>（请填写阿拉伯数字）。
              <p></p>
              </span></div>
                        </div>
                        <div class="form_item">
                            <label class="input_label"><span class="fred">*</span>经营范围：</label>
                            <div class="input_right"><textarea class="fl" rows="5" cols="85" id="jyfw" name="jyfw"
                                                               onclick="imeOpen('jyfw')"></textarea>
                                <button class="btn-chong fl" type="button" id="xzfw" onclick="ChooseFw()"
                                        style="margin-top:30px;"><a href="#">快捷选择</a></button>
                                <div id="positionDiv1">
                                </div>
                            </div>
                        </div>
                        <div class="form_item" style="display: none;">
                            <label class="input_label"><span class="fred">*</span>电脑所在地：</label>
                            <div class="input_right" style="width:633px"><input style="width:633px" type="text" class="txt" id="jycszz"
                                                                                name="">
                            </div>
                        </div>
                        <div class="form_item">
                            <label class="input_label"><span class="fred">*</span>经营场所所在地：</label>
                            <div class="input_right">
                                <select name="jycsq" id="jycsq" checktitle="拟设立市场主体所在地~!" style="width: 180px;">
                                    <option th:value="${city}" th:text="${city}"></option>
                                </select>
                                <!-- <select name="jycsz" id="jycsz" style="width:118px;" onchange="GetXc(this.value)">-->
                                <!-- <input name="jycsz" id="jycsz" placeholder="请输入经营场所所在乡镇" style="width:118px;" onchange="imeOpen('jycsz')">
                                 </input>
                                 <input name="jycsc" id="jycsc" placeholder="请输入经营场所所在村" style="width:168px;"onchange="imeOpen('jycsz')">
                                 </input>-->
                                <input type="text" name="xxdz" class="txt" style="width:440px" id="xxdz"
                                       onclick="imeOpen('xxdz')" value="" checktitle="住所所在地详细地址!" placeholder="街道/门牌号">
                                <span id="location_a" class="input_info"
                                      style="display:none;left:545px;">请输入住所详细地址</span>
                            </div>
                        </div>

                        <div class="form_item">
                            <label class="input_label"><span class="fred">*</span>从业人数：</label>
                            <div class="input_right" style="width:350px"><input type="text" class="txt" id="cyrs"
                               name="cyrs">&nbsp;人
                            </div>
                            <label class="input_label"><span class="fred">*</span>经营者姓名：</label>
                            <div class="input_right" style="width:450px">
                                <input type="text" name="jyzxm" id="jyzxm" class="txt" value="" checktitle="经营者姓名~40:!">
                                <input type="hidden" name="jyzxb" id="jyzxb">
                                <input type="hidden" name="jyzmz" id="jyzmz">
                                <input type="hidden" name="jyztx" id="jyztx">
                                <input type="hidden" name="jyzzz" id="jyzzz">
                                <input type="hidden" name="sfzjg" id="sfzjg">
                            </div>
                        </div>
                        <div class="form_item">
                            <label class="input_label"><span class="fred">*</span>经营者手机号：</label>
                            <div class="input_right" style="width:350px">
                                <input type="text" name="jyzdh" id="jyzdh" class="txt" value=""
                                       checktitle="经营者联系电话~50:!">
                            </div>
                            <label class="input_label"><span class="fred">*</span>经营者身份证号码：</label>
                            <div class="input_right" style="width:450px">
                                <input type="text" name="jyzsfz" id="jyzsfz" class="txt" value="" checktitle="经营者身份证号码">
                            </div>
                        </div>
                        <div class="solid_line_top mb30 mt30"></div>
                        <div class="form_item">
                            <label class="input_label" style="width:40%;">&nbsp;</label>
                            <button type="button" class="btn btn-fan fl" onclick="go_step('1');">上一步</button>
                            <button id="mc_nextxq" class="btn_b btn fl" type="button" onclick="go_step('3');">下一步
                            </button>
                        </div>
                    </div>
                </div>
            </div>
            <!--            @*认证比对div*@-->
            <div style="width:1600px; margin:0 auto;display:none;margin-top:20px;" id="rzbddiv">
                <div class="fl col-lg-4" style="background:#a2dfff;padding-bottom:35px;">
                    <p class="pai_p">身份证件照</p>
                    <img id="rzdb_SFZ" style="width:140px;height:196px;margin-left:61px;" src="/YtjCommon/img/shua.png">
                    <p class="pai_p">拍照照片</p>
                    <img id="rzdb_pai" width="381px" height="240px" style="margin-left:61px;"
                         src="/YtjCommon/img/pai.png">
                </div>
                <div class="fl col-lg-4" style="background:#ffefcc;">
                    <img style="width:100%;margin:0 auto;height:520px;padding:10px 0;" src="/YtjCommon/img/pai.png">
                    <p class="center"><input type="button" id="opencamearbutton" value="打开摄像头" onclick="rzdbCamera(0)"
                                             class="btn-chong" style="width:120px;height:50px;"/></p>
                </div>
                <div class="fl col-lg-4" style="background:#a2dfff;padding-left:0px;padding-right:0px;">
                    <input type="button" id="cnsBtn" value="承诺书" onclick="cnsOpen()" class="btn-fan"
                           style="width:130px;margin-top:10px;display:none;"/>

                    <table class="table table-bordered table-rzdb" style="font-size: 22px;margin-bottom:0px;">
                        <tr style="display:none;">
                            <td><label class="input_label"><span class="fred">*</span>房屋规划用途：</label></td>
                            <td>
                                <div class="input_right">
                                    <label><input name="ghyt" type="radio" value="商用" style="margin-left: 10px;"/><i
                                            class="fa fa-2x icon-radio"></i>商用</label>
                                    <label style="margin-left: 40px;"><input name="ghyt" type="radio" value="住宅"
                                                                             checked/><i
                                            class="fa fa-2x icon-radio"></i>住宅</label>
                                    <input type="hidden" id="fwghyt" name="fwghyt" value=""/>
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td><label class="input_label"><span class="fred">*</span>是否军产：</label></td>
                            <td>
                                <div class="input_right">
                                    <label><input name="isjc" type="radio" value="1" style="margin-left: 10px;"/><i
                                            class="fa fa-2x icon-radio"></i>是</label>
                                    <label style="margin-left: 40px;"><input name="isjc" type="radio" value="0"
                                                                             checked/><i
                                            class="fa fa-2x icon-radio"></i>否</label>
                                    <input type="hidden" id="isjcHid" name="isjcHid" value=""/></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="padding-left: 0px;padding-right: 0px;"><label class="input_label"><span
                                    class="fred">*</span>住所（经营场所）属于：</label></td>
                            <td>
                                <div class="input_right">
                                    <select style="height: 31px; width: 257px;" name="jycssy" id="jycssy">
                                        <option value="1">非住宅</option>
                                        <option value="2">住宅</option>
                                    </select></div>
                            </td>
                        </tr>
                        <tr>
                            <td><label class="input_label"><span class="fred">*</span>经营场所产权归：</label></td>
                            <td>
                                <div class="input_right">
                                    <!--<input required  type="text" name="jycscq" id="jycscq" onclick="imeOpen('jycscq')" maxlength="50" class="txt" style="width: 257px;"></div>-->
                                    <select style="height: 31px; width: 257px;" name="jycscq" id="jycscq">
                                        <option value="1">租赁</option>
                                        <option value="2">自有</option>
                                    </select>
                            </td>
                        </tr>
                        <tr>
                            <td><label class="input_label"><span class="fred">*</span>是否为党员：</label></td>
                            <td>
                                <div class="input_right">
                                    <label><input name="isdy" type="radio" value="1" style="margin-left: 10px;"/><i
                                            class="fa fa-2x icon-radio"></i>是</label>
                                    <label style="margin-left: 40px;"><input name="isdy" type="radio" value="0"
                                                                             checked/><i
                                            class="fa fa-2x icon-radio"></i>否</label>
                                    <input type="hidden" id="isdyHid" name="isdyHid" value=""/>
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td><label class="input_label"><span class="fred">*</span>政治面貌：</label></td>
                            <td>
                                <div class="input_right">
                                    <select style="height: 31px; width: 257px;" name="zzmm" id="zzmm">
                                        <option value="群众">群众</option>
                                        <option value="党员">党员</option>
                                    </select></div>
                            </td>
                        </tr>
                        <tr>
                            <td><label class="input_label"><span class="fred">*</span>文化程度：</label></td>
                            <td>
                                <div class="input_right">
                                    <select style="height: 31px; width: 257px;" name="whcd" id="whcd">
                                        <option value="初中">初中</option>
                                        <option value="小学">小学</option>
                                        <option value="高中">高中</option>
                                        <option value="中专">中专</option>
                                        <option value="大专">大专</option>
                                        <option value="本科">本科</option>
                                        <option value="硕士">硕士</option>
                                        <option value="博士">博士</option>
                                        <option value="其他">其他</option>
                                    </select></div>
                            </td>
                        </tr>
                        <tr>
                            <td><label class="input_label"><span class="fred">*</span>职业状况：</label></td>
                            <td>
                                <div class="input_right">
                                    <select style="height: 31px; width: 257px;" name="zyzk" id="zyzk">
                                        <option value="待业">待业</option>
                                        <option value="务农">务农</option>
                                    </select></div>
                            </td>
                        </tr>
                    </table>
                    <img id="sxqianming" height="200px" style="width:100%;margin:0 auto;" src="/YtjCommon/img/qian.png">
                    <p class="center">
                        <input type="button" id="writeopenButton" value="打开签字板" onclick="open_PenSigner()"
                               class="btn-chong" style="width:120px;height:50px;"/>
                        <input type="button" id="writeclearButton" value="重签" class="btn-chong"
                               style="width:120px;height:50px;display:none;" onclick="Clean_PenSigner()"/>
                        <input type="button" id="writeokButton" value="确认" class="btn-chong"
                               style="width:120px;height:50px;display:none;" onclick="Close_PenSigner1()"/>
                    </p>
                </div>
                <input type="hidden" name="paizhao" id="paizhao"/>
                <input type="hidden" name="QianMing" id="QianMing"/>
                <input type="hidden" name="qmHid" id="qmHid"/>
                <input type="hidden" name="rzduibiScore" id="rzduibiScore" value="0"/>
                <div class="col-md-12 col-lg-12">
                    <div class="form_item">
                        <label class="input_label fl" style="width:40%">&nbsp;</label>
                        <button type="button" class="btn btn-fan fl" onclick="duibi('2')">上一步</button>
                        <button id="mc_nextxq1" class="btn_b btn fl" type="button" onclick="duibi('4')">下一步</button>
                    </div>
                </div>
            </div>

            <!--            @*材料上传div*@-->
            <div style="width: 1600px; margin: 0 auto;display:none;" id="clscdiv">
                <div style="padding-top: 30px;">
                    <div class="mainContainer fl col-lg-6">
                        <img style="width: 100%; margin: 0 auto; height: 550px;" src="/YtjCommon/img/sao.png"/>
                        <p class="tc" style="margin-bottom: 10px;">
                            <input type="button" id="clscPaibutton" value="拍照" class="btn-chong"
                                   style="margin-left: 0;height:50px;display:none;"/>
                        </p>
                    </div>
                    <div class="mainContainer col-lg-6">
                        <div class="navContent" id="cltype"></div>
                        <div class="container1" id="clContainer"></div>
                    </div>
                </div>
                <div class="col-md-12 col-lg-12">
                    <div class="form_item" style="margin-bottom: 30px;">
                        <label class="input_label fl" style="width: 40%">&nbsp;</label>
                        <button type="button" class="btn btn-fan fl" onclick="cailiaoleve('3');">上一步</button>
                        <button id="mc_nextxq2" class="btn_b btn fl" type="button" onclick="cailiaoleve('5');">下一步
                        </button>
                    </div>
                </div>
            </div>


            <!--            @*确认提交div*@-->
            <div class="content_960_b" style=" border-top:none;display:none" id="qrtjdiv">
                <input type="hidden" id="zzHid" name="zzHid" value=""/>
                <div class="con_900">
                    <div>
                        <div style="width: 85%; float: left;">
                            <div class="sbxxtl" deep="4">
                                <div class="form_item">
                                    <label class="input_label fgray">名称：</label>
                                    <div class="input_right input_right5" id="tjmc"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">类型：</label>
                                    <div class="input_right input_right5"> 个体工商户</div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">组成形式：</label>
                                    <div class="input_right input_right5">个人经营</div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray"> 资金数额： </label>
                                    <div class="input_right input_right5" id="tjje"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">行业：</label>
                                    <div class="input_right input_right5" id="tjhy"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">经营范围：</label>
                                    <div class="input_right input_right5" id="tjfw"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">经营场所：</label>
                                    <div class="input_right input_right5" id="tjdz"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">经营者姓名：</label>
                                    <div class="input_right input_right5" id="tjxm"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">经营者联系电话：</label>
                                    <div class="input_right input_right5" id="tjdh"></div>
                                </div>
                                <div class="form_item">
                                    <label class="input_label fgray">经营者身份证号码：</label>
                                    <div class="input_right input_right5" id="tjsfz"></div>
                                </div>
                            </div>
                        </div>

                        <div style="width: 15%; float: left; padding:20px;height:610px;overflow:auto;display:none;">
                            <table class="table table-bordered table-condensed table_sbxxtl" border="0" cellspacing="0"
                                   cellpadding="0">
                                <thead>
                                <tr>
                                    <th width="5%" style="text-align:center;">是否申请</th>
                                    <th width="25%" style="text-align:center;">整合证照事项名称</th>
                                </tr>
                                </thead>
                                <tbody id="zhengzhao"></tbody>
                            </table>
                        </div>
                    </div>
                </div>
                <div class="solid_line_top mb30 mt30"></div>
                <div style="padding-left:40%;">
                    <button type="button" class="btn btn-fan fl" style="width:20%" onclick="go_step('4');">上一步</button>
                    <button type="button" class="btn_b btn fl" style="width:20%" onclick="SubMit();">提交</button>
                </div>
            </div>
        </form>
    </div>
</div>
<div style="position:absolute;right:5%;bottom:10px;"><span class="fl dao" id="agree_btn">本页将在60秒后返回首页</span></div>

<!--@*灰色弹出框*@-->
<div id="toast" style=" display: none; ">
    <div class="weui_mask"></div>
    <div class="weui_toast"><img style="width:40px;height:40px;" src="/YtjCommon/img/loading.gif"/>
        <p class="weui_toast_content">请等待</p></div>
</div>

<script>
    function initPage() {
        function minsize() {
            var $content = $("#tjfw");
            if ($content.height() >= 600) {
                $content.css('font-size', parseInt($content.css('font-size')) - 1 + 'px');
                arguments.callee();  //callee表示对函数对象本身的引用，这有利于实现无名函数的递归或者保证函数的封装性
            }
        }

        minsize();
    }
    function  changeType(id) {
        var html
        //实体店
        if(id==1){
            html=' <option value="[[${city}]]" text="[[${city}]]">[[${city}]]</option>';
            $("#jycsq").html(html)
            $("#jyzzz").attr("name","jyzzz")
            $("#jycszz").attr("name","")
            $("#jycszz").parent().parent().css("display","none")
            $("#jycsq").parent().prev().html("<span class=\"fred\">*</span>经营场所所在地：")
        }
        //网店
        else {
            html=' <option value="拼多多平台" text="拼多多">拼多多平台</option>' +
                ' <option value="淘宝平台" text="淘宝">淘宝平台</option>' +
                ' <option value="58同城平台" text="58同城">58同城平台</option>' +
                ' <option value="微店平台" text="微店">微店平台</option>' +
                ' <option value="孔夫子旧书网平台" text="孔夫子旧书网">孔夫子旧书网平台</option>' +
                ' <option value="友赞平台" text="友赞">友赞平台</option>';
            $("#jycsq").html(html)
            $("#jycsq").parent().prev().html("<span class=\"fred\">*</span>店铺网络地址：")
            $("#jyzzz").attr("name","")
            $("#jycszz").attr("name","jyzzz")
            $("#jycszz").parent().parent().css("display","block")
        }
    }

</script>
<script>
    var secs = 3600;
    for (var i = 0; i <= secs; i++) {
        window.setTimeout("update(" + i + ")", i * 1000);
    }

    function update(num) {
        if (num == secs) {
            checkLeave();//关闭摄像头
            Close_PenSigner2();//关闭手写板
            // 超时返回到首页
            location.href = "/Ytj/GsYw";

        } else {
            var printnr = secs - num;

            var testdiv = document.getElementById("agree_btn");
            testdiv.innerHTML = "本页将在" + printnr + "秒后返回首页";
        }
    }

    function showtime(t) {
        document.myform.phone.disabled = true;
        for (i = 0; i <= t; i++) {
            window.setTimeout("update_p(" + i + "," + t + ")", i * 1000);
        }

    }

    function goBack() {
        window.location.href = "/Ytj/GsYw/GsIndex";
    }

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