{extend name="$base" /} {block name="resources"}
{/block} {block name="head"}{/block} {block name="main"} {php} $page_layout = api("System.Config.wapPageLayout"); $page_layout = $page_layout['data']; if(empty($page_layout)){ $page_layout = array( [ "tag" => "banner", "isVisible" => true ], [ "tag" => "search", "isVisible" => true ], [ "tag" => "nav", "isVisible" => true ],[ "tag" => "notice", "isVisible" => true ], [ "tag" => "coupons", "isVisible" => true ], [ "tag" => "games", "isVisible" => true ], [ "tag" => "discount", "isVisible" => true ], [ "tag" => "spell-bargain", "isVisible" => true ], [ "tag" => "spell-group", "isVisible" => true ], [ "tag" => "goods", "isVisible" => true ], [ "tag" => "cube", "isVisible" => true ], [ "tag" => "bottom", "isVisible" => true ]); } //WAP端首页浮层 $wap_floating = api('System.Shop.wapFloating'); $wap_floating = $wap_floating['data']; {/php} {notempty name="$wap_floating"} {if condition="$wap_floating['is_show'] == 1"}
{/if} {/notempty}
{foreach name="$page_layout" item="vo" key="k"} {if condition="$vo['tag']=='banner'"} {if condition="$vo['isVisible']"} {php} $plat_adv_list = api("System.Shop.advDetail",['ap_keyword' => 'WAP_INDEX_SWIPER', 'export_type' => 'data']); {/php} {notempty name="$plat_adv_list['data']"}
{foreach name="$plat_adv_list['data']['advs']" item="vo"}
{if is_url($vo['adv_url'])} {else/} {/if}
{/foreach}
{/notempty} {/if} {elseif condition="$vo['tag']=='search'"} {if condition="$vo['isVisible']"}
{/if} {elseif condition="$vo['tag']=='nav'"} {if condition="$vo['isVisible']"} {php} $navigation_list = api("System.Shop.shopNavigationList",['page_index'=>1,'page_size'=>0,'type'=>2,'is_show'=>1,'order' => 'sort desc']); $navigation_list = $navigation_list['data']['data']; {/php} {notempty name="$navigation_list" item="vo"}
{/notempty} {/if} {elseif condition="$vo['tag']=='notice'"} {if condition="$vo['isVisible']"} {php} $notice = api("System.Shop.shopNoticeList"); $notice = $notice['data']['data']; {/php} {notempty name="$notice"}

{foreach name="notice" id="vo"}
- {$vo.notice_title}
{/foreach}

{/notempty} {/if} {elseif condition="$vo['tag']=='coupons'"} {if condition="$vo['isVisible']"} {php} $coupon_list = api("System.Member.canReceiveCouponQuery",['uid'=>$uid]); $coupon_list = $coupon_list['data']; {/php} {notempty name="$coupon_list"}
{volist name="coupon_list" id="vo" } {if condition="$vo.max_fetch == $vo.received_num && $vo.max_fetch != 0"}
￥{$vo['money']}

满{$vo.at_least}可用

已领取
{else/}
￥{$vo['money']}

满{$vo.at_least}可用

领取
{/if} {/volist}
{/notempty} {/if} {elseif condition="$vo['tag']=='games'"} {if condition="$vo['isVisible']"} {php} $game_list = api("System.Promotion.promotionGamesList",['condition'=>['status' => 1,"is_index_show" => 1 ],'order'=>'game_id desc']); $game_list = $game_list['data']; {/php} {notempty name="$game_list['data']"}
{foreach name="$game_list['data']" item="vo"}
{/foreach}
{/notempty} {/if} {elseif condition="$vo['tag']=='discount'"} {if condition="$vo['isVisible']"} {php} $discount_data = api("System.Goods.newestDiscount"); $discount = $discount_data['data']; {/php} {if !empty($discount)}
限时秒杀
0 00 : 00 : 00

{volist name="$discount['goods_list']" id="vo" key = "k"} {if $k lt 3}
- {$vo.goods_name}
  ￥{$vo.promotion_price}
{/if} {/volist}

{/if} {/if} {elseif condition="$vo['tag']=='spell-bargain'"} {if condition="$vo['isVisible']"} {if condition="addon_is_exit('NsBargain') == 1"} {php} $bargain_list = api("NsBargain.Bargain.bargainList",['page_size'=>5]); $bargain_list = $bargain_list['data']; {/php} {notempty name="$bargain_list['data']"}

{foreach name="$bargain_list['data']" item="vo" key="k"}
{/foreach}

{/notempty} {/if} {/if} {elseif condition="$vo['tag']=='spell-group'"} {if condition="$vo['isVisible']"} {if condition="addon_is_exit('NsPintuan') == 1"} {php} $pintuan_list = api("NsPintuan.Pintuan.goodsList",['page_size'=>5,'condition'=> json_encode(['npg.is_open' => 1, 'npg.is_show' => 1]),'order'=>'npg.create_time desc']); $pintuan_list = $pintuan_list['data']; {/php} {notempty name="$pintuan_list['data']"}

