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.
56 lines
2.1 KiB
56 lines
2.1 KiB
{layout name="layout" /}
|
|
<div class="sec-user clearfix">
|
|
<div class="content">
|
|
<div class="user-detail">
|
|
<div class="detail-edit">
|
|
<div class="body">
|
|
<div class="body-content clearfix">
|
|
{if condition="count($showlist)"}
|
|
{foreach name="showlist" item="vo"}
|
|
<div class="item-jifen" {if condition="isset($my) and $my eq 1"}onclick="window.location.href='{:url('market_detail',['id'=>$vo['id']])}'" style="cursor:pointer"{/if}>
|
|
<div class="item-wrapper">
|
|
<h2 class="title">{$vo.name}</h2>
|
|
<div class="info">{$vo.description}</div>
|
|
<div class="func">
|
|
<small>{$vo.redeem_point}积分</small>
|
|
{if condition="isset($my) and $my eq 1"}
|
|
<div class="dinline">已兑换</div>
|
|
{else}
|
|
<div data-id="{$vo.id}" style="cursor:pointer;border:1px solid #ccc;border-radius:3px;padding:1px 5px;" class="dinline change">兑换</div>
|
|
{/if}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/foreach}
|
|
{/if}
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
<div class="user-caidan">
|
|
{include file="public:userinfo" /}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<script>
|
|
$(function(){
|
|
$(".change").each(function(){
|
|
$(this).click(function(){
|
|
var url="{:url('redeem')}";
|
|
var id=$(this).data('id');
|
|
if(typeof id=='undefined'||id==''){
|
|
layer.msg("缺少id");
|
|
return false;
|
|
}
|
|
layer.load(1, {shade: [0.1,'#fff']});
|
|
$.get(url,{id:id},function(data){
|
|
layer.closeAll();
|
|
if(typeof data.message!='undefined'){
|
|
layer.msg(data.message);
|
|
}
|
|
});
|
|
});
|
|
});
|
|
});
|
|
</script>
|