Onboarding: Format product count ranges numbers without decimals (https://github.com/woocommerce/woocommerce-admin/pull/3316)
* Format product count ranges numbers without decimals * Don't pass format method as argument to getNumberRangeString
This commit is contained in:
parent
fa2ab220c9
commit
7e2aa85235
|
@ -12,7 +12,7 @@ import { keys, get, pickBy } from 'lodash';
|
|||
/**
|
||||
* WooCommerce dependencies
|
||||
*/
|
||||
import { numberFormat } from 'lib/number-format';
|
||||
import { formatValue } from 'lib/number-format';
|
||||
import { getSetting, CURRENCY as currency } from '@woocommerce/wc-admin-settings';
|
||||
|
||||
/**
|
||||
|
@ -138,18 +138,18 @@ class BusinessDetails extends Component {
|
|||
return keys( pickBy( values ) ).filter( name => this.extensions.includes( name ) );
|
||||
}
|
||||
|
||||
getNumberRangeString( min, max = false, format = numberFormat ) {
|
||||
getNumberRangeString( min, max = false ) {
|
||||
if ( ! max ) {
|
||||
return sprintf(
|
||||
_x( '%s+', 'store product count or revenue', 'woocommerce-admin' ),
|
||||
format( min )
|
||||
formatValue( 'number', min )
|
||||
);
|
||||
}
|
||||
|
||||
return sprintf(
|
||||
_x( '%1$s - %2$s', 'store product count or revenue range', 'woocommerce-admin' ),
|
||||
format( min ),
|
||||
format( max )
|
||||
formatValue( 'number', min ),
|
||||
formatValue( 'number', max )
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue