<%@ page language="java" contentType="text/html;charset=UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,Chrome=1"/>
    <meta http-equiv="X-UA-Compatible" content="IE=9"/>
    <meta name="keywords"
          content="保险保函、电子保函、保证保险、保函开具、工程投标保证保险、建设合同履约保证保险、业主合同款支付保证保险、建设工程质量保证保险、建筑业企业人工工资支付保证保险、海关税保险、诉讼财产保全责任保险">
    <meta name="description" content="百联保是百川信（厦门）网络信息服务有限公司基于金融创新并响应“互联网＋”计划搭建的第三方金融服务平台。 ">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
    <title>百联保-支付保费</title>

    <link type="text/css" rel="stylesheet" href="<c:url value='/resources/versions-2.0/dist/css/bootstrap.min.css' />"/>
    <link type="text/css" rel="stylesheet" href="<c:url value='/resources/versions-2.0/dist/css/public.css' />"/>
    <link type="text/css" rel="stylesheet"
          href="<c:url value='/resources/versions-2.0/dist/css/insure/write-application.css' />"/>
    <link type="text/css" rel="stylesheet"
          href="<c:url value='/resources/versions-2.0/dist/css/insure/fileinput.css' />"/>
    <!--[if lt IE 9]>
    <script src="<c:url value='/resources/versions-2.0/js/html5shiv/3.7.2/html5shiv.min.js' />"></script>
    <script src="<c:url value='/resources/versions-2.0/js/respond.js/1.4.2/respond.min.js' />"></script>
    <![endif]-->
</head>

<%--<body style="background: rgba(244,245,246,1);">--%>
<%--<jsp:include page="../../../index/multi_h.jsp"/>--%>
<body>


<%--<div class="container" style="padding-bottom: 50px; padding-top: 20px;"><!-- container start -->--%>
    <%--<ol class="breadcrumb">--%>
        <%--<li><a href="<c:url value='/'/>">首页</a></li>--%>

    <%--</ol>--%>
    <%--<div class="nav-list">--%>
        <%--<div class="row w-80-auto">--%>
            <%--<div class="col-sm-3 col-sm-4 pull-right">--%>
                <%--<p><i class="pull-left">4</i><span class="pull-left">完成投保</span></p>--%>
            <%--</div>--%>
        <%--</div>--%>
    <%--</div>--%>
    <%--<form class="form-horizontal form-create-item" action="<c:url value='/insurance/build/transaction/policyPayment' />"--%>
          <%--method="post" id="policyPaymentForm">--%>
        <%--<input name="url" value="${url}" type="hidden"/>--%>
    <%--</form>--%>
    <%--<div class="row next-step">--%>

    <%--</div>--%>
<%--</div><!-- container end -->--%>

<%--<jsp:include page="../../../index/multi_f.jsp"/>--%>
<%--<a href="" id="gotoNewUrl" target="_blank"></a>--%>
<!-- script -->

</body>
<script type="text/javascript" src="<c:url value='/resources/script/jquery-1.10.2.min.js' />"></script>
<script type="text/javascript">
    /*var baseUrl = '${url}';
     var isSuccess = '${isSuccess}';
     var oid = '${oid}';
     var wrongMessage = '${wrongMessage}';*/
    $(document).ready(function () {
        console.log('1:' + '${isSuccess}');
        /*     location.href =baseUrl;*/

        if ('${isSuccess}') {
            window.location.href = '${url}';
        } else {
            layer.msg('${wrongMessage}', {time:2000});
            $.ajax({
                type: 'POST',
                url: '${url}/insurance/build/policy/updateOrderFormStatus',
                data: {
                    'order_id': '${oid}',
                    'status': '4'
                },
                dataType: "json",
                success: function (json) {
                    layer.close(index);
                    if (json.statusCode == '200') {
                        window.location.href = json.forwardUrl;
                    } else {
                        layer.msg(json.message);

                    }
                },
                error: function (XMLHttpRequest, textStatus, errorThrown) {
                    layer.close(index);
                    layer.msg(textStatus);
                }
            });
        }
    })

</script>
</html>