list.html 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. <include file="Public:header"/>
  2. <script type="text/javascript" src="__PUBLIC__/layer/laydate/laydate.js"></script>
  3. <div id="main-content">
  4. <div id="top-alert" class="fixed alert alert-error" style="display: none;">
  5. <button class="close fixed" style="margin-top: 4px;">&times;</button>
  6. <div class="alert-content">警告内容</div>
  7. </div>
  8. <div id="main" class="main">
  9. <div class="main-title-h" style="font-size: 24px;">
  10. <span class="h1-title">{$title|htmlspecialchars}</span>
  11. <if condition="$suggest">({$suggest|htmlspecialchars})</if>
  12. <present name="Think.get.name">
  13. 11<i class="ca"></i>[<a href="{$titleList['url']}"> {$titleList['title']|htmlspecialchars}</a> ]
  14. </present>
  15. </div>
  16. <div class="cf">
  17. <div class="fl">
  18. <present name="buttonList['add']">
  19. <a class="btn add-btn btn-success" href="{$buttonList['add']['url']}">{$buttonList['add']['title']}</a>
  20. </present>
  21. <present name="buttonList['resume']">
  22. <button class="btn ajax-post btn-info" url="{$buttonList['resume']['url']}" target-form="ids">{$buttonList['resume']['title']}</button>
  23. </present>
  24. <present name="buttonList['forbid']">
  25. <button class="btn ajax-post btn-warning" url="{$buttonList['forbid']['url']}" target-form="ids">{$buttonList['forbid']['title']}</button>
  26. </present>
  27. <present name="buttonList['delete']">
  28. <button class="btn ajax-post confirm delete-btn btn-danger" url="{$buttonList['delete']['url']}" target-form="ids">{$buttonList['delete']['title']}</button>
  29. </present>
  30. </div>
  31. <div class="search-form fr cf">
  32. <div class="sleft">
  33. <form action="{$searchPostUrl||default='__SELF__'}" name="formSearch" id="formSearch" method="get" name="form1">
  34. <volist name="searches" id="search">
  35. <if condition="$search['type'] == 'select'">
  36. <select size="1" name="{$search['name']}" class="search-input form-control form-input-width" style="height: 32px; font-size: 14px; width: 110px; float: left; margin-right: 5px;" name="field">
  37. <volist name="search['attr']" id="svo">
  38. <php>$search_name=isset($_GET[$search['name']])?$_GET[$search['name']]:''</php>
  39. <option value="{$key}"
  40. <eq name="key" value="$search_name">selected</eq>
  41. >{$svo}</option>
  42. </volist>
  43. </select>
  44. <elseif condition="$search['type'] == 'time'"/>
  45. <input type="text" class="search-input input-1x" name="{$search.name}" value="{:I($search['name'])}" placeholder="{$search.attr}" onclick="laydate({istime: true, format: 'YYYY-MM-DD hh:mm:ss'})"></td>
  46. <else/>
  47. <input type="text" name="{$search.name}" class="search-input" value="{:I($search['name'])}" placeholder="{$search.attr}" style="width: 150px">
  48. <a class="sch-btn" href="javascript:;" id="search"> <i class="btn-search"></i> </a></if>
  49. </volist>
  50. </form>
  51. <script>
  52. //搜索功能
  53. $(function () {
  54. $('#search').click(function () {
  55. $('#formSearch').submit();
  56. });
  57. });
  58. //回车搜索
  59. $(".search-input").keyup(function (e) {
  60. if (e.keyCode === 13) {
  61. $("#search").click();
  62. return false;
  63. }
  64. });
  65. </script>
  66. </div>
  67. </div>
  68. </div>
  69. <!-- 数据表格 -->
  70. <if condition="$keyList">
  71. <div class="data-table table-striped">
  72. <table class="">
  73. <thead>
  74. <tr>
  75. <th class="row-selected row-selected"><input class="check-all" type="checkbox"/></th>
  76. <volist name="keyList" id="field">
  77. <th>{$field.title|htmlspecialchars}</th>
  78. </volist>
  79. </tr>
  80. </thead>
  81. <tbody>
  82. <notempty name="list">
  83. <volist name="list" id="e">
  84. <tr>
  85. <td><input class="ids" type="checkbox" name="id[]" value="{$e['id']}"/></td>
  86. <volist name="keyList" id="field">
  87. <td class="text-ellipsis">{$e[$field['name']]}</td>
  88. </volist>
  89. </tr>
  90. </volist>
  91. <else/>
  92. <td colspan="12" class="text-center empty-info"><i class="glyphicon glyphicon-exclamation-sign"></i>暂无数据</td>
  93. </notempty>
  94. </tbody>
  95. </table>
  96. <div class="page">
  97. <div>{$pagination}</div>
  98. </div>
  99. </div>
  100. </if>
  101. </div>
  102. </div>
  103. <include file="Public:footer"/>