Changeset 1891
- Timestamp:
- 09/16/2009 09:23:40 PM (16 years ago)
- Location:
- trunk
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-activity.php
r1882 r1891 226 226 227 227 $defaults = array( 228 'user_id' => $bp->loggedin_user->id, 229 'content' => false, 230 'primary_link' => false, 231 'component_name' => false, 232 'component_action' => false, 233 'item_id' => false, 234 'secondary_item_id' => false, 235 'recorded_time' => time(), 236 'hide_sitewide' => false 228 'user_id' => $bp->loggedin_user->id, // The user to record the activity for 229 'content' => false, // The content of the activity item 230 'primary_link' => false, // The primary URL for this item in RSS feeds 231 'component_name' => false, // The name/ID of the component e.g. groups, profile, mycomponent 232 'component_action' => false, // The component action e.g. new_wire_post, profile_updated 233 'item_id' => false, // Optional: The ID of the specific item being recorded, e.g. a blog_id, or wire_post_id 234 'secondary_item_id' => false, // Optional: A second ID used to further filter e.g. a comment_id 235 'recorded_time' => time(), // The time that this activity was recorded 236 'hide_sitewide' => false // Should this be hidden on the sitewide activity stream? 237 237 ); 238 238 -
trunk/bp-core.php
r1887 r1891 325 325 global $bp; 326 326 327 if ( !function_exists('xprofile_install') ) { 327 /*** 328 * If the extended profiles component is disabled, we need to revert to using the 329 * built in WordPress profile information 330 */ 331 if ( !function_exists( 'xprofile_install' ) ) { 332 /* Fallback wire values if xprofile is disabled */ 333 $bp->core->profile->slug = 'profile'; 334 $bp->active_components[$bp->core->profile->slug] = $bp->core->profile->slug; 335 328 336 /* Add 'Profile' to the main navigation */ 329 bp_core_add_nav_item( __('Profile', 'buddypress'), 'profile' ); 330 bp_core_add_nav_default( 'profile', 'bp_core_catch_profile_uri', 'public' ); 337 bp_core_new_nav_item( array( 338 'name' => __('Profile', 'buddypress'), 339 'slug' => $bp->core->profile->slug, 340 'position' => 20, 341 'screen_function' => 'bp_core_catch_profile_uri', 342 'default_subnav_slug' => 'public' 343 ) ); 331 344 332 345 $profile_link = $bp->loggedin_user->domain . '/profile/'; 333 346 334 347 /* Add the subnav items to the profile */ 335 348 bp_core_new_subnav_item( array( … … 337 350 'slug' => 'public', 338 351 'parent_url' => $profile_link, 339 'parent_slug' => 'profile', 340 'screen_function' => 'xprofile_screen_display_profile', 341 'position' => 10 352 'parent_slug' => $bp->core->profile->slug, 353 'screen_function' => 'bp_core_catch_profile_uri' 342 354 ) ); 355 343 356 344 357 if ( 'profile' == $bp->current_component ) { -
trunk/bp-groups.php
r1878 r1891 2211 2211 } 2212 2212 2213 function groups_invite_user( $user_id, $group_id ) { 2214 global $bp; 2213 function groups_invite_user( $args = '' ) { 2214 global $bp; 2215 2216 $defaults = array( 2217 'user_id' => false, 2218 'group_id' => false, 2219 'inviter_id' => $bp->loggedin_user->id, 2220 'date_modified' => time(), 2221 'is_confirmed' => 0 2222 ); 2223 2224 $args = wp_parse_args( $args, $defaults ); 2225 extract( $args, EXTR_SKIP ); 2226 2227 if ( !$user_id || !$group_id ) 2228 return false; 2215 2229 2216 2230 if ( groups_is_user_member( $user_id, $group_id ) ) … … 2220 2234 $invite->group_id = $group_id; 2221 2235 $invite->user_id = $user_id; 2222 $invite->date_modified = time();2223 $invite->inviter_id = $ bp->loggedin_user->id;2224 $invite->is_confirmed = 0;2236 $invite->date_modified = $date_modified; 2237 $invite->inviter_id = $inviter_id; 2238 $invite->is_confirmed = $is_confirmed; 2225 2239 2226 2240 if ( !$invite->save() ) 2227 2241 return false; 2228 2242 2229 do_action( 'groups_invite_user', $ group_id, $user_id);2243 do_action( 'groups_invite_user', $args ); 2230 2244 2231 2245 return true; 2232 2246 } 2233 2247 2234 function groups_uninvite_user( $user_id, $group_id , $deprecated = true) {2248 function groups_uninvite_user( $user_id, $group_id ) { 2235 2249 global $bp; 2236 2250 -
trunk/bp-groups/deprecated/bp-groups-deprecated.php
r1834 r1891 636 636 if ( 'invite' == $_POST['friend_action'] ) { 637 637 638 if ( !groups_invite_user( $_POST['friend_id'], $_POST['group_id']) )638 if ( !groups_invite_user( array( 'user_id' => $_POST['friend_id'], 'group_id' => $_POST['group_id'] ) ) ) 639 639 return false; 640 640 -
trunk/bp-themes/bp-default/_inc/css/screen.css
r1876 r1891 1972 1972 /**** PROFILES ************************/ 1973 1973 1974 table.profile-fields tr.alt {1974 table.profile-fields tr.alt, table.wp-profile-fields tr.alt { 1975 1975 background: #f0f0f0; 1976 1976 } 1977 1977 1978 table.profile-fields tr td.label {1978 table.profile-fields tr td.label, table.wp-profile-fields tr td.label { 1979 1979 border-right: 1px solid #dadada; 1980 1980 font-weight: bold; … … 1985 1985 } 1986 1986 1987 table.profile-fields {1987 table.profile-fields, table.wp-profile-fields { 1988 1988 width: 100%; 1989 1989 } 1990 table.profile-fields tr td {1990 table.profile-fields tr td, table.wp-profile-fields tr td { 1991 1991 padding: 0.5em 1em; 1992 1992 } 1993 1993 1994 table.profile-fields tr td.label {1994 table.profile-fields tr td.label, table.wp-profile-fields tr td.label { 1995 1995 width: 130px; 1996 1996 } -
trunk/bp-themes/bp-sn-parent/_inc/ajax.php
r1745 r1891 80 80 if ( 'invite' == $_POST['friend_action'] ) { 81 81 82 if ( !groups_invite_user( $_POST['friend_id'], $_POST['group_id']) )82 if ( !groups_invite_user( array( 'user_id' => $_POST['friend_id'], 'group_id' => $_POST['group_id'] ) ) ) 83 83 return false; 84 84 -
trunk/bp-themes/bp-sn-parent/profile/index.php
r1871 r1891 128 128 129 129 <?php /* Profile Wire Loop - uses [TEMPLATEPATH]/wire/post-list.php */ ?> 130 <?php if ( function_exists('bp_wire_get_post_list') ) : ?>130 <?php if ( function_exists('bp_wire_get_post_list') && function_exists( 'xprofile_install' ) ) : ?> 131 131 132 132 <?php do_action( 'bp_before_profile_wire_widget' ) ?> -
trunk/bp-wire.php
r1809 r1891 34 34 global $bp; 35 35 36 /* Profile wire's will only work if xprofile is enabled */ 37 if ( !function_exists( 'xprofile_install' ) ) 38 return false; 39 36 40 /* Add 'Wire' to the main navigation */ 37 41 bp_core_new_nav_item( array( 'name' => __('Wire', 'buddypress'), 'slug' => $bp->wire->slug, 'position' => 40, 'screen_function' => 'bp_wire_screen_latest', 'default_subnav_slug' => 'all-posts', 'item_css_id' => $bp->wire->id ) );
Note: See TracChangeset
for help on using the changeset viewer.