|
@@ -10,64 +10,39 @@
|
|
|
<table class="layui-table margin-top-20" lay-skin="line">
|
|
|
<thead>
|
|
|
<tr>
|
|
|
- <th class='list-table-check-td think-checkbox'><input data-auto-none data-check-target='.list-check-box' type='checkbox'></th>
|
|
|
<th class='list-table-sort-td'><button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button></th>
|
|
|
- <th class='text-left nowrap' style="width: 40%">分类名称</th>
|
|
|
+ <th class='text-left nowrap'>分类名称</th>
|
|
|
<th class='text-left nowrap'>LOGO</th>
|
|
|
- <th class="text-left" style="width: 20%">操作</th>
|
|
|
+ <th class="text-left" style="width: 30%">操作</th>
|
|
|
</tr>
|
|
|
</thead>
|
|
|
- </table>
|
|
|
-
|
|
|
- {foreach $list as $key=>$vo}
|
|
|
- <table class="layui-table margin-top-10" lay-skin="line">
|
|
|
- <thead>
|
|
|
+ <tbody>
|
|
|
+ {foreach $list as $key=>$vo}
|
|
|
<tr>
|
|
|
- <th class='list-table-check-td think-checkbox'><input class="list-check-box" value='{$vo.id}' type='checkbox'></th>
|
|
|
- <th class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></th>
|
|
|
- <th class='text-left nowrap' style="width: 40%">{$vo.title|default=''}</th>
|
|
|
- <th class='text-left nowrap' ><img data-tips-image="{$vo.logo|default=''}" src="{$vo.logo|default=''}" width="35px"/></th>
|
|
|
|
|
|
- <th class='text-left' style="width: 20%">
|
|
|
+ <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
|
|
|
+ <td class='text-left nowrap'>{$vo.title|default=''}</td>
|
|
|
+ <td class='text-left nowrap'><img data-tips-image="{$vo.logo|default=''}" src="{$vo.logo|default=''}" width="50px"></td>
|
|
|
+ <td class='text-left' style="width: 20%">
|
|
|
<a data-title="编辑分类" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
|
|
|
+ <a data-title="商品管理" class="layui-btn layui-btn-sm layui-btn-normal" data-open='{:url("/mall/gift_goods/index")}?id={$vo.id}'>商品管理</a>
|
|
|
{if $vo.status == 1}
|
|
|
<span class="layui-btn layui-btn-sm layui-btn-warm" onclick="btn_confirm('禁用','forbidden','{$vo.id}');" >禁 用</span>
|
|
|
{else}
|
|
|
<span class="layui-btn layui-btn-sm layui-btn-sm" onclick="btn_confirm('启用','enable','{$vo.id}');">启 用</span>
|
|
|
{/if}
|
|
|
<span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','del','{$vo.id}');">删 除</span>
|
|
|
- <a data-title="添加" class="layui-btn layui-btn-sm" data-modal='{:url("add")}?pid={$vo.id}'>添加</a>
|
|
|
- </th>
|
|
|
- </tr>
|
|
|
- </thead>
|
|
|
- {foreach $vo['children'] as $ck=>$cv}
|
|
|
- <tbody>
|
|
|
- <tr>
|
|
|
- <td class='list-table-check-td think-checkbox'></td>
|
|
|
- <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$cv.id};action#sort;sort#{value}" data-loading="false" value="{$cv.sort}" class="list-sort-input"></td>
|
|
|
- <td class='text-left nowrap' style="width: 40%">|-- {$cv.title|default=''}</td>
|
|
|
- <td class='text-left nowrap' ><img data-tips-image="{$cv.logo|default=''}" src="{$cv.logo|default=''}" width="35px"/></td>
|
|
|
- <td class='text-left nowrap'>
|
|
|
- <a data-title="编辑分类" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$cv.id}&pid={$cv.pid}'>编 辑</a>
|
|
|
- {if $cv.status == 1}
|
|
|
- <span class="layui-btn layui-btn-sm layui-btn-warm" onclick="btn_confirm('禁用','forbidden','{$cv.id}');" >禁 用</span>
|
|
|
- {else}
|
|
|
- <span class="layui-btn layui-btn-sm layui-btn-sm" onclick="btn_confirm('启用','enable','{$cv.id}');">启 用</span>
|
|
|
- {/if}
|
|
|
- <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','del','{$cv.id}');">删 除</span>
|
|
|
</td>
|
|
|
</tr>
|
|
|
- </tbody>
|
|
|
{/foreach}
|
|
|
+ </tbody>
|
|
|
</table>
|
|
|
- {/foreach}
|
|
|
-
|
|
|
{empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
|
|
|
</div>
|
|
|
<script>
|
|
|
function btn_confirm(msg,fun,id) {
|
|
|
layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
|
|
|
- var url = "/mall/video_cate/"+fun;
|
|
|
+ var url = "/nutrition/video_cate/"+fun;
|
|
|
layer.closeAll();
|
|
|
$.ajax({
|
|
|
type: "post",
|