Fix/some outstanding CES bugs (https://github.com/woocommerce/woocommerce-admin/pull/5739)
* fix settings change enqueue params * Include comments in score record callback * send empty string for comments Co-authored-by: Rebecca Scott <me@becdetat.com>
This commit is contained in:
parent
b4e309f964
commit
cc5e500085
|
@ -98,10 +98,11 @@ function CustomerEffortScoreTracks( {
|
||||||
} );
|
} );
|
||||||
};
|
};
|
||||||
|
|
||||||
const recordScore = ( score ) => {
|
const recordScore = ( score, comments ) => {
|
||||||
recordEvent( 'ces_feedback', {
|
recordEvent( 'ces_feedback', {
|
||||||
action,
|
action,
|
||||||
score,
|
score,
|
||||||
|
comments: comments || '',
|
||||||
store_age: storeAge,
|
store_age: storeAge,
|
||||||
...trackProps,
|
...trackProps,
|
||||||
} );
|
} );
|
||||||
|
@ -153,7 +154,6 @@ CustomerEffortScoreTracks.propTypes = {
|
||||||
* Whether tracking is allowed or not.
|
* Whether tracking is allowed or not.
|
||||||
*/
|
*/
|
||||||
allowTracking: PropTypes.bool,
|
allowTracking: PropTypes.bool,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Whether props are still being resolved.
|
* Whether props are still being resolved.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -369,9 +369,10 @@ class CustomerEffortScoreTracks {
|
||||||
'How easy was it to update your settings?',
|
'How easy was it to update your settings?',
|
||||||
'woocommerce-admin'
|
'woocommerce-admin'
|
||||||
),
|
),
|
||||||
|
'onsubmit_label' => $this->onsubmit_label,
|
||||||
'pagenow' => 'woocommerce_page_wc-settings',
|
'pagenow' => 'woocommerce_page_wc-settings',
|
||||||
'adminpage' => 'woocommerce_page_wc-settings',
|
'adminpage' => 'woocommerce_page_wc-settings',
|
||||||
'props' => array(),
|
'props' => (object) array(),
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue