1ad42d3d8849e0cf3613113c7fbcdc8f.php 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  1. <?php /*a:6:{s:76:"D:\phpstudy_pro\WWW\CRMEB\app\admin\view\setting\system_group_data\index.php";i:1595820902;s:61:"D:\phpstudy_pro\WWW\CRMEB\app\admin\view\public\container.php";i:1595820902;s:62:"D:\phpstudy_pro\WWW\CRMEB\app\admin\view\public\frame_head.php";i:1595820902;s:57:"D:\phpstudy_pro\WWW\CRMEB\app\admin\view\public\style.php";i:1595820902;s:62:"D:\phpstudy_pro\WWW\CRMEB\app\admin\view\public\inner_page.php";i:1595820902;s:64:"D:\phpstudy_pro\WWW\CRMEB\app\admin\view\public\frame_footer.php";i:1595820902;}*/ ?>
  2. <!DOCTYPE html>
  3. <html lang="zh-CN">
  4. <head>
  5. <meta charset="utf-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <?php if(empty($is_layui) || (($is_layui instanceof \think\Collection || $is_layui instanceof \think\Paginator ) && $is_layui->isEmpty())): ?>
  8. <link href="/system/frame/css/bootstrap.min.css?v=3.4.0" rel="stylesheet">
  9. <?php endif; ?>
  10. <link href="/static/plug/layui/css/layui.css" rel="stylesheet">
  11. <link href="/system/css/layui-admin.css" rel="stylesheet">
  12. <link href="/system/frame/css/font-awesome.min.css?v=4.3.0" rel="stylesheet">
  13. <link href="/system/frame/css/animate.min.css" rel="stylesheet">
  14. <link href="/system/frame/css/style.min.css?v=3.0.0" rel="stylesheet">
  15. <script src="/system/frame/js/jquery.min.js"></script>
  16. <script src="/system/frame/js/bootstrap.min.js"></script>
  17. <script src="/static/plug/layui/layui.all.js"></script>
  18. <script>
  19. $eb = parent._mpApi;
  20. window.controlle="<?php echo strtolower(trim(preg_replace("/[A-Z]/", "_\\0", app('request')->controller()), "_"));?>";
  21. window.module="<?php echo app('http')->getName();?>";
  22. </script>
  23. <title></title>
  24. <!--<script type="text/javascript" src="/static/plug/basket.js"></script>-->
  25. <script type="text/javascript" src="/static/plug/requirejs/require.js"></script>
  26. <?php /* <script type="text/javascript" src="/static/plug/requirejs/require-basket-load.js"></script> */ ?>
  27. <script>
  28. var hostname = location.hostname;
  29. if(location.port) hostname += ':' + location.port;
  30. requirejs.config({
  31. map: {
  32. '*': {
  33. 'css': '/static/plug/requirejs/require-css.js'
  34. }
  35. },
  36. shim:{
  37. 'iview':{
  38. deps:['css!iviewcss']
  39. },
  40. 'layer':{
  41. deps:['css!layercss']
  42. }
  43. },
  44. baseUrl:'//'+hostname+'/',
  45. paths: {
  46. 'static':'static',
  47. 'system':'system',
  48. 'vue':'static/plug/vue/dist/vue.min',
  49. 'axios':'static/plug/axios.min',
  50. 'iview':'static/plug/iview/dist/iview.min',
  51. 'iviewcss':'static/plug/iview/dist/styles/iview',
  52. 'lodash':'static/plug/lodash',
  53. 'layer':'static/plug/layer/layer',
  54. 'layercss':'static/plug/layer/theme/default/layer',
  55. 'jquery':'static/plug/jquery/jquery.min',
  56. 'moment':'static/plug/moment',
  57. 'sweetalert':'static/plug/sweetalert2/sweetalert2.all.min',
  58. 'formCreate':'/static/plug/form-create/form-create.min',
  59. },
  60. basket: {
  61. excludes:['system/js/index','system/util/mpVueComponent','system/util/mpVuePackage']
  62. // excludes:['system/util/mpFormBuilder','system/js/index','system/util/mpVueComponent','system/util/mpVuePackage']
  63. }
  64. });
  65. </script>
  66. <script type="text/javascript" src="/system/util/mpFrame.js"></script>
  67. </head>
  68. <body class="gray-bg">
  69. <div class="wrapper wrapper-content">
  70. <div class="row">
  71. <div class="col-sm-12">
  72. <div class="ibox">
  73. <div class="ibox-title">
  74. <button type="button" class="btn btn-w-m btn-primary" onclick="$eb.createModalFrame(this.innerText,'<?php echo Url('create',array('gid'=>$gid)); ?>')">添加数据</button>
  75. <div class="ibox-tools">
  76. </div>
  77. </div>
  78. <div class="ibox-content">
  79. <div class="row">
  80. <div class="col-sm-8 m-b-xs">
  81. <?php /* <form action="" class="form-inline">
  82. <i class="fa fa-search" style="margin-right: 10px;"></i>
  83. <select name="is_show" aria-controls="editable" class="form-control input-sm">
  84. <option value="">是否显示</option>
  85. <option value="1" <?php if($params['is_show'] == '1'): ?>selected="selected"<?php endif; ?>>显示</option>
  86. <option value="0" <?php if($params['is_show'] == '0'): ?>selected="selected"<?php endif; ?>>不显示</option>
  87. </select>
  88. <select name="access" aria-controls="editable" class="form-control input-sm">
  89. <option value="">子管理员是否可用</option>
  90. <option value="1" <?php if($params['access'] == '1'): ?>selected="selected"<?php endif; ?>>可用</option>
  91. <option value="0" <?php if($params['access'] == '0'): ?>selected="selected"<?php endif; ?>>不可用</option>
  92. </select>
  93. <div class="input-group">
  94. <input type="text" name="keyword" value="<?php echo htmlentities($params['keyword']); ?>" placeholder="请输入关键词" class="input-sm form-control"> <span class="input-group-btn">
  95. <button type="submit" class="btn btn-sm btn-primary"> 搜索</button> </span>
  96. </div>
  97. </form> */ ?>
  98. <form action="" class="form-inline">
  99. <i class="fa fa-search" style="margin-right: 10px;"></i>
  100. <input type="hidden" name="gid" value="<?php echo htmlentities($where['gid']); ?>">
  101. <select name="status" aria-controls="editable" class="form-control input-sm">
  102. <option value="">是否可用</option>
  103. <option value="1" <?php if($where['status'] == '1'): ?>selected="selected"<?php endif; ?>>显示</option>
  104. <option value="2" <?php if($where['status'] == '2'): ?>selected="selected"<?php endif; ?>>不显示</option>
  105. </select>
  106. <button type="submit" class="btn btn-sm btn-primary"> 搜索</button> </span>
  107. </form>
  108. </div>
  109. </div>
  110. <div class="table-responsive">
  111. <table class="table table-striped table-bordered">
  112. <thead>
  113. <tr>
  114. <th class="text-center">编号</th>
  115. <?php if(is_array($fields) || $fields instanceof \think\Collection || $fields instanceof \think\Paginator): $i = 0; $__LIST__ = $fields;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?>
  116. <th class="text-center"><?php echo htmlentities($vo['name']); ?></th>
  117. <?php endforeach; endif; else: echo "" ;endif; ?>
  118. <th class="text-center">是否可用</th>
  119. <th class="text-center">操作</th>
  120. </tr>
  121. </thead>
  122. <tbody class="">
  123. <?php if(is_array($list) || $list instanceof \think\Collection || $list instanceof \think\Paginator): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?>
  124. <tr>
  125. <td class="text-center">
  126. <?php echo htmlentities($vo['id']); ?>
  127. </td>
  128. <?php if(is_array($fields) || $fields instanceof \think\Collection || $fields instanceof \think\Paginator): $i = 0; $__LIST__ = $fields;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$item): $mod = ($i % 2 );++$i;?>
  129. <td class="text-center">
  130. <?php if(isset($vo['value'][$item['title']]['value']) && $vo['value'][$item['title']]['value'] !== ''): if($vo['value'][$item['title']]['type'] == 'upload' || $vo['value'][$item['title']]['type'] == 'uploads'): if(is_array($vo['value'][$item['title']]['value'])): if(is_array($vo['value'][$item['title']]['value']) || $vo['value'][$item['title']]['value'] instanceof \think\Collection || $vo['value'][$item['title']]['value'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['value'][$item['title']]['value'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$valueItem): $mod = ($i % 2 );++$i;?>
  131. <img class="image" data-image="<?php echo htmlentities($valueItem); ?>" width="45" height="45" src="<?php echo htmlentities($valueItem); ?>" />
  132. <?php endforeach; endif; else: echo "" ;endif; else: ?>
  133. <img class="image" data-image="<?php echo htmlentities($vo['value'][$item['title']]['value']); ?>" width="45" height="45" src="<?php echo htmlentities($vo['value'][$item['title']]['value']); ?>" />
  134. <?php endif; else: ?>
  135. <?php echo htmlentities($vo['value'][$item['title']]['value']); ?>
  136. <?php endif; ?>
  137. <?php endif; ?>
  138. </td>
  139. <?php endforeach; endif; else: echo "" ;endif; ?>
  140. <td class="text-center">
  141. <?php if($vo['status'] == 1): ?>
  142. <i class="fa fa-check text-navy"></i>
  143. <?php elseif($vo['status'] == 2): ?>
  144. <i class="fa fa-close text-danger"></i>
  145. <?php endif; ?>
  146. </td>
  147. <td class="text-center">
  148. <button class="btn btn-info btn-xs" type="button" onclick="$eb.createModalFrame('编辑','<?php echo Url('edit',array('gid'=>$gid,'id'=>$vo['id'])); ?>')"><i class="fa fa-edit"></i> 编辑</button>
  149. <button class="btn btn-danger btn-xs " data-url="<?php echo Url('delete',array('id'=>$vo['id'])); ?>" type="button"><i class="fa fa-times"></i> 删除</button>
  150. </td>
  151. </tr>
  152. <?php endforeach; endif; else: echo "" ;endif; ?>
  153. </tbody>
  154. </table>
  155. </div>
  156. <link href="/system/frame/css/plugins/dataTables/dataTables.bootstrap.css" rel="stylesheet">
  157. <div class="row">
  158. <div class="col-sm-6">
  159. <div class="dataTables_info" id="DataTables_Table_0_info" role="alert" aria-live="polite" aria-relevant="all">共 <?php echo htmlentities($total); ?> 项</div>
  160. </div>
  161. <div class="col-sm-6">
  162. <div class="dataTables_paginate paging_simple_numbers" id="editable_paginate">
  163. <?php echo $page;?>
  164. </div>
  165. </div>
  166. </div>
  167. </div>
  168. </div>
  169. </div>
  170. </div>
  171. <script>
  172. $('.btn-danger').on('click',function(){
  173. window.t = $(this);
  174. var _this = $(this),url =_this.data('url');
  175. $eb.$swal('delete',function(){
  176. $eb.axios.get(url).then(function(res){
  177. console.log(res);
  178. if(res.status == 200 && res.data.code == 200) {
  179. $eb.$swal('success',res.data.msg);
  180. _this.parents('tr').remove();
  181. }else
  182. return Promise.reject(res.data.msg || '删除失败')
  183. }).catch(function(err){
  184. $eb.$swal('error',err);
  185. });
  186. })
  187. });
  188. $(".image").on('click',function (e) {
  189. var images = $(this).data('image');
  190. $eb.openImage(images);
  191. })
  192. </script>
  193. </div>
  194. </body>
  195. </html>