{foreach name="$pintuan_list['data']" item="vo" key="k"}
{/foreach}

{/notempty} {/if} {/if} {elseif condition="$vo['tag']=='adv'"} {if condition="$vo['isVisible']"} {/if} {elseif condition="$vo['tag']=='goods'"} {if condition="$vo['isVisible']"} {php} $new_goods_list = api("System.Goods.newGoodsList", ["page_size" => 4]); $new_goods_list = $new_goods_list['data']; {/php} {notempty name="$new_goods_list"}
新品

{foreach name="$new_goods_list" item="list" key='k'}

- {$list.goods_name}

  {in name="$list.point_exchange_type" value="0,2"} ￥{$list.promotion_price} {else/} {if $list['point_exchange_type'] == 1 && $list['promotion_price'] > 0} ￥{$list.promotion_price}+{$list.point_exchange}积分 {else/} {$list.point_exchange}积分 {/if} {/in}
{/foreach}

{/notempty} {php} $recommend_goods_list = api("System.Goods.recommendGoodsList", ["page_size" => 4]); $recommend_goods_list = $recommend_goods_list['data']; {/php} {notempty name="$recommend_goods_list"}
精品

{foreach name="$recommend_goods_list" item="list" key='k'}

- {$list.goods_name}

  {in name="$list.point_exchange_type" value="0,2"} ￥{$list.promotion_price} {else/} {if $list['point_exchange_type'] == 1 && $list['promotion_price'] > 0} ￥{$list.promotion_price}+{$list.point_exchange}积分 {else/} {$list.point_exchange}积分 {/if} {/in}
{/foreach}

{/notempty} {php} $hot_goods_list = api("System.Goods.hotGoodsList", ["page_size" => 4]); $hot_goods_list = $hot_goods_list['data']; {/php} {notempty name="$hot_goods_list"}
热卖
更多 >

{foreach name="$hot_goods_list" item="list" key='k'}

- {$list.goods_name}

  {in name="$list.point_exchange_type" value="0,2"} ￥{$list.promotion_price} {else/} {if $list['point_exchange_type'] == 1 && $list['promotion_price'] > 0} ￥{$list.promotion_price}+{$list.point_exchange}积分 {else/} {$list.point_exchange}积分 {/if} {/in}
{/foreach}

{/notempty} {php} $block_list = api("System.Goods.goodsCategoryBlockWap"); $block_list = $block_list['data']; {/php} {foreach name="$block_list['data']" item="class"} {notempty name="$class['goods_list']"}
{if $class['img']}
{/if}
{$class.recommend_name}

{foreach name="class.goods_list" item="list" key='k'}

- {$list.goods_name}

  {in name="$list.point_exchange_type" value="0,2"} ￥{$list.promotion_price} {else/} {if $list['point_exchange_type'] == 1 && $list['promotion_price'] > 0} ￥{$list.promotion_price}+{$list.point_exchange}积分 {else/} {$list.point_exchange}积分 {/if} {/in}
{/foreach}

{/notempty} {/foreach} {/if} {elseif condition="$vo['tag']=='cube'"} {if condition="$vo['isVisible']"} {php} $magiccube = api("System.Config.wapHomeMagicCube"); $magiccube = $magiccube['data']; {/php} {notempty name="magiccube"}
{if count($magiccube) eq 1}
{if is_url($magiccube[0]['url'])} {else/} {/if}
{elseif count($magiccube) eq 2}
{for start="0" end="2" }
{if is_url($magiccube[$i]['url'])} {else/} {/if}
{/for}
{elseif count($magiccube) eq 3}
{if is_url($magiccube[0]['url'])} {else/} {/if}
{for start="1" end="3" }
{if is_url($magiccube[$i]['url'])} {else/} {/if}
{/for}
{elseif count($magiccube) eq 4}
{if is_url($magiccube[0]['url'])} {else/} {/if}
{if is_url($magiccube[1]['url'])} {else/} {/if}
{for start="2" end="4" }
{if is_url($magiccube[$i]['url'])} {else/} {/if}
{/for}
{/if}
{/notempty} {/if} {/if} {/foreach}
{php} $copyright = api('System.Config.copyRight'); $copyright = $copyright['data']; {/php} {if $copyright['is_load'] > 0} {notempty name="$copyright['bottom_info']['copyright_logo']"} {else/} {/notempty} {notempty name="$copyright['bottom_info']['copyright_companyname']"} {$copyright['bottom_info']['copyright_companyname']} {else/} 山西牛酷信息科技有限公司 提供技术支持 {/notempty} {else/} 山西牛酷信息科技有限公司 提供技术支持 {/if}
{/block} {block name="script"}
{/block}