Don't show variations table when there is an active search (https://github.com/woocommerce/woocommerce-admin/pull/1601)
This commit is contained in:
parent
1660484d4c
commit
0a10291969
|
@ -133,7 +133,8 @@ export default compose(
|
||||||
withSelect( ( select, props ) => {
|
withSelect( ( select, props ) => {
|
||||||
const { query } = props;
|
const { query } = props;
|
||||||
const { getItems, isGetItemsRequesting, getItemsError } = select( 'wc-api' );
|
const { getItems, isGetItemsRequesting, getItemsError } = select( 'wc-api' );
|
||||||
const isSingleProductView = query.products && 1 === query.products.split( ',' ).length;
|
const isSingleProductView =
|
||||||
|
! query.search && query.products && 1 === query.products.split( ',' ).length;
|
||||||
if ( isSingleProductView ) {
|
if ( isSingleProductView ) {
|
||||||
const productId = parseInt( query.products );
|
const productId = parseInt( query.products );
|
||||||
const includeArgs = { include: productId };
|
const includeArgs = { include: productId };
|
||||||
|
|
Loading…
Reference in New Issue