<{uqcms m="shop" c="get_one:smarty.get.id" v="shop"}> 
<{import file="common.html" title=$shop.name}>
<link rel="stylesheet" type="text/css" href="<{$__APP__}>public/css/index.css"/> 
<link rel="stylesheet" type="text/css" href="<{$__APP__}>public/css/shop.css"/> 
<div class="shead">
	<div class="splogo">
		<div class="lo"><a href=""><img src="<{$__IMG__}><{$shop.logo|img_size:60x60}>"></a></div>
		<div class="r">
			<div class="name"><{$shop.name}></div>
			<div class="fans"><span>粉丝</span><i><{$shop.collect}></i></div>
		</div>
	</div>
	<div class="other">
		<a href="javascript:;" class="collect_shop" data-spid="<{$smarty.get.id}>"><{if $shop.collect_status}>已经收藏<{else}>店铺收藏<{/if}></a>
	</div>
</div> 
<{uqcms m="goods" v="data" c="shop_goods:shop_id=smarty.get.id&group_cid=smarty.get.group_cid&page=smarty.get.page&sort=smarty.get.sort"}>
<div class="sp_cats">
	<a href="?m=shop&id=<{$smarty.get.id}>" <{if $smarty.get.sort ==''}>class="ch"<{/if}>><em><{$data.count.total}></em><span>全部商品</span></a>
	<a href="?m=shop&id=<{$smarty.get.id}>&sort=new" <{if $smarty.get.sort =='new'}>class="ch"<{/if}>><em><{$data.count.new}></em><span>商品上新</span></a>
	<a href="?m=shop&id=<{$smarty.get.id}>&sort=sps" <{if $smarty.get.sort =='sps'}>class="ch"<{/if}>><em><{$data.count.sps}></em><span>活动促销</span></a>
</div> 
<div class="hot_box">
	<div class="hot_con"> 
		<{if $data.list}>
			<{foreach item=i from=$data.list}>		
				<div class="gs_box">
					<div class="img"><a href="?m=goods&a=detail&id=<{$i.id}>"><img data-original="<{$__IMG__}><{$i.images|img_size:200x200}>" class="lazy"/></a></div>
					<div class="con">
						<div class="ttl"><a href="?m=goods&a=detail&id=<{$i.id}>"><{$i.title}></a></div> 
						<div class="pr">
							<{if $i.act_status == '1'}><span class="cx">促</span><{/if}>
							<i>¥</i> 
							<em><{$i.price}></em> 
						</div> 
					</div> 
				</div>
			<{/foreach}> 
			<{else}>
				<div class="nomsg"><span>暂无产品</span></div>
		<{/if}>
	</div> 
</div>
 
<{uqcms m="goods" v="group" c="group:"|cat:$smarty.get.id}> 
<div class="btm_nav">
	<ul>
		<li><a href="wap.php?m=shop&a=detail&shop_id=<{$smarty.get.id}>" class=""><span>店铺详情</span></a></li>
		<li class="nav_menu">
			<a href="javascript:;"><span>热门分类</span></a>
			<dl>
				<{foreach item=i from=$group}>
					<dd><a href="wap.php?m=shop&id=<{$smarty.get.id}>&group_cid=<{$i.id}>"><span><{$i.name}></span></a></dd>
				<{/foreach}>
			</dl>
		</li> 
		<li><a href="javascript:;" class="on"><span>联系卖家</span></a></li> 
	</ul>
</div> 
 
<{include file="default/footer.html"}>
<script type="text/javascript" src="<{$__PUBLIC__}>js/jquery.lazyload.js"></script>  
<script type="text/javascript">
$(function(){
	$("img.lazy").lazyload({effect: "fadeIn"});
	$(".gs_box .img").css('height',$('.gs_box .img').width()); 
	// 店铺收藏 
	$(".collect_shop").click(function(){ 
		$this = $(this);
		spid = $this.attr('data-spid');
		$.post("index.php?m=ajax&a=collect_shop",{spid: spid},function(result){ 
			var data = jQuery.parseJSON(result);  
			if(data.error == '0'){
				if(data.status == '2'){ 
					location.href="wap.php?m=member&a=login&returnUrl=<{$UQCMS.request_url}>";
				}else if(data.status == '1'){
					$this.html('已经收藏');
				}else if(data.status == '0'){
					$this.html('店铺收藏');
				}
			}else{
				$.alert(data.msg);
			} 
		}); 
		return false;
	});
	$(".nav_menu").click(function(e){
		$(this).children('dl').show(); 
		e.stopPropagation();
	});
	$(document).click(function(){ 
		$(".nav_menu").children('dl').hide();
	});
	
}); 
</script>