ordertail.html 8.5 KB
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
    <link rel="stylesheet" href="https://at.alicdn.com/t/font_886149_x7uh64tifl.css">

    <!--<link rel="stylesheet" href="__TMPL__/public/assets/css/example.css"/>-->
    <link rel="stylesheet" href="__TMPL__/public/assets/css/base.css">
    <link rel="stylesheet" href="__TMPL__/public/assets/css/ordertail.css">



    <title>我要雇人</title>
    <script type="text/javascript" src="__TMPL__/public/assets/js/jquery.min.js"></script>
    <script type="text/javascript" src="__TMPL__/public/assets/js/base.js"></script>
    <style>

    </style>
</head>
<body>
<div class="container">
    <div class="head">
        <p class="ordernum">订单号:{$list.order_sn}</p>
        <eq name="list.status" value="2"><p class="orderstate">待审核</p></eq>
        <eq name="list.status" value="3"><p class="orderstate">待付款</p></eq>
        <eq name="list.status" value="4"><p class="orderstate">审核未通过</p></eq>
        <eq name="list.status" value="5"><p class="orderstate">已取消</p></eq>
        <eq name="list.status" value="6"><p class="orderstate">待完成</p></eq>
        <eq name="list.status" value="10"><p class="orderstate">待完成</p></eq>
        <eq name="list.status" value="7"><p class="orderstate">待评价</p></eq>
        <eq name="list.status" value="8"><p class="orderstate">已评价</p></eq>
    </div>
    <div class="ordercontent">
        <p class="content_name">{$list.select_name}</p>
        <p class="content_price">¥{$list.money}/天</p>
        <p class="content_date">{$list.start_time}-{$list.end_time}</p>
        <in name="list.status" value="6,7,8">
        <p class="content_date">雇佣人员: {$list.user_name}</p>
        <p class="content_date">联系电话: {$list.user_tel}</p>
        </in>
    </div>
    <div class="companyinfo">
        <p class="signcompany">
            <img src="__TMPL__/public/assets/images/companysign.png" alt="">
        </p>
        <div class="textcompany">
            <p class="company_name">公司名称</p>
            <div class="companytext_name">
                {$list.title}
            </div>
        </div>


    </div>

    <div class="companyinfo">
        <p class="signcompany">
            <img src="__TMPL__/public/assets/images/companysign.png" alt="">
        </p>
        <div class="textcompany">
            <p class="company_name">工作地点</p>
            <div class="companytext_name">
                {$list.address}
            </div>
        </div>


    </div>

    <div class="companyinfo">
        <p class="signcompany">
            <img src="__TMPL__/public/assets/images/companysign.png" alt="">
        </p>
        <div class="textcompany">
            <p class="company_name">工作要求</p>
            <div class="companytext_name">
                {$list.else}

            </div>
        </div>
    </div>
    <div class="companyinfo">
        <p class="signcompany">
            <img src="__TMPL__/public/assets/images/companysign.png" alt="">
        </p>
        <div class="textcompany">
            <p class="company_name">招聘人数</p>
            <div class="companytext_name">
                {$list.people} 人

            </div>
        </div>
    </div>
    <eq name="list.status" value="4">
        <div class="companyinfo">
            <p class="signcompany">
                <img src="__TMPL__/public/assets/images/companysign.png" alt="">
            </p>
            <div class="textcompany">
                <p class="company_name">审核不通过原因</p>
                <div class="companytext_name">
                    抱歉,您的资料填写不完整
                </div>
            </div>
        </div>
    </eq>
    <div class="orderfoot">
        <eq name="list.status" value="3">
            <p class="sure cancel" >取消订单</p>
            <p class="pay toPay">付款</p>
        </eq>
        <eq name="list.status" value="6">
            <p class=" pay sure">确认完成</p>
        </eq>
        <eq name="list.status" value="7">
            <p class="pay common">评价</p>
        </eq>
    </div>
</div>
<!--begin:提示弹层-->
<div class="pop_fn"></div>
<script>
    window.alert = function(name){
        var iframe = document.createElement("IFRAME");
        iframe.style.display="none";
        document.documentElement.appendChild(iframe);
        window.frames[0].window.alert(name);
        iframe.parentNode.removeChild(iframe);
    }
    window.confirm = function (message) {
        var iframe = document.createElement("IFRAME");
        iframe.style.display = "none";
        iframe.setAttribute("src", 'data:text/plain,');
        document.documentElement.appendChild(iframe);
        var alertFrame = window.frames[0];
        var result = alertFrame.window.confirm(message);
        iframe.parentNode.removeChild(iframe);
        return result;
    }

    var id = "{$Request.param.id}";
    var logId = "{$Request.param.logId}";
    // 取消
    $('.cancel').click(function change() {
        window.event.stopPropagation();
        var a=confirm("是否取消订单");
        if(a==true){
            $.ajax({
                type: 'POST',
                url: "{:url('Member/changeStatus')}",
                data: {
                    'id':id,
                },
                success: function (res) {
                    // console.log(res);
                    popup(res.message);
                    if(res.code == 1){
                        setTimeout("def()",2500);
                    }
                },
                error: function (res) {
                    // console.log(res);
                }
            });
        }
    })
    // 确认
    $('.cancel').click(function sure() {
        $.ajax({
            type: 'POST',
            url: "{:url('Member/sureStatus')}",
            data: {
                'id':logId,
            },
            success: function (res) {
                // console.log(res);
                popup(res.message);
                if(res.code == 1){
                    setTimeout("def()",2500);
                }
            },
            error: function (res) {
                // console.log(res);
            }
        });
    })

    //评价页面
    $('.cancel').click(function common() {
        var url = "{:url('Member/common')}";
        url = url.split('.');
        url = url[0] + '/id/' + logId + ".html";
        window.location.href = url;
    })

    wx.config({
        debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
        appId: "{$config.appId}", // 必填,公众号的唯一标识
        timestamp: "{$config.timestamp}", // 必填,生成签名的时间戳
        nonceStr: "{$config.nonceStr}", // 必填,生成签名的随机串
        signature: "{$config.signature}",// 必填,签名
        jsApiList: [
            'chooseWXPay'
        ] // 必填,需要使用的JS接口列表
    });
    // 支付
    $('.toPay').click(function toPay(){
        $.ajax({
            type: 'POST',
            url: "{:url('Member/toPay')}",
            data: {
                'id': id,
            },
            success: function (res) {
                wx.chooseWXPay({
                    timestamp: res.data.timeStamp , // 支付签名时间戳,注意微信jssdk中的所有使用timestamp字段均为小写。但最新版的支付后台生成签名使用的timeStamp字段名需大写其中的S字符
                    nonceStr: res.data.nonceStr, // 支付签名随机串,不长于 32 位
                    package: res.data.package, // 统一支付接口返回的prepay_id参数值,提交格式如:prepay_id=\*\*\*)
                    signType: res.data.signType, // 签名方式,默认为'SHA1',使用新版支付需传入'MD5'
                    paySign: res.data.paySign, // 支付签名
                    success: function (res) {
                        location.reload();
                        // window.location.href = "{:url('User/myOrder')}"
// 支付成功后的回调函数
                    },
                    error:function () {
                        alert('3333')
                    }
                });
                console.log(res);
            },
            error: function (res) {
                console.log(res);
            }
        });
    })

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