人人商城

display.html 5.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. {template 'common/header'}
  2. {template 'user/user-header'}
  3. <div class="keyword-list-head clearfix we7-margin-bottom">
  4. <form action="" method="get">
  5. <input type="hidden" name="c" value="user">
  6. <input type="hidden" name="a" value="display">
  7. <input type="hidden" name="do" value="{$_GPC['do']}">
  8. <input type="hidden" name="type" value="{$_GPC['type']}">
  9. <label for="" class="col-sm-1 control-label" style="width: 60px;">用户状态</label>
  10. <div class="col-sm-2" style="width: 140px;">
  11. <select name="expire" class="form-control">
  12. <option value="0" {if $_GPC['expire'] == 0}selected="selected"{/if}>不限</option>
  13. <option value="1" {if $_GPC['expire'] == 1}selected="selected"{/if}>未到期</option>
  14. <option value="2" {if $_GPC['expire'] == 2}selected="selected"{/if}>已到期</option>
  15. </select>
  16. </div>
  17. <label for="" class="col-sm-1 control-label" style="width: 50px;">用户组</label>
  18. <div class="input-controls col-sm-3">
  19. <select name="groupid" class="we7-select form-control">
  20. <option value="" selected="selected">不限</option>
  21. {loop $user_groups $group}
  22. <option value="{$group['id']}"{if $group['id'] == $_GPC['groupid']} selected="selected"{/if}>{$group['name']}</option>
  23. {/loop}
  24. </select>
  25. </div>
  26. <div class="input-group pull-left col-sm-3">
  27. <input type="text" name="search" id="" value="{$_GPC['search']}" class="form-control" placeholder="搜索用户名或手机号" />
  28. <span class="input-group-btn"><button class="btn btn-default"><i class="fa fa-search"></i></button></span>
  29. </div>
  30. </form>
  31. <div class="pull-right">
  32. {if $_GPC['type'] == 'display' || $_GPC['type'] == ''}<a href="{url 'user/create'}" class="btn btn-primary">+添加用户</a>{/if}
  33. </div>
  34. </div>
  35. <table class="table we7-table table-hover table-manage vertical-middle" id="js-users-display" ng-controller="UsersDisplay" ng-cloak>
  36. <col width="150px"/>
  37. <col width="150px">
  38. <col width="170px"/>
  39. <col width="100px"/>
  40. <col width="100px"/>
  41. <col width="80px"/>
  42. <col width="80px"/>
  43. <col width="130px"/>
  44. <col width="130px"/>
  45. <col width="150px"/>
  46. <tr>
  47. <th></th>
  48. <th class="text-left">用户名</th>
  49. <th>用户权限组</th>
  50. <th>公众号</th>
  51. <th>小程序</th>
  52. <th>pc</th>
  53. <th>APP</th>
  54. <th>注册时间</th>
  55. <th>到期时间</th>
  56. <th class="text-right">操作</th>
  57. </tr>
  58. <tr ng-repeat="user in users" ng-if="users">
  59. <td class="td-link">
  60. <a ng-href="{{links.edit}}uid={{user.uid}}">
  61. <img src="{{user.avatar}}" alt="" class="img-responsive icon"/>
  62. </a>
  63. </td>
  64. <td><span ng-bind="user.username"></span><br/><span ng-bind="user.mobile"></span></td>
  65. <td>
  66. <span class="color-default" ng-if="user.founder">管理员</span>
  67. <span class="color-default" ng-if="user.groupname && !user.founder" ng-bind="user.groupname"></span>
  68. <span class="color-default" ng-if="!user.groupname && !user.founder">未分配</span>
  69. </td>
  70. <td class="color-default" ng-bind="user.maxaccount"></td>
  71. <td class="color-default" ng-bind="user.maxwxapp"></td>
  72. <td class="color-default" ng-bind="user.maxwebapp"></td>
  73. <td class="color-default" ng-bind="user.maxphoneapp"></td>
  74. <td>
  75. <span ng-bind="user.joindate"></span>
  76. </td>
  77. <td>
  78. <span ng-bind="user.endtime"></span>
  79. </td>
  80. <td class="vertical-middle table-manage-td">
  81. <div class="link-group" ng-if="!user.founder">
  82. <a ng-href="{{links.edit}}uid={{user.uid}}" ng-if="type == 'display' || type == 'clerk'">编辑</a>
  83. <a href="javascript:;" ng-click="operate(user.uid, 'recycle')" ng-if="type == 'display' || type == 'clerk'" data-toggle="tooltip" data-placement="left" title="禁用后可在用户回收站查找到并重新启用。">禁用</a>
  84. <a href="javascript:;" ng-click="operate(user.uid, 'check_pass')" ng-if="type == 'check'">通过</a>
  85. <a href="javascript:;" ng-click="operate(user.uid, 'recycle')" ng-if="type == 'check'" data-toggle="tooltip" data-placement="left" title="拒绝后可在用户回收站查找到并启用。">拒绝</a>
  86. <a href="javascript:;" ng-click="operate(user.uid, 'recycle_restore')" ng-if="type == 'recycle'">启用</a>
  87. <a href="javascript:;" ng-click="operate(user.uid, 'recycle_delete')" class="del" ng-if="type == 'recycle'">删除</a>
  88. </div>
  89. <div class="manage-option text-right" ng-if="!user.founder && type != 'recycle' && type != 'check'">
  90. <a href="{{links.edit}}uid={{user.uid}}">基础信息</a>
  91. <a href="{{links.edit}}&do=edit_modules_tpl&uid={{user.uid}}">应用模板权限</a>
  92. <a href="{{links.edit}}&do=edit_account&uid={{user.uid}}">使用账号列表</a>
  93. </div>
  94. </td>
  95. </tr>
  96. <tr ng-if="!users">
  97. <td colspan="10" class="text-center">暂无数据</td>
  98. </tr>
  99. </table>
  100. <div class="text-right pager-pagination-float">
  101. {$pager}
  102. </div>
  103. <span class="pager-total">共{php echo $total}个</span>
  104. <script type="text/javascript">
  105. $(function(){
  106. $('[data-toggle="tooltip"]').tooltip();
  107. });
  108. angular.module('userManageApp').value('config', {
  109. type: "{php echo !empty($_GPC['type']) ? $_GPC['type'] : 'display'}",
  110. users: {php echo !empty($users) ? json_encode($users) : 'null'},
  111. usergroups: {php echo !empty($usergroups) ? json_encode($usergroups) : 'null'},
  112. links: {
  113. link: "{php echo url('user/display/operate')}",
  114. edit: "{php echo url('user/edit')}",
  115. },
  116. });
  117. angular.bootstrap($('#js-users-display'), ['userManageApp']);
  118. </script>
  119. {template 'common/footer'}