5c7008818cab23b15ee1477e746e4066.php 5.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. <?php if (!defined('THINK_PATH')) exit();?><div class="bjui-pageHeader" data-layout-fixed="true">
  2. <div class="bjui-searchBar">
  3. <div class="btn-group">
  4. <button type="button" class="btn-green" >查询</button>
  5. <!-- showMoreSearch 记住显示状态data-name="custom2" -->
  6. <button type="button" class="btn-green" data-toggle="moresearch" title="更多查询条件"><i class="fa fa-angle-double-down"></i></button>
  7. </div>
  8. <span><a class="btn btn-orange" href="javascript:;" onclick="loadpage(this)" data-icon="undo"> 刷新</a></span>
  9. <span style="float:right;" ><a onclick="down_data('/jdxf/admin1.php/Home/user/downdata?',$('#user_form').serialize())" class="btn btn-blue" data-icon="arrow-up" ><i class="fa fa-arrow-down"></i> 导出</a></span>
  10. <span style="float:right;margin-right:20px; <?php echo display(CONTROLLER_NAME.'/add'); ?> ">
  11. <a class="btn btn-green" data-toggle="dialog"
  12. data-options="{id:'user_add', url:'/jdxf/admin1.php/Home/user/add', width:450, height:500,onClose:'user_sx',mask:true}" data-id="dialog-mask" data-mask="true" data-icon="plus"> 新增用户</a>
  13. </span>
  14. </div>
  15. <form data-toggle="ajaxsearch" data-options="{searchDatagrid:$.CurrentNavtab.find('#usertable')}" id="user_form">
  16. <div class="bjui-moreSearch">
  17. <fieldset>
  18. <legend style="font-weight:normal;">搜索:</legend>
  19. <div style="margin:0; padding:1px 5px 5px;">
  20. <span>登录名:</span>
  21. <input name="username" size="12">&nbsp;
  22. <span>姓名:</span>
  23. <input name="truename" size="12">&nbsp;
  24. <span>组:</span>
  25. <input type="text" name="depname" data-toggle="selectztree" size="12" data-tree="#gtree_user_sel" readonly >
  26. <ul id="gtree_user_sel" class="ztree hide" data-toggle="ztree" data-expand-all="true" data-check-enable="true"
  27. data-chk-style="radio" data-radio-type="all" data-on-check="ztrCheck" data-on-click="ztrClick">
  28. <?php if(is_array($group)): $i = 0; $__LIST__ = $group;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$gvo): $mod = ($i % 2 );++$i;?><li data-id="<?php echo ($gvo["id"]); ?>" data-pid="<?php echo ($gvo["pid"]); ?>"><?php echo ($gvo["title"]); ?></li><?php endforeach; endif; else: echo "" ;endif; ?>
  29. </ul>
  30. &nbsp;<span>角色:</span>
  31. <input type="text" name="posname" data-toggle="selectztree" size="12" data-tree="#tree_user_sel" readonly > <span style="color:red;" >*</span>
  32. <ul id="tree_user_sel" class="ztree hide" data-toggle="ztree" data-expand-all="true" data-check-enable="true"
  33. data-chk-style="radio" data-radio-type="all" data-on-check="ztrCheck" data-on-click="ztrClick">
  34. <?php if(is_array($role)): $i = 0; $__LIST__ = $role;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><li data-id="<?php echo ($vo["id"]); ?>" data-pid="<?php echo ($vo["pid"]); ?>"><?php echo ($vo["title"]); ?></li><?php endforeach; endif; else: echo "" ;endif; ?>
  35. </ul>
  36. <div class="btn-group">
  37. <button type="submit" class="btn-green" onclick="formnone()" data-icon="search">查询!</button>
  38. <button type="reset" class="btn-orange" data-icon="times">重置</button>
  39. </div>
  40. </div>
  41. </fieldset>
  42. </div>
  43. </form>
  44. </div>
  45. <!--header end -->
  46. <div class="bjui-pageContent">
  47. <!--
  48. <ul id="ztree-test-demo2" class="ztree" data-toggle="ztree"
  49. data-options="{nodes:[{id:1,pid:0,name:'表单元素',faicon:'rss',children:[{id:10,pId:1,name:'按钮'},{id:11,pId:1,name:'文本框'}]}]}"></ul>
  50. <ul id="ztree-test" class="ztree" data-toggle="ztree" data-check-enable="true" data-on-click="MainMenuClick">
  51. <li data-id="1" data-pid="0" data-faicon="rss" data-faicon-close="cab">表单元素</li>
  52. <li data-id="9" data-pid="1" data-url="/jdxf/admin1.php/home/Permission/index" data-tabid="form-button" data-faicon="bell">按钮</li>
  53. <li data-id="10" data-pid="1" data-url="" data-tabid="form-button" data-faicon="bell">按钮</li>
  54. <li data-id="11" data-pid="10" data-url="" data-tabid="form-input" data-faicon="info-circle">文本框</li>
  55. -->
  56. <table id='usertable'>
  57. <thead>
  58. <tr>
  59. <th data-options="{name:'username',width:230}">登录名</th>
  60. <th data-options="{name:'truename'}">姓名</th>
  61. <!-- <th data-options="{name:'extension'}">分机号</th>
  62. <th data-options="{name:'agentid'}">座席号</th>-->
  63. <th data-options="{name:'depname'}">所在组</th>
  64. <th data-options="{name:'posname'}">担任角色</th>
  65. <th data-options="{name:'phone'}">联系电话</th>
  66. <th data-options="{name:'email'}">电子邮箱</th>
  67. <th data-options="{name:'address'}">地址</th>
  68. <th data-options="{render:'user_opert',align:'center',quicksort:false}">操作</th>
  69. </tr>
  70. </thead>
  71. </table>
  72. </div>
  73. <script>
  74. mypage('#usertable',true,false,'/jdxf/admin1.php/Home/user/index/list/1');//表id ,取值url
  75. function user_opert(tr,data){
  76. return '<a class="btn btn-green" data-toggle="dialog" data-options={id:"user_edit",url:"/jdxf/admin1.php/Home/user/edit/id/'+data.id+'",width:"450",height:"500",onClose:"user_sx"} data-mask="true" >编辑</a>'+
  77. '<a class="btn btn-red" onclick="Data_del(\'/jdxf/admin1.php/Home/user/del\','+data.id+',\'#usertable\')" data-mask="true" >删除</a>';
  78. }
  79. function user_sx(){
  80. $('#usertable').datagrid('refresh', {'filterFlag':true});
  81. }
  82. </script>