[Grouped products] Create product-grouped feature flag (#41639)

* Create product-grouped feature flag

* Add support to the product editor to handle grouped product types as well

* Add changelog file
This commit is contained in:
Maikel David Pérez Gómez 2023-11-23 13:24:51 -03:00 committed by GitHub
parent 4a0db06321
commit 829ca23326
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 11 additions and 0 deletions

View File

@ -23,6 +23,7 @@ declare global {
'product-variation-management': boolean;
'product-virtual-downloadable': boolean;
'product-external-affiliate': boolean;
'product-grouped': boolean;
'remote-inbox-notifications': boolean;
'remote-free-extensions': boolean;
settings: boolean;

View File

@ -0,0 +1,4 @@
Significance: minor
Type: add
Add support to the product editor to handle grouped product types as well

View File

@ -22,6 +22,7 @@
"product-variation-management": true,
"product-virtual-downloadable": true,
"product-external-affiliate": false,
"product-grouped": false,
"remote-inbox-notifications": true,
"remote-free-extensions": true,
"payment-gateway-suggestions": true,

View File

@ -23,6 +23,7 @@
"product-variation-management": true,
"product-virtual-downloadable": true,
"product-external-affiliate": true,
"product-grouped": true,
"remote-inbox-notifications": true,
"remote-free-extensions": true,
"settings": false,

View File

@ -49,6 +49,10 @@ class Init {
array_push( $this->supported_post_types, 'external' );
}
if ( Features::is_enabled( 'product-grouped' ) ) {
array_push( $this->supported_post_types, 'grouped' );
}
$this->redirection_controller = new RedirectionController( $this->supported_post_types );
if ( \Automattic\WooCommerce\Utilities\FeaturesUtil::feature_is_enabled( 'product_block_editor' ) ) {