Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
02/24/2023 09:37:44 AM (21 months ago)
Author:
imath
Message:

Use a custom post type instead of the page post type for directories

  • The buddypress post type is now the one used for the BP component

directory page.

  • Introduce the bp_core_set_unique_directory_page_slug() function to

make sure there is no conflict with an existing WP page when setting the
BP Component directory page post_name.

  • Introduce the bp_restricted custom status. We'll be able to use it for

future visibility features.

  • Deprecate the Admin Slugs screen and corresponding functions
  • Bump raw_db_version to 13422 (the first commit about merging BP

Rewrites).

  • Add an update function to update the post type of the existing BP

component directory pages and potential WP Nav Menus including these.

Props r-a-y, johnjamesjacoby, boonebgorges

Closes https://github.com/buddypress/buddypress/pull/67
See #4954

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/testcases/core/functions.php

    r13417 r13431  
    566566        restore_current_blog();
    567567
    568         $this->assertFalse( wp_cache_get( 'directory_pages', 'bp' ) );
     568        $this->assertFalse( wp_cache_get( 'directory_pages', 'bp_pages' ) );
    569569    }
    570570
     
    631631
    632632    /**
    633      * @group bp_core_add_root_component
    634      */
    635     public function test_add_root_component_not_in_bp_pages() {
    636         buddypress()->foo = new stdClass;
    637         buddypress()->foo->id = 'foo';
    638         buddypress()->foo->slug = 'foo';
    639 
    640         bp_core_add_root_component( 'foo' );
    641 
    642         $this->assertTrue( in_array( 'foo', buddypress()->add_root ) );
    643         $this->assertTrue( buddypress()->foo->has_directory );
    644         $this->assertNotEmpty( buddypress()->loaded_components['foo'] );
    645     }
    646 
    647     /**
    648633     * @group bp_core_time_since
    649634     * @group bp_core_current_time
     
    841826    /**
    842827     * @group bp_core_add_page_mappings
    843      * @ticket 8187
     828     * @ticket BP8187
    844829     */
    845830    public function test_bp_core_add_page_mappings_in_multisite_subdirectory() {
Note: See TracChangeset for help on using the changeset viewer.