Fix autocompleters in customers and taxes report (https://github.com/woocommerce/woocommerce-admin/pull/1458)
This commit is contained in:
parent
fb0d71f117
commit
9dd4c10d7d
|
@ -103,7 +103,7 @@ describe( 'Leaderboard', () => {
|
||||||
);
|
);
|
||||||
const leaderboard = leaderboardWrapper.root.findByType( Leaderboard );
|
const leaderboard = leaderboardWrapper.root.findByType( Leaderboard );
|
||||||
|
|
||||||
const endpoint = NAMESPACE + 'reports/products';
|
const endpoint = NAMESPACE + '/reports/products';
|
||||||
const query = { orderby: 'items_sold', per_page: 5, extended_info: 1 };
|
const query = { orderby: 'items_sold', per_page: 5, extended_info: 1 };
|
||||||
|
|
||||||
expect( getReportStatsMock.mock.calls[ 0 ][ 1 ] ).toBe( endpoint );
|
expect( getReportStatsMock.mock.calls[ 0 ][ 1 ] ).toBe( endpoint );
|
||||||
|
|
|
@ -57,7 +57,7 @@ export const advancedFilters = {
|
||||||
input: {
|
input: {
|
||||||
component: 'Search',
|
component: 'Search',
|
||||||
type: 'customers',
|
type: 'customers',
|
||||||
getLabels: getRequestByIdString( NAMESPACE + 'customers', customer => ( {
|
getLabels: getRequestByIdString( NAMESPACE + '/customers', customer => ( {
|
||||||
id: customer.id,
|
id: customer.id,
|
||||||
label: [ customer.first_name, customer.last_name ].filter( Boolean ).join( ' ' ),
|
label: [ customer.first_name, customer.last_name ].filter( Boolean ).join( ' ' ),
|
||||||
} ) ),
|
} ) ),
|
||||||
|
@ -157,7 +157,7 @@ export const advancedFilters = {
|
||||||
input: {
|
input: {
|
||||||
component: 'Search',
|
component: 'Search',
|
||||||
type: 'emails',
|
type: 'emails',
|
||||||
getLabels: getRequestByIdString( NAMESPACE + 'customers', customer => ( {
|
getLabels: getRequestByIdString( NAMESPACE + '/customers', customer => ( {
|
||||||
id: customer.id,
|
id: customer.id,
|
||||||
label: customer.email,
|
label: customer.email,
|
||||||
} ) ),
|
} ) ),
|
||||||
|
|
|
@ -49,7 +49,7 @@ export const filters = [
|
||||||
settings: {
|
settings: {
|
||||||
type: 'taxes',
|
type: 'taxes',
|
||||||
param: 'taxes',
|
param: 'taxes',
|
||||||
getLabels: getRequestByIdString( NAMESPACE + 'taxes', tax => ( {
|
getLabels: getRequestByIdString( NAMESPACE + '/taxes', tax => ( {
|
||||||
id: tax.id,
|
id: tax.id,
|
||||||
label: getTaxCode( tax ),
|
label: getTaxCode( tax ),
|
||||||
} ) ),
|
} ) ),
|
||||||
|
|
Loading…
Reference in New Issue