recommend-goods.hbs 4.76 KB
{{#if this}} {{!-- 剔除值为false的项 --}}
    {{#if is_shop}}
        <a class="good-info brand-info" data-type="hot-shop" data-brand="" data-shop="" href="{{shopUrl}}">
            <div class="brand-info-box">
                <img src="{{image shop_logo 240 85}}" alt="{{shop_name}}">
                {{!-- <h5 class="bname">{{shop_name}}</h5> --}}
                <p class="summary">
                    上新<b>{{new_product_num}}</b>&nbsp;
                    &nbsp;<b>{{favorite_num}}</b>人收藏
                </p>
                <span class="entry">进入店铺<span></span></span>

                <div class="shop-goods">
                    {{#product_list}}
                    <div class="info">
                        <img class="lazy" src="{{image default_images 110 145}}"></img>
                    </div>
                    {{/product_list}}
                </div>
            </div>
        </a>
    {{else}}
        <div class="good-info {{#if @root.sale_vip_login}}sale-vip{{/if}}" data-good-id="{{product_id}}"
             data-id="{{product_skn}}" data-bp-id="guang_goodList_{{product_name}}_false">
            <div class="tag-container clearfix">
                {{# tags}}
                    {{# is_new}}
                        <p class="good-tag new-tag">NEW</p>
                    {{/ is_new}}
                    {{# is_hot}}
                        <p class="good-tag hot-tag">HOT</p>
                    {{/ is_hot}}
                    {{# is_advance}}
                        <p class="good-tag renew-tag">再到着</p>
                    {{/ is_advance}}
                    {{# is_discount}}
                        <p class="good-tag sale-tag">SALE</p>
                    {{/ is_discount}}
                    {{# is_yohood}}
                        <p class="good-tag new-festival-tag">新品节</p>
                    {{/ is_yohood}}
                    {{# is_limited}}
                        <p class="good-tag limit-tag">限量</p>
                    {{/ is_limited}}
                    {{# is_presell}}
                        <p class="good-tag is-presell">预售</p>
                    {{/ is_presell}}
                    {{# is_global}}
                        <p class="good-tag is-global">
                            <span>{{../tbl_country_name}}</span>
                        </p>
                    {{/ is_global}}
                {{/ tags}}
            </div>
            <div class="good-detail-img">
                <a class="good-thumb" href="{{url}}" title="{{imgAlt}}">
                    {{#if @root._noLazy}}
                        <img src="{{image2 default_images w=235 h=314 q=60}}" alt="{{imgAlt}}"/>
                    {{else}}
                        <img class="lazy" data-original="{{image2 default_images w=235 h=314 q=60}}" alt="{{imgAlt}}"/>
                    {{/if}}
                </a>
                {{# is_soon_sold_out}}
                    <p class="few-tag">即将售罄</p>
                {{/ is_soon_sold_out}}

                {{# is_solded}}
                <p class="out-tag">已售罄</p>
                {{/ is_solded}}

                {{!-- {{# noStorage}}
                    <div class="no-storage">
                        <div class="no-storage-img"></div>
                    </div>
                {{/ noStorage}} --}}
                {{#if similar}}
                {{> common/similar}}
                {{/if}}
            </div>
            <div class="good-detail-text">
                <div class="name">
                    <a href="{{url}}" title="{{imgAlt}}">{{product_name}}</a>
                </div>
                <div class="price">
                    {{#if @root.saleViplogin}}
                        <i class="vip-grade vip-grade-{{@root.vipLevel}}"></i>
                        <span class="sale-price {{^market_price}}no-price{{/market_price}}">¥
                            {{#if @root.vipPrice1}}{{round vip1_price}}{{/if}}
                            {{#if @root.vipPrice2}}{{round vip2_price}}{{/if}}
                            {{#if @root.vipPrice3}}{{round vip3_price}}{{/if}}
                        </span>
                    {{else}}
                        <span class="sale-price {{^market_price}}no-price{{/market_price}}">¥{{round sales_price}}</span>
                    {{/if}}
                    {{#market_price}}
                        <span class="market-price">¥{{round .}}</span>
                    {{/market_price}}
                </div>
                {{#if @root.saleVip}}
                    <div class="vip-info">
                        <i class="vip-icon"></i>更优惠
                    </div>
                {{/if}}
                {{#if similar}}
                <a class="similar-btn iconfont">&#xe606;</a>
                {{/if}}
            </div>
        </div>
    {{/if}}
{{/if}}