文件

203 行
5.2 KiB
HTML
可执行文件

<!--[1.7.90]-->
<style type="text/css">
.card_b {
width: 100%;
height: 50px;
display: flex;
align-items: center;
justify-content: flex-end;
box-sizing: border-box;
padding: 0 30px;
background: #ebebeb;
}
.card_b a {
width: 100px;
height: 30px;
text-align: center;
line-height: 30px;
font-size: 14px;
background: #009688;
border-radius: 5px;
text-decoration: none;
color: white;
}
.kaquan_c {
margin-top: 10px;
box-sizing: border-box;
border: 1px solid #ddd;
}
.kaquan_c01 {
width: 100%;
height: 40px;
display: flex;
align-items: center;
font-size: 14px;
background: #ebebeb;
}
.kaquan_c01_a {
width: 30%;
text-align: center;
}
.kaquan_c01_b {
width: 20%;
box-sizing: border-box;
padding: 0 5px;
}
.kaquan_c01_c {
width: 20%;
box-sizing: border-box;
padding: 0 5px;
}
.kaquan_c01_h {
width: 30%;
box-sizing: border-box;
padding: 0 5px;
text-align: center;
}
.kaquan_c02 {
width: 100%;
height: 80px;
display: flex;
align-items: center;
font-size: 14px;
}
.kaquan_c02:hover {
background: #f8f8f8;
}
.kaquan_c02_a {
width: 30%;
text-align: center;
font-size: 18px;
}
.kaquan_c02_b {
width: 20%;
box-sizing: border-box;
padding: 0 5px;
}
.kaquan_c02_c {
width: 20%;
box-sizing: border-box;
padding: 0 5px;
}
.kaquan_c02_h {
width: 30%;
box-sizing: border-box;
padding: 0 5px;
display: flex;
align-items: center;
justify-content: center;
}
.kaquan_c02_h a {
box-sizing: border-box;
padding: 5px 0;
border: 1px solid #009688;
color: #009688;
border-radius: 4px;
font-size: 14px;
margin: 0 5px;
min-width: 80px;
text-align: center;
cursor: pointer;
text-decoration: none;
}
.kaquan_c02_h a:hover {
background: #009688;
color: white;
}
</style>
<div class="listbox">
<empty name="info">
<div class="card_b">
<if condition="$authArr['addMemberCardShow'] eq true">
<a href="javacript:void(0);" id="add">新增会员卡</a>
</if>
</div>
</empty>
<div class="kaquan_c">
<div class="kaquan_c01">
<div class="kaquan_c01_a">卡名称</div>
<div class="kaquan_c01_b">制作日期</div>
<div class="kaquan_c01_c">领取人数(人)</div>
<div class="kaquan_c01_h">操作</div>
</div>
<if condition="isset($info)">
<div class="kaquan_c02">
<div class="kaquan_c02_a">{$info['title']}</div>
<div class="kaquan_c02_b">{$info['time']}</div>
<div class="kaquan_c02_c">{$info['closure']}</div>
<input type="hidden" id="idd" value="{$info['id']}">
<div class="kaquan_c02_h">
<if condition="$authArr['addMemberCardShow'] eq true">
<!-- <a class="kaquan_c02_h01" href="{:U('/Retail/VipCard/addMemberCardShow',array('id'=>$info['id']))}">编辑</a>-->
<a class="kaquan_c02_h01" href="javacript:void(0);" id="edit">编辑</a>
</if>
<if condition="$authArr['deleteCard'] eq true">
<a class="kaquan_c02_h02" id="delete_id">删除</a>
</if>
</div>
</div>
</if>
</div>
</div>
<script type="text/javascript">
var idd = $('#idd').val();
$('#delete_id').click(function () {
$.ajax({
url: "{:U('deleteCard')}",
type: "POST",
data: {'id': idd},
success: function (data) {
if (data.status == 1) {
top.layer.msg(data.mesg, {icon: 1, time: 5000}, function () {
MenuApp.refreshWindow(true);
})
} else {
top.layer.msg(data.mesg, {icon: 1, time: 3000})
}
}
})
})
$('#add').click(function () {
layer.open({
type: 2,
title: '新增微信会员卡',
area: ['calc(100% - 160px)', 'calc(100% - 65px)'],
offset: 'rb',
shade: 0,
content: "{:U('/Retail/VipCard/create')}",
end: function () {
MenuApp.refreshWindow(true);
}
});
})
$('#edit').click(function () {
layer.open({
type: 2,
title: '编辑微信会员卡',
area: ['calc(100% - 160px)', 'calc(100% - 65px)'],
offset: 'rb',
content: "{:U('/Retail/VipCard/addMemberCardShow',array('id'=>$info['id']))}",
end: function () {
MenuApp.refreshWindow(true);
}
});
})
</script>