Add no product option to product count dropdown (https://github.com/woocommerce/woocommerce-admin/pull/3092)

This commit is contained in:
Joshua T Flowers 2019-10-24 07:33:10 +08:00 committed by GitHub
parent c678421b63
commit 38c9e38e28
2 changed files with 5 additions and 0 deletions

View File

@ -246,6 +246,10 @@ class BusinessDetails extends Component {
render() {
const { isInstallingExtensions, extensionInstallError } = this.state;
const productCountOptions = [
{
key: '0',
label: __( "I don't have any products yet.", 'woocommerce-admin' ),
},
{
key: '1-10',
label: this.getNumberRangeString( 1, 10 ),

View File

@ -266,6 +266,7 @@ class OnboardingProfile extends \WC_REST_Data_Controller {
'readonly' => true,
'validate_callback' => 'rest_validate_request_arg',
'enum' => array(
'0',
'1-10',
'11-100',
'101-1000',