Friendica Communications Platform (please note that this is a clone of the repository at github, issues are handled there) https://friendi.ca
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

139 lines
4.9 KiB

  1. <script>
  2. function confirm_delete(uname){
  3. return confirm( "{{$confirm_delete}}".format(uname));
  4. }
  5. function confirm_delete_multi(){
  6. return confirm("{{$confirm_delete_multi}}");
  7. }
  8. function selectall(cls){
  9. $("."+cls).attr('checked','checked');
  10. return false;
  11. }
  12. </script>
  13. <div id='adminpage'>
  14. <h1>{{$title}} - {{$page}}</h1>
  15. <form action="{{$baseurl}}/admin/users" method="post">
  16. <input type='hidden' name='form_security_token' value='{{$form_security_token}}'>
  17. <h3>{{$h_pending}}</h3>
  18. {{if $pending}}
  19. <table id='pending'>
  20. <thead>
  21. <tr>
  22. {{foreach $th_pending as $th}}<th>{{$th}}</th>{{/foreach}}
  23. <th></th>
  24. <th></th>
  25. </tr>
  26. </thead>
  27. <tbody>
  28. {{foreach $pending as $u}}
  29. <tr>
  30. <td class="created">{{$u.created}}</td>
  31. <td class="name">{{$u.name}}</td>
  32. <td class="email">{{$u.email}}</td>
  33. <td class="checkbox"><input type="checkbox" class="pending_ckbx" id="id_pending_{{$u.hash}}" name="pending[]" value="{{$u.hash}}" /></td>
  34. <td class="tools">
  35. <a href="{{$baseurl}}/regmod/allow/{{$u.hash}}" title='{{$approve}}'><span class='icon like'></span></a>
  36. <a href="{{$baseurl}}/regmod/deny/{{$u.hash}}" title='{{$deny}}'><span class='icon dislike'></span></a>
  37. </td>
  38. </tr>
  39. {{/foreach}}
  40. </tbody>
  41. </table>
  42. <div class='selectall'><a href='#' onclick="return selectall('pending_ckbx');">{{$select_all}}</a></div>
  43. <div class="submit"><input type="submit" name="page_users_deny" value="{{$deny}}"/> <input type="submit" name="page_users_approve" value="{{$approve}}" /></div>
  44. {{else}}
  45. <p>{{$no_pending}}</p>
  46. {{/if}}
  47. <h3>{{$h_users}}</h3>
  48. {{if $users}}
  49. <table id='users'>
  50. <thead>
  51. <tr>
  52. <th></th>
  53. {{foreach $th_users as $th}}<th>{{$th}}</th>{{/foreach}}
  54. <th></th>
  55. <th></th>
  56. </tr>
  57. </thead>
  58. <tbody>
  59. {{foreach $users as $u}}
  60. <tr>
  61. <td><img class='icon' src="{{$u.micro}}" alt="{{$u.nickname}}" title="{{$u.nickname}}"></td>
  62. <td class='name'><a href="{{$u.url}}" title="{{$u.nickname}}" >{{$u.name}}</a></td>
  63. <td class='email'>{{$u.email}}</td>
  64. <td class='register_date'>{{$u.register_date}}</td>
  65. <td class='login_date'>{{$u.login_date}}</td>
  66. <td class='lastitem_date'>{{$u.lastitem_date}}</td>
  67. <td class='login_date'>{{$u.page_flags}} {{if $u.is_admin}}({{$siteadmin}}){{/if}} {{if $u.account_expired}}({{$accountexpired}}){{/if}}</td>
  68. <td class="checkbox">
  69. {{if $u.is_deletable}}
  70. <input type="checkbox" class="users_ckbx" id="id_user_{{$u.uid}}" name="user[]" value="{{$u.uid}}"/></td>
  71. {{else}}
  72. &nbsp;
  73. {{/if}}
  74. <td class="tools">
  75. {{if $u.is_deletable}}
  76. <a href="{{$baseurl}}/admin/users/block/{{$u.uid}}?t={{$form_security_token}}" title='{{if $u.blocked}}{{$unblock}}{{else}}{{$block}}{{/if}}'><span class='icon {{if $u.blocked==0}}unlock{{else}}lock{{/if}}'></span></a>
  77. <a href="{{$baseurl}}/admin/users/delete/{{$u.uid}}?t={{$form_security_token}}" title='{{$delete}}' onclick="return confirm_delete('{{$u.name}}')"><span class='icon delete'></span></a>
  78. {{else}}
  79. &nbsp;
  80. {{/if}}
  81. </td>
  82. </tr>
  83. {{/foreach}}
  84. </tbody>
  85. </table>
  86. <div class='selectall'><a href='#' onclick="return selectall('users_ckbx');">{{$select_all}}</a></div>
  87. <div class="submit"><input type="submit" name="page_users_block" value="{{$block}}/{{$unblock}}" /> <input type="submit" name="page_users_delete" value="{{$delete}}" onclick="return confirm_delete_multi()" /></div>
  88. {{else}}
  89. NO USERS?!?
  90. {{/if}}
  91. </form>
  92. {{if $deleted}}
  93. <h3>{{$h_deleted}}</h3>
  94. <table id='deleted'>
  95. <thead>
  96. <tr>
  97. <th></th>
  98. {{foreach $th_deleted as $th}}<th>{{$th}}</th>{{/foreach}}
  99. </tr>
  100. </thead>
  101. <tbody>
  102. {{foreach $deleted as $u}}
  103. <tr>
  104. <td><img class='icon' src="{{$u.micro}}" alt="{{$u.nickname}}" title="{{$u.nickname}}"></td>
  105. <td class='name'><a href="{{$u.url}}" title="{{$u.nickname}}" >{{$u.name}}</a></td>
  106. <td class='email'>{{$u.email}}</td>
  107. <td class='register_date'>{{$u.register_date}}</td>
  108. <td class='login_date'>{{$u.login_date}}</td>
  109. <td class='lastitem_date'>{{$u.lastitem_date}}</td>
  110. <td class='login_date'>{{$u.deleted}}</td>
  111. </tr>
  112. {{/foreach}}
  113. </tbody>
  114. </table>
  115. {{/if}}
  116. <h3>{{$h_newuser}}</h3>
  117. <form action="{{$baseurl}}/admin/users" method="post">
  118. <input type='hidden' name='form_security_token' value='{{$form_security_token}}'>
  119. <table id='users'>
  120. <tbody>
  121. <tr>
  122. <td>{{include file="field_input.tpl" field=$newusername}}</td>
  123. </tr>
  124. <tr>
  125. <td>{{include file="field_input.tpl" field=$newusernickname}}</td>
  126. </tr>
  127. <tr>
  128. <td>{{include file="field_input.tpl" field=$newuseremail}}</td>
  129. </tr>
  130. </tbody>
  131. </table>
  132. <div class="submit"><input type="submit" name="add_new_user_submit" value="{{$submit}}" /></div>
  133. </form>
  134. </div>