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.
 
 
 
 
 
 

153 lines
5.3 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|escape:'html'}}"/> <input type="submit" name="page_users_approve" value="{{$approve|escape:'html'}}" /></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}}
  54. <th>
  55. <a href="{{$baseurl}}/admin/users/?o={{if $order_direction_users == "+"}}-{{/if}}{{$th.1}}">
  56. {{if $order_users == $th.1}}
  57. {{if $order_direction_users == "+"}}
  58. &#8595;
  59. {{else}}
  60. &#8593;
  61. {{/if}}
  62. {{else}}
  63. &#8597;
  64. {{/if}}
  65. {{$th.0}}</a>
  66. </th>
  67. {{/foreach}}
  68. <th></th>
  69. <th></th>
  70. </tr>
  71. </thead>
  72. <tbody>
  73. {{foreach $users as $u}}
  74. <tr>
  75. <td><img class='icon' src="{{$u.micro}}" alt="{{$u.nickname}}" title="{{$u.nickname}}"></td>
  76. <td class='name'><a href="{{$u.url}}" title="{{$u.nickname}}" >{{$u.name}}</a></td>
  77. <td class='email'>{{$u.email}}</td>
  78. <td class='register_date'>{{$u.register_date}}</td>
  79. <td class='login_date'>{{$u.login_date}}</td>
  80. <td class='lastitem_date'>{{$u.lastitem_date}}</td>
  81. <td class='login_date'>{{$u.page_flags}} {{if $u.is_admin}}({{$siteadmin}}){{/if}} {{if $u.account_expired}}({{$accountexpired}}){{/if}}</td>
  82. <td class="checkbox">
  83. {{if $u.is_deletable}}
  84. <input type="checkbox" class="users_ckbx" id="id_user_{{$u.uid}}" name="user[]" value="{{$u.uid}}"/></td>
  85. {{else}}
  86. &nbsp;
  87. {{/if}}
  88. <td class="tools">
  89. {{if $u.is_deletable}}
  90. <a href="{{$baseurl}}/admin/users/block/{{$u.uid}}?t={{$form_security_token}}" title='{{if $u.blocked}}{{$unblock}}{{else}}{{$block}}{{/if}}'><span class='icon block {{if $u.blocked==0}}dim{{/if}}'></span></a>
  91. <a href="{{$baseurl}}/admin/users/delete/{{$u.uid}}?t={{$form_security_token}}" title='{{$delete}}' onclick="return confirm_delete('{{$u.name}}')"><span class='icon drop'></span></a>
  92. {{else}}
  93. &nbsp;
  94. {{/if}}
  95. </td>
  96. </tr>
  97. {{/foreach}}
  98. </tbody>
  99. </table>
  100. <div class='selectall'><a href='#' onclick="return selectall('users_ckbx');">{{$select_all}}</a></div>
  101. <div class="submit"><input type="submit" name="page_users_block" value="{{$block|escape:'html'}}/{{$unblock|escape:'html'}}" /> <input type="submit" name="page_users_delete" value="{{$delete|escape:'html'}}" onclick="return confirm_delete_multi()" /></div>
  102. {{else}}
  103. NO USERS?!?
  104. {{/if}}
  105. </form>
  106. {{if $deleted}}
  107. <h3>{{$h_deleted}}</h3>
  108. <table id='deleted'>
  109. <thead>
  110. <tr>
  111. <th></th>
  112. {{foreach $th_deleted as $th}}<th>{{$th}}</th>{{/foreach}}
  113. </tr>
  114. </thead>
  115. <tbody>
  116. {{foreach $deleted as $u}}
  117. <tr>
  118. <td><img class='icon' src="{{$u.micro}}" alt="{{$u.nickname}}" title="{{$u.nickname}}"></td>
  119. <td class='name'><a href="{{$u.url}}" title="{{$u.nickname}}" >{{$u.name}}</a></td>
  120. <td class='email'>{{$u.email}}</td>
  121. <td class='register_date'>{{$u.register_date}}</td>
  122. <td class='login_date'>{{$u.login_date}}</td>
  123. <td class='lastitem_date'>{{$u.lastitem_date}}</td>
  124. <td class='login_date'>{{$u.deleted}}</td>
  125. </tr>
  126. {{/foreach}}
  127. </tbody>
  128. </table>
  129. {{/if}}
  130. <h3>{{$h_newuser}}</h3>
  131. <form action="{{$baseurl}}/admin/users" method="post">
  132. <input type='hidden' name='form_security_token' value='{{$form_security_token}}'>
  133. <table id='users'>
  134. <tbody>
  135. <tr>
  136. <td>{{include file="field_input.tpl" field=$newusername}}</td>
  137. </tr>
  138. <tr>
  139. <td>{{include file="field_input.tpl" field=$newusernickname}}</td>
  140. </tr>
  141. <tr>
  142. <td>{{include file="field_input.tpl" field=$newuseremail}}</td>
  143. </tr>
  144. </tbody>
  145. </table>
  146. <div class="submit"><input type="submit" name="add_new_user_submit" value="{{$submit|escape:'html'}}" /></div>
  147. </form>
  148. </div>