myorder.html 3.8 KB
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
    <title>我的订单</title>
    <link rel="stylesheet" href="__TMPL__/public/assets/css/init.css">
    <link href="__TMPL__/public/assets/css/swiper.min.css" rel="stylesheet" type="text/css">
    <link rel="stylesheet" href="http://at.alicdn.com/t/font_793738_ycnvxk1als.css">
    <link rel="stylesheet" href="__TMPL__/public/assets/css/shop.css">
    <script src="__TMPL__/public/assets/js/fontsize.js"></script>
</head>
<body style="background-color: #F5F6FA">
<div class="tab_box">
    <div class="tab_title tab_active">全部</div>
    <div class="tab_title">进行中</div>
    <div class="tab_title">已完成</div>
</div>
<div>

    <div class="tab_content">
        <volist name="order" id="vo">
            <a href="{:url('orderInfo',['id'=>$vo.id])}">
            <div class="tab_item">
                <div class="tab_info_box">
                    <div><img src="{:cmf_get_image_url($vo.thumbnail)}" alt=""></div>
                    <div>
                        <div class="tab_title1">{$vo.name}</div>
                        <div class="tab_info">{$vo.fee}积分</div>
                        <div class="tab_num">X{$vo.num}</div>
                    </div>
                </div>
                <div class="tab_state">
                    <switch name="$vo.status">
                        <case value="1|2">进行中</case>
                        <case value="3">已完成</case>
                    </switch>
                </div>
            </div>
            </a>
        </volist>
    </div>





    <div class="tab_content  hidden">
        <volist name="order2" id="vo">
            <a href="{:url('orderInfo',['id'=>$vo.id])}">
            <div class="tab_item">
                <div class="tab_info_box">
                    <div><img src="{:cmf_get_image_url($vo.thumbnail)}" alt=""></div>
                    <div>
                        <div class="tab_title1">{$vo.name}</div>
                        <div class="tab_info">{$vo.fee}积分</div>
                        <div class="tab_num">X{$vo.num}</div>
                    </div>
                </div>
                <div class="tab_state">
                    <switch name="$vo.status">
                        <case value="1|2">进行中</case>
                        <case value="3">已完成</case>
                    </switch>
                </div>
            </div>
            </a>
        </volist>
    </div>


    <div class="tab_content  hidden">
        <volist name="order3" id="vo">
            <a href="{:url('orderInfo',['id'=>$vo.id])}">
            <div class="tab_item">
                <div class="tab_info_box">
                    <div><img src="{:cmf_get_image_url($vo.thumbnail)}" alt=""></div>
                    <div>
                        <div class="tab_title1">{$vo.name}</div>
                        <div class="tab_info">{$vo.fee}积分</div>
                        <div class="tab_num">X{$vo.num}</div>
                    </div>
                </div>
                <div class="tab_state">
                    <switch name="$vo.status">
                        <case value="1|2">进行中</case>
                        <case value="3">已完成</case>
                    </switch>
                </div>
            </div>
            </a>
        </volist>
    </div>
</div>



<style>
    .hidden{
        display: none;
    }
</style>

<script src="__TMPL__/public/assets/js/jquery-2.1.0.js"></script>
<script>
    $('.tab_title').click(function () {
        var index=$(this).index()
        $(this).addClass('tab_active').siblings().removeClass('tab_active')
        $('.tab_content').eq(index).show().siblings().hide()
    })
</script>
</body>
</html>