|
@@ -43,9 +43,11 @@
|
|
|
<th class="text-center">优惠券最低消费</th>
|
|
|
<th class="text-center">优惠券开始使用时间</th>
|
|
|
<th class="text-center">优惠券结束使用时间</th>
|
|
|
+ <th class="text-center">优惠券使用时间</th>
|
|
|
<th class="text-center">获取放方式</th>
|
|
|
<th class="text-center">是否可用</th>
|
|
|
<th class="text-center">状态</th>
|
|
|
+ <th class="text-center">操作</th>
|
|
|
</tr>
|
|
|
</thead>
|
|
|
<tbody class="">
|
|
@@ -83,6 +85,15 @@
|
|
|
{$vo.end_time|date='Y-m-d H:i:s'}
|
|
|
{/if}
|
|
|
|
|
|
+ </td>
|
|
|
+ <td class="text-center">
|
|
|
+ {if ($vo.use_time == 0)}
|
|
|
+ 未使用
|
|
|
+ {/if}
|
|
|
+ {if ($vo.use_time > 0)}
|
|
|
+ {$vo.use_time|date='Y-m-d H:i:s'}
|
|
|
+ {/if}
|
|
|
+
|
|
|
</td>
|
|
|
<td class="text-center">
|
|
|
{$vo.type == 'send' ? '后台发放' : '手动领取'}
|
|
@@ -103,6 +114,9 @@
|
|
|
未使用
|
|
|
{/if}
|
|
|
</td>
|
|
|
+ <td class="text-center">
|
|
|
+ <button style="margin-top: 5px;" class="btn btn-danger btn-xs del_news_one" data-id="{$vo.id}" type="button" data-url="{:Url('delete',array('id'=>$vo['id']))}" ><i class="fa fa-times"></i> 删除</button>
|
|
|
+ </td>
|
|
|
</tr>
|
|
|
{/volist}
|
|
|
</tbody>
|
|
@@ -114,3 +128,24 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
{/block}
|
|
|
+{block name="script"}
|
|
|
+<script>
|
|
|
+
|
|
|
+ $('.del_news_one').on('click',function(){
|
|
|
+ window.t = $(this);
|
|
|
+ var _this = $(this),url =_this.data('url');
|
|
|
+ $eb.$swal('delete',function(){
|
|
|
+ $eb.axios.get(url).then(function(res){
|
|
|
+ console.log(res);
|
|
|
+ if(res.status == 200 && res.data.code == 200) {
|
|
|
+ $eb.$swal('success',res.data.msg);
|
|
|
+ _this.parents('tr').remove();
|
|
|
+ }else
|
|
|
+ return Promise.reject(res.data.msg || '删除失败')
|
|
|
+ }).catch(function(err){
|
|
|
+ $eb.$swal('error',err);
|
|
|
+ });
|
|
|
+ })
|
|
|
+ });
|
|
|
+</script>
|
|
|
+{/block}
|