Ticket #7781: 7781.2.patch
File 7781.2.patch, 6.2 KB (added by , 7 years ago) |
---|
-
deleted file src/bp-templates/bp-nouveau/buddypress/groups/create-invites.php
diff --git src/bp-templates/bp-nouveau/buddypress/groups/create-invites.php src/bp-templates/bp-nouveau/buddypress/groups/create-invites.php deleted file mode 100644 index d2d2a9f65..000000000
+ - 1 <?php2 /**3 * Group create step invite friends4 *5 * This template include provides the standard BP invites step screen content6 *7 * @since 3.0.08 */9 ?>10 11 <?php bp_nouveau_user_feedback( 'create-invite-friends' ); ?>12 13 <?php14 bp_new_group_invite_friend_list( array( 'before' => '<ul class="friends-list create-group-invites">', 'after' => '</ul>' ) ); -
src/bp-templates/bp-nouveau/buddypress/groups/create.php
diff --git src/bp-templates/bp-nouveau/buddypress/groups/create.php src/bp-templates/bp-nouveau/buddypress/groups/create.php index 7d7b43fce..9d038a68b 100644
bp_nouveau_groups_create_hook( 'before', 'page' ); ?> 9 9 10 10 <?php bp_nouveau_groups_create_hook( 'before', 'content_template' ); ?> 11 11 12 <form action="<?php bp_group_creation_form_action(); ?>" method="post" id="create-group-form" class="standard-form" enctype="multipart/form-data"> 12 <?php if ( 'group-invites' !== bp_get_groups_current_create_step() ) : ?> 13 <form action="<?php bp_group_creation_form_action(); ?>" method="post" id="create-group-form" class="standard-form" enctype="multipart/form-data"> 14 <?php else : ?> 15 <div id="create-group-form" class="standard-form"> 16 <?php endif; ?> 13 17 14 18 <?php bp_nouveau_groups_create_hook( 'before' ); ?> 15 19 … … bp_nouveau_groups_create_hook( 'before', 'page' ); ?> 31 35 32 36 <?php bp_nouveau_groups_create_hook( 'after' ); ?> 33 37 34 </form> 38 <?php if ( 'group-invites' !== bp_get_groups_current_create_step() ) : ?> 39 </form><!-- #create-group-form --> 40 <?php else : ?> 41 </div><!-- #create-group-form --> 42 <?php endif; ?> 35 43 36 44 <?php bp_nouveau_groups_create_hook( 'after', 'content_template' ); ?> 37 45 -
src/bp-templates/bp-nouveau/includes/groups/functions.php
diff --git src/bp-templates/bp-nouveau/includes/groups/functions.php src/bp-templates/bp-nouveau/includes/groups/functions.php index 0a593e763..44f235269 100644
function bp_nouveau_groups_remove_home_widget_filters() { 1066 1066 function bp_nouveau_group_get_core_create_screens( $id = '' ) { 1067 1067 // screen id => dynamic part of the hooks, nonce & specific template to use. 1068 1068 $screens = array( 1069 'group-details' => array( 'hook' => 'group_details_creation_step', 'nonce' => 'groups_create_save_group-details', 'template' => 'groups/single/admin/edit-details' ), 1070 'group-settings' => array( 'hook' => 'group_settings_creation_step', 'nonce' => 'groups_create_save_group-settings', ), 1071 'group-avatar' => array( 'hook' => 'group_avatar_creation_step', 'nonce' => 'groups_create_save_group-avatar', ), 1072 'group-cover-image' => array( 'hook' => 'group_cover_image_creation_step', 'nonce' => 'groups_create_save_group-cover-image', ), 1073 'group-invites' => array( 'hook' => 'group_invites_creation_step', 'nonce' => 'groups_create_save_group-invites', 'template' => 'groups/create-invites' ), 1069 'group-details' => array( 1070 'hook' => 'group_details_creation_step', 1071 'nonce' => 'groups_create_save_group-details', 1072 'template' => 'groups/single/admin/edit-details', 1073 ), 1074 'group-settings' => array( 1075 'hook' => 'group_settings_creation_step', 1076 'nonce' => 'groups_create_save_group-settings', 1077 ), 1078 'group-avatar' => array( 1079 'hook' => 'group_avatar_creation_step', 1080 'nonce' => 'groups_create_save_group-avatar', 1081 ), 1082 'group-cover-image' => array( 1083 'hook' => 'group_cover_image_creation_step', 1084 'nonce' => 'groups_create_save_group-cover-image', 1085 ), 1086 'group-invites' => array( 1087 'hook' => 'group_invites_creation_step', 1088 'nonce' => 'groups_create_save_group-invites', 1089 'template' => 'common/js-templates/invites/index', 1090 ), 1074 1091 ); 1075 1092 1076 1093 if ( isset( $screens[ $id ] ) ) { -
src/bp-templates/bp-nouveau/includes/groups/template-tags.php
diff --git src/bp-templates/bp-nouveau/includes/groups/template-tags.php src/bp-templates/bp-nouveau/includes/groups/template-tags.php index c4d9afc72..87f9d64ad 100644
function bp_nouveau_group_manage_screen() { 356 356 ); 357 357 } 358 358 } 359 360 wp_nonce_field( $core_screen['nonce'] );361 359 } 362 360 } 363 361 … … function bp_nouveau_group_manage_screen() { 413 411 do_action( 'bp_after_group_creation_step_buttons' ); 414 412 } 415 413 414 /** 415 * Avoid nested forms with the Backbone views for the group invites step. 416 */ 417 if ( 'group-invites' === bp_get_groups_current_create_step() ) { 418 printf( 419 '<form action="%s" method="post" enctype="multipart/form-data">', 420 bp_get_group_creation_form_action() 421 ); 422 } 423 424 if ( ! empty( $core_screen['nonce'] ) ) { 425 wp_nonce_field( $core_screen['nonce'] ); 426 } 427 416 428 printf( 417 429 '<input type="hidden" name="group-id" id="group-id" value="%s" />', 418 430 $is_group_create ? esc_attr( bp_get_new_group_id() ) : esc_attr( bp_get_group_id() ) … … function bp_nouveau_group_manage_screen() { 437 449 */ 438 450 do_action( 'bp_directory_groups_content' ); 439 451 } 452 453 /** 454 * Avoid nested forms with the Backbone views for the group invites step. 455 */ 456 if ( 'group-invites' === bp_get_groups_current_create_step() ) { 457 echo '</form>'; 458 } 440 459 } 441 460 442 461 /** -
src/bp-templates/bp-nouveau/includes/template-tags.php
diff --git src/bp-templates/bp-nouveau/includes/template-tags.php src/bp-templates/bp-nouveau/includes/template-tags.php index 6c6b44c64..79d4c3215 100644
function bp_nouveau_single_item_subnav_classes() { 1593 1593 $classes[] = 'group-subnav'; 1594 1594 } 1595 1595 1596 if ( bp_is_group() && 'send-invites' === bp_current_action() ) {1596 if ( ( bp_is_group() && 'send-invites' === bp_current_action() ) || ( bp_is_group_create() && 'group-invites' === bp_get_groups_current_create_step() ) ) { 1597 1597 $classes[] = 'bp-invites-nav'; 1598 1598 } 1599 1599