index.html 4.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. {extend name="../../admin/view/main"}
  2. {block name="button"}
  3. <!--{if auth("synchronize") and $type eq 'index'}-->
  4. <button data-load='{:url("synchronize")}' data-confirm="确定要同步快递公司数据吗?" class='layui-btn layui-btn-sm layui-btn-primary'>同步公司</button>
  5. <!--{/if}-->
  6. <!--{if auth("add") and $type eq 'index'}-->
  7. <button data-modal='{:url("add")}' data-title="添加快递公司" class='layui-btn layui-btn-sm layui-btn-primary'>添加公司</button>
  8. <!--{/if}-->
  9. <!--{if auth("state") and $type eq 'index'}-->
  10. <button data-action='{:url("state")}' data-confirm="确定要禁用快递公司?" data-rule="id#{key};status#0" class='layui-btn layui-btn-sm layui-btn-primary'>批量禁用</button>
  11. <!--{/if}-->
  12. <!--{if auth("state") and $type eq 'recycle'}-->
  13. <button data-action='{:url("state")}' data-rule="id#{key};status#1" class='layui-btn layui-btn-sm layui-btn-primary'>批量启用</button>
  14. <!--{/if}-->
  15. <!--{if auth("remove") and $type eq 'recycle'}-->
  16. <button data-action='{:url("remove")}' data-csrf="{:systoken('remove')}" data-rule="id#{key}" class='layui-btn layui-btn-sm layui-btn-primary'>批量删除</button>
  17. <!--{/if}-->
  18. {/block}
  19. {block name="content"}
  20. <div class="layui-tab layui-tab-card think-bg-white'amount'">
  21. <ul class="layui-tab-title">
  22. {foreach ['index'=>'快递公司','recycle'=>'回 收 站'] as $k=>$v}
  23. {if $type eq $k}
  24. <li data-open="{:url('index')}?type={$k}" class="layui-this">{$v}</li>
  25. {else}
  26. <li data-open="{:url('index')}?type={$k}">{$v}</li>
  27. {/if}{/foreach}
  28. </ul>
  29. <div class="layui-tab-content'amount'">
  30. {include file='shop_truck_company/index_search'}
  31. <table class="layui-table" lay-skin="line">
  32. {notempty name='list'}
  33. <thead>
  34. <tr>
  35. <th class='list-table-check-td think-checkbox'>
  36. <label><input data-auto-none data-check-target='.list-check-box' type='checkbox'></label>
  37. </th>
  38. <th class='list-table-sort-td'>
  39. <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
  40. </th>
  41. <th class='text-left nowrap'>快递名称</th>
  42. <th class='text-center nowrap'>快递鸟接口编码</th>
  43. <th class='text-center nowrap'>快递100百度编码</th>
  44. <th class='text-center nowrap'>快递100接口编码</th>
  45. <th class="text-center">创建时间</th>
  46. <th></th>
  47. </tr>
  48. </thead>
  49. {/notempty}
  50. <tbody>
  51. {foreach $list as $key=>$vo}
  52. <tr data-dbclick>
  53. <td class='list-table-check-td think-checkbox'>
  54. <label><input class="list-check-box" value='{$vo.id}' type='checkbox'></label>
  55. </td>
  56. <td class='list-table-sort-td'>
  57. <label><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"></label>
  58. </td>
  59. <td class='text-left nowrap'>{$vo.name|default=''}</td>
  60. <td class='text-center nowrap'>{$vo.code_1|default='-'}</td>
  61. <td class='text-center nowrap'>{$vo.code_2|default='-'}</td>
  62. <td class='text-center nowrap'>{$vo.code_3|default='-'}</td>
  63. <td class='text-center nowrap'>{$vo.create_at|format_datetime}</td>
  64. <td class='text-left nowrap'>
  65. <!--{if auth("edit") and $type eq 'index'}-->
  66. <a data-dbclick class="layui-btn layui-btn-sm" data-title="编辑快递公司" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
  67. <!--{/if}-->
  68. <!--{if $vo.status eq 1 and auth("state")}-->
  69. <a class="layui-btn layui-btn-warm layui-btn-sm" data-action="{:url('state')}" data-value="id#{$vo.id};status#0">禁 用</a>
  70. <!--{elseif auth("state")}-->
  71. <a class="layui-btn layui-btn-warm layui-btn-sm" data-action="{:url('state')}" data-value="id#{$vo.id};status#1">激 活</a>
  72. <!--{/if}-->
  73. <!--{if auth("remove") and $type eq 'recycle'}-->
  74. <a class="layui-btn layui-btn-danger layui-btn-sm" data-confirm="确定要删除数据吗?" data-action="{:url('remove')}" data-value="id#{$vo.id}">删 除</a>
  75. <!--{/if}-->
  76. </td>
  77. </tr>
  78. {/foreach}
  79. </tbody>
  80. </table>
  81. {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
  82. </div>
  83. </div>
  84. {/block}