You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
57 lines
2.0 KiB
57 lines
2.0 KiB
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<a class="cart-mini" href="flow.php">
|
|
<i class="iconfont"></i>
|
|
購物車
|
|
<span class="mini-cart-num J_cartNum" id="hd_cartnum">({$number})</span>
|
|
</a>
|
|
<div id="J_miniCartList" class="cart-menu">
|
|
<!--{if $cart_list}-->
|
|
<ul>
|
|
<!--{foreach from=$cart_list item=goods name=ioo}-->
|
|
<li class="clearfix <!-- {if $smarty.foreach.ioo.first} -->first<!-- {/if} -->">
|
|
<div class="cart-item">
|
|
<a class="thumb" target="_blank" href="{$goods.url}">
|
|
<img src="{if $goods.goods_thumb eq 'package_img'}themes/<?php echo $GLOBALS['_CFG']['template']; ?>/images/ico_cart_package.gif{else}{$goods.goods_thumb}{/if}">
|
|
</a>
|
|
<a class="name" target="_blank" href="{$goods.url}">{$goods.short_name}</a>
|
|
<span class="price">{$goods.shop_price}元 x {$goods.goods_number}</span>
|
|
<a class="btn-del delItem" href="javascript:deleteCartGoods({$goods.rec_id});">
|
|
<i class="iconfont"></i>
|
|
</a>
|
|
</div>
|
|
</li>
|
|
<!--{/foreach}-->
|
|
</ul>
|
|
<div class="count clearfix">
|
|
<span class="total">
|
|
<strong>合計:<em id="hd_cart_total">{$amount}元</em></strong>
|
|
</span>
|
|
<a class="btnprimary" href="flow.php">去購物車結算</a>
|
|
</div>
|
|
<!--{else}-->
|
|
<p class="loading_top">購物車中還沒有商品,趕緊選購吧!</p>
|
|
<!--{/if}-->
|
|
</div>
|
|
<script type="text/javascript">
|
|
function deleteCartGoods(rec_id)
|
|
{
|
|
Ajax.call('delete_cart_goods.php', 'id='+rec_id, deleteCartGoodsResponse_top, 'POST', 'JSON');
|
|
}
|
|
|
|
/**
|
|
* 接收返回的信息
|
|
*/
|
|
function deleteCartGoodsResponse_top(res)
|
|
{
|
|
if (res.error)
|
|
{
|
|
alert(res.err_msg);
|
|
}
|
|
else
|
|
{
|
|
$('.ECS_CARTINFO').html(res.content);
|
|
$('.cart-panel-content').height($(window).height()-90);
|
|
$("#ECS_CARTINFO_TOP").html(res.content_top);
|
|
}
|
|
}
|
|
</script> |