coupons.hbs 7.98 KB
<div class="me-coupons-page me-page yoho-page clearfix">
        {{> path}}
        {{> navigation}}
        <div class="me-main">
            <div class="coupons{{#if unUse}} un-use-coupons{{/if}}{{#if used}} used-coupons{{/if}}{{#if noValid}} no-valid-coupons{{/if}} block">
                <h2 class="title">优惠券</h2>

                {{> tabs}}
                <div class="coupons-wrap">
                    <p class="coupons-header clearfix">
                        <span class="coupons-name">优惠券名称</span>
                        <span class="coupons-info">详细说明</span>
                        {{#if unUse}}
                            <span class="coupons-opt">操作</span>
                        {{/if}}
                        {{#if used}}
                            <span class="coupons-opt">订单号</span>
                        {{/if}}
                        {{#if noValid}}
                            <span class="coupons-opt">状态</span>
                        {{/if}}
                    </p>

                    {{# unUseCoupons}}
                    {{#unless empty}}
                        <div class="coupon" data-couponId="{{id}}">
                            <div class="coupons-name">
                                <div class="coupons-card coupons-notuse">
                                    <div class="coupons-date clearfix">
                                        <p class="left">{{beginTime}} - {{endTime}}</p>
                                        <p class="right">{{overState}}</p>
                                    </div>
                                    <div class="coupons-num clearfix">
                                        <div class="left coupons-sht">
                                            <p class="coupons-price">{{value}}</p>
                                            <p class="coupons-full">{{rule}}</p>
                                        </div>
                                        <div class="left coupons-dtl">{{useRemark}}</div>
                                    </div>
                                </div>
                            </div>
                            <div class="coupons-info">
                                <div class="coupons-text">
                                    {{#categorys}}<p>限品类:{{.}}</p>{{/categorys}}
                                    {{#brands}}<p>限品牌:{{.}}</p>{{/brands}}
                                    {{#if isNoLimit}}<p>全场通用</p>{{/if}}
                                    <p>特例商品({{extraPro}}等特例商品)暂不支持使用优惠券。</p>
                                    {{#explains}}<p>说明:{{.}}</p>{{/explains}}
                                </div>
                            </div>
                            <div class="coupons-opt">
                                <a class="btn use-btn" id="coupon-use" href="{{proListUrl}}" target="_black">立即使用</a>
                            </div>
                        </div>
                    {{/unless}}
                    {{/ unUseCoupons}}

                    {{# usedCoupons}}
                    {{#unless empty}}
                        <div class="coupon" data-couponId="{{id}}">
                            <div class="coupons-name">
                                <div class="coupons-card coupons-use">
                                    <div class="coupons-date clearfix">
                                        <p class="left">{{beginTime}} - {{endTime}}</p>
                                    </div>
                                    <div class="coupons-num clearfix">
                                        <div class="left coupons-sht">
                                            <p class="coupons-price">{{value}}</p>
                                            <p class="coupons-full">{{rule}}</p>
                                        </div>
                                        <div class="left coupons-dtl">{{useRemark}}</div>
                                    </div>
                                </div>
                            </div>
                            <div class="coupons-info">
                                <div class="coupons-text">
                                    {{#categorys}}<p>限品类:{{.}}</p>{{/categorys}}
                                    {{#brands}}<p>限品牌:{{.}}</p>{{/brands}}
                                    {{#if isNoLimit}}<p>全场通用</p>{{/if}}
                                    <p>特例商品({{extraPro}}等特例商品)暂不支持使用优惠券。</p>
                                    {{#explains}}<p>说明:{{.}}</p>{{/explains}}
                                </div>
                            </div>
                            <div class="coupons-opt">
                            <a href="{{orderDetailUrl}}">
                                <p>{{orderNum}}</p>
                                <p>{{useTime}}</p>
                            </a>
                            </div>
                        </div>
                    {{/unless}}
                    {{/ usedCoupons}}

                    {{# noValidCoupons}}
                    {{#unless empty}}
                        <div class="coupon" data-couponId="{{id}}">
                            <div class="coupons-name">
                                <div class="coupons-card coupons-overtime">
                                    <div class="coupons-date clearfix">
                                        <p class="left">{{beginTime}} - {{endTime}}</p>
                                    </div>
                                    <div class="coupons-num clearfix">
                                        <div class="left coupons-sht">
                                            <p class="coupons-price">{{value}}</p>
                                            <p class="coupons-full">{{rule}}</p>
                                        </div>
                                        <div class="left coupons-dtl">{{useRemark}}</div>
                                    </div>
                                </div>
                            </div>
                            <div class="coupons-info">
                                <div class="coupons-text">
                                    {{#categorys}}<p>限品类:{{.}}</p>{{/categorys}}
                                    {{#brands}}<p>限品牌:{{.}}</p>{{/brands}}
                                    {{#if isNoLimit}}<p>全场通用</p>{{/if}}
                                    <p>特例商品({{extraPro}}等特例商品)暂不支持使用优惠券。</p>
                                    {{#explains}}<p>说明:{{.}}</p>{{/explains}}
                                </div>
                            </div>
                            <div class="coupons-opt">
                                <a class="btn overtime-btn">过期</a>
                            </div>
                        </div>
                    {{/unless}}
                    {{/ noValidCoupons}}
                </div>
                {{#if unUseCoupons}}
                    {{#unless unUseCoupons.empty}}
                        {{> pager}}
                    {{^}}
                        {{#with unUseCoupons}}
                            {{> empty}}
                        {{/with}}
                    {{/unless}}
                {{/if}}

                {{#if usedCoupons}}
                    {{#unless usedCoupons.empty}}
                        {{> pager}}
                    {{^}}
                        {{#with usedCoupons}}
                            {{> empty}}
                        {{/with}}
                    {{/unless}}
                {{/if}}

                {{#if noValidCoupons}}
                    {{#unless noValidCoupons.empty}}
                        {{> pager}}
                    {{^}}
                        {{#with noValidCoupons}}
                            {{> empty}}
                        {{/with}}
                    {{/unless}}
                {{/if}}
            </div>
        </div>

</div>