<!--商品列表BEGIN-->     
<style type="text/css">
#box{background: #FFF;width: 238px;height: 410px;margin: -390px 0 0 0;display: block;border: solid 4px #D93600;position: absolute;z-index: 999;opacity: .5}
.shopMenu{position: fixed;z-index: 1;right: 25%;top: 0;}
</style>
<div class="squares" nc_type="current_display_mode">
    <input type="hidden" id="lockcompare" value="unlock" />
  <?php if(!empty($goods_list) && is_array($goods_list)){?>
  <ul class="list_pic">
    <?php foreach($goods_list as $value){?>
    <li class="item">
      <div class="goods-content" nctype_goods=" <?php echo $value['goods_id'];?>" nctype_store="<?php echo $value['store_id'];?>">
        <div class="goods-pic"><a href="{:url('/Home/Goods/index',['goods_id'=>$value.goods_id])}" target="_blank" title="<?php echo $value['goods_name'];?>"><img class="lazyload" data-original="<?php echo thumb($value, 240);?>" title="<?php echo $value['goods_name'];?>" src="{$Think.config.url_domain_root}static/home/images/loading.gif" alt="<?php echo $value['goods_name'];?>" /></a></div>
        <?php if (config('groupbuy_allow') && $value['goods_promotion_type'] == 1) {?>
        <div class="goods-promotion"><span>抢购商品</span></div>
        <?php } elseif (config('promotion_allow') && $value['goods_promotion_type'] == 2)  {?>
        <div class="goods-promotion"><span>限时折扣</span></div>
        <?php }?>
        <div class="goods-info">
          <div class="goods-pic-scroll-show">
            <ul>
            <?php if(!empty($value['image'])) {?>
              <?php $i=0;foreach ($value['image'] as $val) { $i++; ?>
              <li<?php if($i==1) {?> class="selected"<?php }?>><a href="javascript:void(0);"><img class="lazyload" data-original="<?php echo thumb($val, 60);?>" src="{$Think.config.url_domain_root}static/home/images/loading.gif" /></a></li>
              <?php }?>
            <?php } else {?>
              <li class="selected"><a href="javascript:void(0);"><img class="lazyload" data-original="<?php echo thumb($value, 60);?>" src="{$Think.config.url_domain_root}static/home/images/loading.gif" /></a></li>
            <?php }?>
            </ul>
          </div>
          <div class="goods-name"><a href="{:url('/Home/Goods/index',['goods_id'=>$value.goods_id])}" target="_blank" title="<?php echo $value['goods_jingle'];?>"><?php echo $value['goods_name_highlight'];?><em><?php echo $value['goods_jingle'];?></em></a></div>
          <div class="goods-price"> <em class="sale-price" title="{$Think.lang.goods_class_index_store_goods_price}{$Think.lang.ds_colon}{$Think.lang.currency}<?php echo $value['goods_promotion_price'];?>"><?php echo dsPriceFormatForList($value['goods_promotion_price']);?></em> <em class="market-price" title="市场价：{$Think.lang.currency}<?php echo $value['goods_marketprice'];?>"><?php echo dsPriceFormatForList($value['goods_marketprice']);?></em> <span class="raty" data-score="<?php echo $value['evaluation_good_star'];?>"></span> </div>
          <div class="goods-sub">
            <?php if ($value['is_virtual'] == 1) {?>
            <span class="virtual" title="虚拟兑换商品">虚拟兑换</span>
            <?php }?>
            <?php if ($value['is_fcode'] == 1) {?>
            <span class="fcode" title="F码优先购买商品">F码优先</span>
            <?php }?>
            <?php if ($value['is_presell'] == 1) {?>
            <span class="presell" title="预售购买商品">预售</span>
            <?php }?>
            <?php if ($value['have_gift'] == 1) {?>
            <span class="gift" title="捆绑赠品">赠品</span>
            <?php }?>
            <span class="goods-compare" nc_type="compare_<?php echo $value['goods_id'];?>" data-param='{"gid":"<?php echo $value['goods_id'];?>"}'><i></i>加入对比</span> </div>
          <div class="sell-stat">
            <ul>
              <li><a href="{:url('/Home/Goods/index',['goods_id'=>$value.goods_id])}#ncGoodsRate" target="_blank" class="status"><?php echo $value['goods_salenum'];?></a>
                <p>商品销量</p>
              </li>
              <li><a href="{:url('/Home/Goods/comments_list',['goods_id'=>$value.goods_id])}" target="_blank"><?php echo $value['evaluation_count'];?></a>
                <p>用户评论</p>
              </li>
              <li><em member_id="<?php echo $value['member_id'];?>">&nbsp;</em></li>
            </ul>
          </div>
          <div class="store"><a href="{:url('/Home/Store/index',['store_id'=>$value.store_id])}" title="<?php echo $value['store_name'];?>" class="name"><?php echo $value['store_name'];?></a></div>
          <div class="add-cart">
            <?php if ($value['goods_storage'] == 0) {?>
            <?php if ($value['is_appoint'] == 1) {?>
            <a href="javascript:void(0);" onclick="<?php if (session('is_login') !== '1'){?>login_dialog();<?php }else{?>ajax_form('arrival_notice', '立即预约', '{:url('/Home/Goods/arrival_notice',['goods_id'=>$value.goods_id,'type'=>'2'])}', 350);<?php }?>"><i class="icon-bullhorn"></i>立即预约</a>
            <?php } else {?>
            <a href="javascript:void(0);" onclick="<?php if (session('is_login') !== '1'){?>login_dialog();<?php }else{?>ajax_form('arrival_notice', '到货通知', '{:url('/Home/Goods/arrival_notice',['goods_id'=>$value.goods_id,'type'=>'2'])}', 350);<?php }?>"><i class="icon-bullhorn"></i>到货通知</a>
            <?php }?>
            <?php } else {?>
            <?php if ($value['is_virtual'] == 1 || $value['is_fcode'] == 1 || $value['is_presell'] == 1) {?>
            <a href="javascript:void(0);" nctype="buy_now" data-param="{goods_id:<?php echo $value['goods_id'];?>}"><i class="icon-shopping-cart"></i>
            <?php if ($value['is_fcode'] == 1) {?>
            F码购买
            <?php } else if ($value['is_presell'] == 1) {echo '预售购买';} else {?>
            立即购买
            <?php }?>
            </a>
            <?php } else {?>
            <a href="javascript:void(0);" nctype="add_cart" data-param="{goods_id:<?php echo $value['goods_id'];?>}"><i class="icon-shopping-cart"></i>加入购物车</a>
            <?php }?>
            <?php }?>
          </div>
        </div>
      </div>
    </li>
    <?php }?>
    <div class="clear"></div>
  </ul>
  <?php }else{?>
  <div id="no_results" class="no-results"><i></i>{$Think.lang.index_no_record}</div>
  <?php }?>
</div>
<form id="buynow_form" method="post" action="{:url('/Home/Buy/buy_step1')} ">
  <input id="goods_id" name="cart_id[]" type="hidden"/>
</form>
<script type="text/javascript" src="{$Think.config.url_domain_root}static/plugins/js/jquery.raty/jquery.raty.min.js"></script>
<script type="text/javascript" src="{$Think.config.url_domain_root}static/home/js/compare.js"></script>
<script type="text/javascript">
    $(document).ready(function(){
        $('.raty').raty({
            path: "{$Think.config.url_domain_root}static/plugins/js/jquery.raty/img",
            readOnly: true,
            width: 80,
            score: function() {
              return $(this).attr('data-score');
            }
        });
      	//初始化对比按钮
        initCompare();
    });
</script> 
<!--商品列表END-->     
        