index.html 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. {extend name='admin@main'}
  2. {block name="content"}
  3. <div class="think-box-shadow">
  4. <table class="layui-table margin-top-20" lay-skin="line">
  5. <thead>
  6. <tr>
  7. <th class='list-table-check-td think-checkbox'><input data-auto-none data-check-target='.list-check-box' type='checkbox'></th>
  8. <th class='text-left nowrap'>签到类型</th>
  9. <th class="text-left" >累计天数</th>
  10. <th class="text-left" >积分</th>
  11. <th class="text-left" >成长值</th>
  12. <th class="text-left" style="width: 20%">操作</th>
  13. </tr>
  14. </thead>
  15. <tbody>
  16. {foreach $list as $key=>$vo}
  17. <tr>
  18. <td class='list-table-check-td think-checkbox'><input class="list-check-box" value='{$vo.id}' type='checkbox'></td>
  19. <td class='text-left nowrap'>
  20. {if $vo.type == 1}
  21. 每日签到
  22. {else}
  23. 当月累积签到{$vo.day}天
  24. {/if}
  25. </td>
  26. <td class='text-left nowrap'>{$vo.day|default=''}</td>
  27. <td class='text-left nowrap'>{$vo.integral|default=''}</td>
  28. <td class='text-left nowrap'>{$vo.growth|default='0'}</td>
  29. <td class='text-left' style="width: 20%">
  30. <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
  31. </td>
  32. </tr>
  33. {/foreach}
  34. </tbody>
  35. </table>
  36. {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
  37. </div>
  38. <script>
  39. function btn_confirm(msg,fun,id) {
  40. layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
  41. var url = "/store/goods_cate/"+fun;
  42. layer.closeAll();
  43. $.ajax({
  44. type: "post",
  45. url: url,
  46. data: {id:id},
  47. dataType: "json",
  48. async: false,
  49. success: function (data) {
  50. layer.msg(data.info);
  51. setTimeout(function () {
  52. window.location.reload();
  53. },1000)
  54. }
  55. });
  56. });
  57. }
  58. </script>
  59. {/block}