Ticket #7105: 7105.04.patch
File 7105.04.patch, 10.4 KB (added by , 8 years ago) |
---|
-
src/bp-templates/bp-legacy/buddypress/groups/single/admin/manage-members.php
diff --git src/bp-templates/bp-legacy/buddypress/groups/single/admin/manage-members.php src/bp-templates/bp-legacy/buddypress/groups/single/admin/manage-members.php index f404f9b..e259e4e 100644
19 19 */ 20 20 do_action( 'bp_before_group_manage_members_admin' ); ?> 21 21 22 <div class=" bp-widget">23 <h3 ><?php _e( 'Administrators', 'buddypress' ); ?></h3>22 <div class="group-members-list group-admins-list"> 23 <h3 class="section-header"><?php _e( 'Administrators', 'buddypress' ); ?></h3> 24 24 25 <?php if ( bp_ has_members( '&include='. bp_group_admin_ids() ) ) : ?>25 <?php if ( bp_group_has_members( array( 'per_page' => 15, 'group_role' => array( 'admin' ), 'page_arg' => 'mlpage-admin' ) ) ) : ?> 26 26 27 <ul id="admins-list" class="item-list single-line"> 28 29 <?php while ( bp_members() ) : bp_the_member(); ?> 30 <li> 31 <?php echo bp_core_fetch_avatar( array( 'item_id' => bp_get_member_user_id(), 'type' => 'thumb', 'width' => 30, 'height' => 30, 'alt' => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_member_name() ) ) ); ?> 32 <h5> 33 <a href="<?php bp_member_permalink(); ?>"> <?php bp_member_name(); ?></a> 34 <?php if ( count( bp_group_admin_ids( false, 'array' ) ) > 1 ) : ?> 35 <span class="small"> 36 <a class="button confirm admin-demote-to-member" href="<?php bp_group_member_demote_link( bp_get_member_user_id() ); ?>"><?php _e( 'Demote to Member', 'buddypress' ); ?></a> 37 </span> 38 <?php endif; ?> 39 </h5> 40 </li> 41 <?php endwhile; ?> 27 <?php if ( bp_group_member_needs_pagination() ) : ?> 42 28 43 </ul>29 <div class="pagination no-ajax"> 44 30 45 <?php endif; ?> 31 <div id="member-count" class="pag-count"> 32 <?php bp_group_member_pagination_count(); ?> 33 </div> 46 34 47 </div> 35 <div id="member-admin-pagination" class="pagination-links"> 36 <?php bp_group_member_admin_pagination(); ?> 37 </div> 48 38 49 <?php if ( bp_group_has_moderators() ) : ?> 50 <div class="bp-widget"> 51 <h3><?php _e( 'Moderators', 'buddypress' ); ?></h3> 39 </div> 52 40 53 <?php if ( bp_has_members( '&include=' . bp_group_mod_ids() ) ) : ?> 54 <ul id="mods-list" class="item-list single-line"> 41 <?php endif; ?> 55 42 56 <?php while ( bp_members() ) : bp_the_member(); ?> 43 <ul id="admins-list" class="item-list"> 44 <?php while ( bp_group_members() ) : bp_group_the_member(); ?> 57 45 <li> 58 <?php echo bp_core_fetch_avatar( array( 'item_id' => bp_get_member_user_id(), 'type' => 'thumb', 'width' => 30, 'height' => 30, 'alt' => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_member_name() ) ) ); ?> 59 <h5> 60 <a href="<?php bp_member_permalink(); ?>"> <?php bp_member_name(); ?></a> 61 <span class="small"> 62 <a href="<?php bp_group_member_promote_admin_link( array( 'user_id' => bp_get_member_user_id() ) ); ?>" class="button confirm mod-promote-to-admin"><?php _e( 'Promote to Admin', 'buddypress' ); ?></a> 63 <a class="button confirm mod-demote-to-member" href="<?php bp_group_member_demote_link( bp_get_member_user_id() ); ?>"><?php _e( 'Demote to Member', 'buddypress' ); ?></a> 64 </span> 65 </h5> 46 <div class="item-avatar"> 47 <?php bp_group_member_avatar_thumb(); ?> 48 </div> 49 50 <div class="item"> 51 <div class="item-title"> 52 <?php bp_group_member_link(); ?> 53 </div> 54 <p class="joined item-meta"> 55 <?php bp_group_member_joined_since(); ?> 56 </p> 57 </div> 58 59 <div class="action"> 60 <?php if ( count( bp_group_admin_ids( false, 'array' ) ) > 1 ) : ?> 61 <a class="button confirm admin-demote-to-member" href="<?php bp_group_member_demote_link(); ?>"><?php _e( 'Demote to Member', 'buddypress' ); ?></a> 62 <?php endif; ?> 63 64 <?php 65 66 /** 67 * Fires inside the display of a member admin item in group management area. 68 * 69 * @since 1.1.0 70 * @since 2.7.0 Added $section parameter. 71 */ 72 do_action( 'bp_group_manage_members_admin_item', 'admins-list' ); ?> 73 74 </div> 66 75 </li> 67 <?php endwhile; ?> 76 <?php endwhile; ?> 77 </ul> 68 78 69 </ul> 79 <?php if ( bp_group_member_needs_pagination() ) : ?> 80 81 <div class="pagination no-ajax"> 82 83 <div id="member-count" class="pag-count"> 84 <?php bp_group_member_pagination_count(); ?> 85 </div> 86 87 <div id="member-admin-pagination" class="pagination-links"> 88 <?php bp_group_member_admin_pagination(); ?> 89 </div> 90 91 </div> 70 92 71 93 <?php endif; ?> 94 95 <?php else: ?> 96 97 <div id="message" class="info"> 98 <p><?php _e( 'No group administrators were found.', 'buddypress' ); ?></p> 72 99 </div> 73 <?php endif; ?>74 100 101 <?php endif; ?> 102 </div> 75 103 76 <div class=" bp-widget">77 <h3 ><?php _e( "Members", 'buddypress' ); ?></h3>104 <div class="group-members-list group-mods-list"> 105 <h3 class="section-header"><?php _e( 'Moderators', 'buddypress' ); ?></h3> 78 106 79 <?php if ( bp_group_has_members( 'per_page=15&exclude_banned=0') ) : ?>107 <?php if ( bp_group_has_members( array( 'per_page' => 15, 'group_role' => array( 'mod' ), 'page_arg' => 'mlpage-mod' ) ) ) : ?> 80 108 81 109 <?php if ( bp_group_member_needs_pagination() ) : ?> 82 110 … … do_action( 'bp_before_group_manage_members_admin' ); ?> 94 122 95 123 <?php endif; ?> 96 124 97 <ul id="members-list" class="item-list single-line"> 125 <ul id="mods-list" class="item-list"> 126 98 127 <?php while ( bp_group_members() ) : bp_group_the_member(); ?> 128 <li> 129 <div class="item-avatar"> 130 <?php bp_group_member_avatar_thumb(); ?> 131 </div> 132 133 <div class="item"> 134 <div class="item-title"> 135 <?php bp_group_member_link(); ?> 136 </div> 137 <p class="joined item-meta"> 138 <?php bp_group_member_joined_since(); ?> 139 </p> 140 </div> 141 142 <div class="action"> 143 <a href="<?php bp_group_member_promote_admin_link(); ?>" class="button confirm mod-promote-to-admin"><?php _e( 'Promote to Admin', 'buddypress' ); ?></a> 144 <a class="button confirm mod-demote-to-member" href="<?php bp_group_member_demote_link(); ?>"><?php _e( 'Demote to Member', 'buddypress' ); ?></a> 145 146 <?php 147 148 /** 149 * Fires inside the display of a member admin item in group management area. 150 * 151 * @since 1.1.0 152 * @since 2.7.0 Added $section parameter. 153 */ 154 do_action( 'bp_group_manage_members_admin_item', 'mods-list' ); ?> 155 156 </div> 157 </li> 158 <?php endwhile; ?> 99 159 100 <li class="<?php bp_group_member_css_class(); ?>"> 101 <?php bp_group_member_avatar_mini(); ?> 160 </ul> 161 162 <?php if ( bp_group_member_needs_pagination() ) : ?> 163 164 <div class="pagination no-ajax"> 165 166 <div id="member-count" class="pag-count"> 167 <?php bp_group_member_pagination_count(); ?> 168 </div> 102 169 103 <h5> 104 <?php bp_group_member_link(); ?> 170 <div id="member-admin-pagination" class="pagination-links"> 171 <?php bp_group_member_admin_pagination(); ?> 172 </div> 105 173 106 <?php if ( bp_get_group_member_is_banned() ) _e( '(banned)', 'buddypress' ); ?>174 </div> 107 175 108 <span class="small">176 <?php endif; ?> 109 177 178 <?php else: ?> 179 180 <div id="message" class="info"> 181 <p><?php _e( 'No group moderators were found.', 'buddypress' ); ?></p> 182 </div> 183 184 <?php endif; ?> 185 </div> 186 187 <div class="group-members-list"> 188 <h3 class="section-header"><?php _e( "Members", 'buddypress' ); ?></h3> 189 190 <?php if ( bp_group_has_members( array( 'per_page' => 15, 'exclude_banned' => 0 ) ) ) : ?> 191 192 <?php if ( bp_group_member_needs_pagination() ) : ?> 193 194 <div class="pagination no-ajax"> 195 196 <div id="member-count" class="pag-count"> 197 <?php bp_group_member_pagination_count(); ?> 198 </div> 199 200 <div id="member-admin-pagination" class="pagination-links"> 201 <?php bp_group_member_admin_pagination(); ?> 202 </div> 203 204 </div> 205 206 <?php endif; ?> 207 208 <ul id="members-list" class="item-list"> 209 <?php while ( bp_group_members() ) : bp_group_the_member(); ?> 210 211 <li class="<?php bp_group_member_css_class(); ?>"> 212 <div class="item-avatar"> 213 <?php bp_group_member_avatar_thumb(); ?> 214 </div> 215 216 <div class="item"> 217 <div class="item-title"> 218 <?php bp_group_member_link(); ?> 219 <?php 220 if ( bp_get_group_member_is_banned() ) { 221 echo ' <span class="banned">'; 222 _e( '(banned)', 'buddypress' ); 223 echo '</span>'; 224 } ?> 225 </div> 226 <p class="joined item-meta"> 227 <?php bp_group_member_joined_since(); ?> 228 </p> 229 </div> 230 231 <div class="action"> 110 232 <?php if ( bp_get_group_member_is_banned() ) : ?> 111 233 112 234 <a href="<?php bp_group_member_unban_link(); ?>" class="button confirm member-unban" title="<?php esc_attr_e( 'Unban this member', 'buddypress' ); ?>"><?php _e( 'Remove Ban', 'buddypress' ); ?></a> … … do_action( 'bp_before_group_manage_members_admin' ); ?> 119 241 120 242 <?php endif; ?> 121 243 122 <a href="<?php bp_group_member_remove_link(); ?>" class="button confirm"><?php _e( 'Remove from group', 'buddypress' ); ?></a> 123 124 <?php 244 <a href="<?php bp_group_member_remove_link(); ?>" class="button confirm"><?php _e( 'Remove from group', 'buddypress' ); ?></a> 125 245 126 /** 127 * Fires inside the display of a member admin item in group management area. 128 * 129 * @since 1.1.0 130 */ 131 do_action( 'bp_group_manage_members_admin_item' ); ?> 246 <?php 132 247 133 </span> 134 </h5> 248 /** 249 * Fires inside the display of a member admin item in group management area. 250 * 251 * @since 1.1.0 252 * @since 2.7.0 Added $section parameter. 253 */ 254 do_action( 'bp_group_manage_members_admin_item', 'members-list' ); ?> 255 </div> 135 256 </li> 136 257 137 258 <?php endwhile; ?> … … do_action( 'bp_before_group_manage_members_admin' ); ?> 156 277 <?php else: ?> 157 278 158 279 <div id="message" class="info"> 159 <p><?php _e( ' This group has no members.', 'buddypress' ); ?></p>280 <p><?php _e( 'No group members were found.', 'buddypress' ); ?></p> 160 281 </div> 161 282 162 283 <?php endif; ?> -
src/bp-templates/bp-legacy/css/buddypress.css
diff --git src/bp-templates/bp-legacy/css/buddypress.css src/bp-templates/bp-legacy/css/buddypress.css index 83b76fb..1b3e854 100644
body.activity-permalink #buddypress ul.item-list li.activity-item { 1420 1420 overflow: auto; 1421 1421 list-style: none; 1422 1422 } 1423 #buddypress .group-members-list { 1424 width: 100%; 1425 margin-top: 1em; 1426 clear: both; 1427 overflow: auto; 1428 } 1423 1429 #buddypress #item-buttons:empty { 1424 1430 display: none; 1425 1431 }