admin/addon/hongbao/shop/view/hongbao/group_member.html

95 lines
3.0 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{extend name="app/shop/view/base.html"/}
{block name="resources"}
<link rel="stylesheet" href="SHOP_CSS/goods_lists.css">
<style>
.layui-layer-page .layui-layer-content {
padding: 20px 30px;
}
</style>
{/block}
{block name="main"}
<div class="layui-tab ns-table-tab" lay-filter="coupon_tab">
<div class="layui-tab-content">
<!-- 列表 -->
<table id="coupon_list" lay-filter="coupon_list"></table>
</div>
</div>
<!-- 会员 -->
<script type="text/html" id="member_info">
<div class="ns-table-title">
<div class="ns-title-pic">
<img layer-src src="{{ns.img(d.headimg) || ns.img('SHOP_IMG/default_headimg.png')}}" onerror="this.src = 'SHOP_IMG/default_headimg.png' ">
</div>
<div class="ns-title-content">
<a href="javascript:;" class="ns-multi-line-hiding ns-gn-color"
title="{{d.nickname}}">{{d.nickname}}</a>
</div>
</div>
</script>
{/block}
{block name="script"}
<script>
var laytpl;
layui.use(['form', 'laytpl', 'laydate', 'element'], function () {
var table,
form = layui.form,
element = layui.element,
laydate = layui.laydate,
validityType = 0,
repeat_flag = false; //防重复标识
laytpl = layui.laytpl,
form.render();
//监听Tab切换以改变地址hash值
element.on('tab(coupon_tab)', function () {
table.reload({
page: {curr: 1},
where: {'status': this.getAttribute('lay-id')},
})
});
var group_id = {$group_id};
// 券名称、发起时间、已参与人数/需成团人数、成团截止时间、操作(参与人列表)
table = new Table({
elem: '#coupon_list',
page: false,
url: ns.url("hongbao://shop/hongbao/groupMember", {'group_id': group_id}),
cols: [
[{
title: '会员信息',
unresize: 'false',
width: '17%',
templet: '#member_info'
},{
title: '活动内容',
field: 'name',
unresize: 'false',
width: '12%',
templet: function (data) {
return data.divide_num + '人瓜分'+ data.money + '元';
}
},{
title: '瓜分金额',
field: 'coupon_money',
unresize: 'false',
width: '12%',
templet: function (data) {
var content = '';
if(data.balance_money == undefined || data.balance_money == ''){
content = '';
}else{
content = data.balance_money + '元';
}
return content;
}
}]
],
});
});
</script>
{/block}