Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release branch for 7.1.0 #8056

Merged
merged 61 commits into from
Jan 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
c39d1af
Fix broken dispute details UI (#7959)
Jinksi Jan 2, 2024
8af9441
Remove URL params from woopay_source_url (#7924)
malithsen Jan 2, 2024
b59d3d2
Track payment request button load events (#7919)
malithsen Jan 2, 2024
a80913f
Merge trunk v7.0.0 into develop
botwoo Jan 3, 2024
08a145b
Add Tracks to Place Order button (#7854)
malithsen Jan 3, 2024
cdbb1d1
Send metadata in the error message (#7951)
hsingyuc Jan 3, 2024
9e30129
Avoid WooPay duplicate charges when order cannot be completely proces…
cesarcosta99 Jan 4, 2024
2a86138
Hide the transaction details refund menu for non-refundable disputes …
Jinksi Jan 4, 2024
c56dbcf
Fix missing transaction error when viewing orders placed in mismatche…
Jinksi Jan 5, 2024
c02877a
Fix the typo for transaction controls label (#7979)
KarlisJ Jan 5, 2024
fc29bee
Fix unnecessary gateway import warning in BNPL messaging element clas…
timur27 Jan 5, 2024
439ec44
Expose WCPay refund transaction id for refund endpoint (#7932)
dpaun1985 Jan 5, 2024
e37aa7d
Rerender Woopay Button on jQuery Events (#7981)
lovo-h Jan 8, 2024
14b37a2
Fix WooPay tablet breakpoint (#7985)
alefesouza Jan 8, 2024
7b71828
Use shared dispute utility function `isRefundable` for disputed order…
Jinksi Jan 8, 2024
2eae9af
Update underlying jetpack dependencies (#7989)
deepakpathania Jan 9, 2024
6610e65
Restock order items when refunding in full from transaction details p…
KarlisJ Jan 9, 2024
16dac06
Fix Link button alignment in the Checkout block (#7994)
mdmoore Jan 9, 2024
8cfa008
Add theme name to compatibility service (#7952)
tpaksu Jan 10, 2024
3919df5
Verify that order exists before offering "Partial refund" option on t…
dmvrtx Jan 10, 2024
64ef715
Add active plugin list to compatibility service (#7933)
allie500 Jan 11, 2024
4487bb0
Fix JS error when purchasing free products (#7982)
malithsen Jan 11, 2024
ba86be4
Add e2e test for dispute flow: viewing dispute details via the order …
Jinksi Jan 12, 2024
880bfea
fix: pay for order 3DS handling (#8006)
frosso Jan 12, 2024
352cff0
Fix Dropdown menu border defect (#8007)
mgascam Jan 12, 2024
dd6f5fe
chore: update BNPL settings sorting for consistency with onboarding (…
frosso Jan 12, 2024
c36cc13
Getting settings directly from the db in Mode (#8003)
gpressutto5 Jan 12, 2024
6bf63af
Add new Tracks around WooPay Save My Info checkbox (#7973)
malithsen Jan 12, 2024
48c3a5d
Pass currency and do not pass transaction_ids parameter to create ins…
shendy-a8c Jan 15, 2024
805cba8
Compatibility Service: Send the post type count (#8000)
allie500 Jan 15, 2024
f8a4897
Displaying Clearpay instead of Afterpay for UK based stores (#7995)
gpressutto5 Jan 15, 2024
983a472
Fix WooPay Adapted Extensions initialization (#7986)
alefesouza Jan 16, 2024
e157a1c
Prevent possible fatal when using `get_edit_post_link` filter (#8023)
cesarcosta99 Jan 16, 2024
f63d75f
Allow issue of zero amount refunds (#8013)
dmvrtx Jan 16, 2024
1156673
fix: Stripe Link autofill on checkout (#8021)
frosso Jan 17, 2024
5c25d7f
Revert "Displaying Clearpay instead of Afterpay for UK based stores" …
jessepearson Jan 17, 2024
f00749a
Show Payments → Overview waiting period notice for new accounts that …
Jinksi Jan 18, 2024
3877aef
Switch to proper input element when using Stripe Link autofill (#8017)
timur27 Jan 18, 2024
173b56d
Store balance transaction ID in order metadata (#7945)
anu-rock Jan 18, 2024
861cb06
Checking if wcpayPaymentRequestPayForOrderParams before using it (#8014)
gpressutto5 Jan 18, 2024
a0cbc73
Getting settings directly from the db in Logger (#8038)
gpressutto5 Jan 18, 2024
1fc5474
Allow subscription purchase via Payment Request when no shipping meth…
mdmoore Jan 18, 2024
627850e
Improve disputed order notice so is more readable and actionable (and…
haszari Jan 18, 2024
ca1d5a0
Show the correct number of days in the new account waiting period not…
Jinksi Jan 18, 2024
98f728b
Use consistent inline notice style for deposit settings notices (#8042)
Jinksi Jan 19, 2024
a7904e5
Updates the version of subscriptions-core bundled in WooPayments to 6…
mattallan Jan 19, 2024
06ccfd5
Merge split UPE tests with main gateway tests (#7954)
timur27 Jan 19, 2024
c576435
Add events for interactions with transactions page (#8020)
dpaun1985 Jan 19, 2024
945c672
Fix incorrect test mode notice when left KYC early after going live f…
oaratovskyi Jan 19, 2024
ef84865
Fix reverse WPCOM url in Safe Mode (#8033)
oaratovskyi Jan 19, 2024
e375e8b
Update Dev/Sandbox Mode Choice Design (#8002)
dmallory42 Jan 19, 2024
5a1d4b9
Add ENUM class for country codes (#7925)
zmaglica Jan 19, 2024
f1af5a8
Update PO success modal (#8005)
ismaeldcom Jan 19, 2024
fd41bcc
Fix failing E2E pipelines (#8048)
timur27 Jan 19, 2024
21a024b
Updates to use centralised account status function (#8028)
dmallory42 Jan 19, 2024
8f6b267
Update dev mode to Sandbox mode throughout the plugin (#8004)
dmallory42 Jan 20, 2024
18914b9
Update version and add changelog entries for release 7.1.0
github-actions[bot] Jan 21, 2024
bb80890
Address QIT security errors (#8060)
mgascam Jan 23, 2024
aa38eca
Amend changelog entries for release 7.1.0
botwoo Jan 23, 2024
d65a7b9
Amend changelog entries for release 7.1.0
botwoo Jan 23, 2024
30e54c5
Amend changelog entries for release 7.1.0
botwoo Jan 25, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions .github/workflows/e2e-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,8 @@ jobs:
strategy:
fail-fast: false
matrix:
test_groups: [ 'wcpay', 'subscriptions', 'upe', 'upeSplit' ] # [TODO] Unskip blocks tests after investigating constant failures.
test_groups: [ 'wcpay', 'subscriptions' ] # [TODO] Unskip blocks tests after investigating constant failures.
test_branches: [ 'merchant', 'shopper' ]
exclude:
- test_groups: 'upe'
test_branches: 'merchant'
- test_groups: 'upeSplit'
test_branches: 'merchant'

name: WC - latest | ${{ matrix.test_groups }} - ${{ matrix.test_branches }}

Expand Down
6 changes: 1 addition & 5 deletions .github/workflows/e2e-tests-atomic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,12 @@ jobs:
fail-fast: false
max-parallel: 1
matrix:
test_groups: [ 'wcpay', 'subscriptions', 'upe', 'upeSplit' ]
test_groups: [ 'wcpay', 'subscriptions' ]
test_branches: [ 'merchant', 'shopper' ]
exclude:
- test_groups: 'subscriptions'
- test_groups: 'wcpay'
test_branches: 'merchant'
- test_groups: 'upe'
test_branches: 'merchant'
- test_groups: 'upeSplit'
test_branches: 'merchant'

env:
E2E_GROUP: ${{ matrix.test_groups }}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ We currently support the following variables:

## Test account setup

For setting up a test account follow [these instructions](https://woo.com/document/woopayments/testing-and-troubleshooting/dev-mode/).
For setting up a test account follow [these instructions](https://woo.com/document/woopayments/testing-and-troubleshooting/sandbox-mode/).

You will need a externally accessible URL to set up the plugin. You can use ngrok for this.

Expand Down
1 change: 0 additions & 1 deletion assets/images/illustrations/po-eligibility.svg

This file was deleted.

49 changes: 49 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,54 @@
*** WooPayments Changelog ***

= 7.1.0 - 2024-01-25 =
* Add - Add active plugins array to compatibility data.
* Add - Add post_types and their counts as an array to compatibility data.
* Add - Add the active theme name of the blog to the compatibility service
* Add - Expose the refund transaction ID in WooCommerce Order Refund API
* Add - Select the proper payment element when using saved Stripe Link tokens or choosing to use Stripe Link for new email.
* Add - Track filtering interactions on the Transactions page.
* Fix - Allow subscription purchase via Payment Request when no shipping methods are present.
* Fix - Allow zero-amount refunds for backwards compatibility with basic payment gateway and to allow re-stock of refunded orders.
* Fix - Checking if wcpayPaymentRequestPayForOrderParams before using it in Pay for Order page
* Fix - Checkout error when page URL is too long
* Fix - Comment: Fix QIT security tests errors.
* Fix - Fix incorrect test mode notice when left KYC early after going live from builder mode
* Fix - Fix network error that occurs when viewing an test mode order with test mode disabled, and vice versa.
* Fix - fix pay-for-order quirks and 3DS behavior
* Fix - Fix Safe Mode message reversed host
* Fix - Fix Stripe Link autofill on checkout.
* Fix - Fix Stripe Link button alignment in the Checkout Block
* Fix - Hide the transaction details refund menu for ineligble disputed transactions
* Fix - Improve clarity & readability of disputed order notice (not all text bold).
* Fix - Prevent possible fatal when using get_edit_post_link filter.
* Fix - Re-render WooPay button when cart updates, when checkout updates.
* Fix - Reinstate first deposit waiting period notice in payments overview (fix bug)
* Fix - Remove unnecessary import statement which leads to a warning when first loaded
* Fix - Resolved an error that would occur with WC 8.5.0 when editing a subscription customer from the admin dashboard.
* Fix - Resolved an issue that caused ordering the Admin Subscriptions List Table to not work when HPOS is enabled.
* Fix - Restock order items when performing full refund from transaction details page
* Fix - Reverting to manual styling over native WordPress components to fix CSS defects on Analytics page
* Fix - Send metadata in error message
* Fix - Show the correct number of days in the new account waiting period notice.
* Fix - Update WooPay tablet breakpoint.
* Fix - Verify that order exists before offering "Partial refund" option on transaction details page.
* Update - Changed the edit subscription product "Expire after" (Subscription length) so it more clearly describes when a subscription will automatically stop renewing.
* Update - Pass currency parameter and not transaction_ids parameter when creating instant deposit.
* Update - Store balance transaction ID in order metadata.
* Update - Updated BNPL sorting in settings for consistency with onboarding.
* Update - Update references to dev mode to use sandbox mode terminology.
* Update - Updates to the styling of the onboarding mode selection page.
* Update - Update style of notices within the deposits section of the settings screen.
* Dev - Added enum class for country codes
* Dev - Add new Tracks events to WooPay Save My Info checkbox
* Dev - Allow test pipelines to pass by slightly adjusting HTML selectors
* Dev - Merge UPE tests into the single and main gateway test file for unit and E2E tests.
* Dev - Place order button Tracks
* Dev - Track payment-request-button loads
* Dev - Update jetpack dependencies for syncing.
* Dev - Updates to account status logic to streamline it.
* Dev - Update subscriptions-core to 6.7.1.

= 7.0.0 - 2024-01-03 =
* Add - Add Account Management tools with reset account functionality for partially onboarded accounts.
* Add - Adding Compatibility Service to assist with flagging possible compatibility issues in the future.
Expand Down
1 change: 1 addition & 0 deletions client/checkout/api/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ export default class WCPayAPI {
if ( ! this.stripe ) {
let betas = [ 'card_country_event_beta_1' ];
if ( isStripeLinkEnabled ) {
// https://stripe.com/docs/payments/link/autofill-modal
betas = betas.concat( [ 'link_autofill_modal_beta_1' ] );
}

Expand Down
20 changes: 20 additions & 0 deletions client/checkout/blocks/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ import {
} from '../constants.js';
import { getDeferredIntentCreationUPEFields } from './payment-elements';
import { handleWooPayEmailInput } from '../woopay/email-input-iframe';
import wcpayTracks from 'tracks';
import wooPayExpressCheckoutPaymentMethod from '../woopay/express-button/woopay-express-checkout-payment-method';
import { isPreviewing } from '../preview';

Expand Down Expand Up @@ -113,6 +114,24 @@ Object.entries( enabledPaymentMethodsConfig )
} );
} );

const addCheckoutTracking = () => {
const placeOrderButton = document.getElementsByClassName(
'wc-block-components-checkout-place-order-button'
);
if ( placeOrderButton.length ) {
placeOrderButton[ 0 ].addEventListener( 'click', () => {
const blocksCheckbox = document.getElementById(
'radio-control-wc-payment-method-options-woocommerce_payments'
);
if ( ! blocksCheckbox?.checked ) {
return;
}

wcpayTracks.recordUserEvent( wcpayTracks.events.PLACE_ORDER_CLICK );
} );
}
};

// Call handleWooPayEmailInput if woopay is enabled and this is the checkout page.
if ( getUPEConfig( 'isWooPayEnabled' ) ) {
if (
Expand All @@ -131,4 +150,5 @@ if ( getUPEConfig( 'isWooPayEnabled' ) ) {
registerExpressPaymentMethod( paymentRequestPaymentMethod( api ) );
window.addEventListener( 'load', () => {
enqueueFraudScripts( getUPEConfig( 'fraudServices' ) );
addCheckoutTracking();
} );
96 changes: 45 additions & 51 deletions client/checkout/blocks/payment-processor.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ import {
import enableStripeLinkPaymentMethod from 'wcpay/checkout/stripe-link';
import { getUPEConfig } from 'wcpay/utils/checkout';
import { validateElements } from 'wcpay/checkout/classic/payment-processing';
import {
BLOCKS_SHIPPING_ADDRESS_FIELDS,
BLOCKS_BILLING_ADDRESS_FIELDS,
} from '../constants';

const getBillingDetails = ( billingData ) => {
return {
Expand Down Expand Up @@ -74,66 +70,64 @@ const PaymentProcessor = ( {
const paymentMethodsConfig = getUPEConfig( 'paymentMethodsConfig' );
const isTestMode = getUPEConfig( 'testMode' );
const gatewayConfig = getPaymentMethods()[ upeMethods[ paymentMethodId ] ];
const customerData = useCustomerData();
const billingData = customerData.billingAddress;
const {
billingAddress: billingData,
setShippingAddress,
setBillingAddress,
} = useCustomerData();

useEffect( () => {
if ( isLinkEnabled( paymentMethodsConfig ) ) {
enableStripeLinkPaymentMethod( {
api: api,
elements: elements,
emailId: 'email',
fill_field_method: ( address, nodeId, key ) => {
const setAddress =
BLOCKS_SHIPPING_ADDRESS_FIELDS[ key ] === nodeId
? customerData.setShippingAddress
: customerData.setBillingData ||
customerData.setBillingAddress;
const customerAddress =
BLOCKS_SHIPPING_ADDRESS_FIELDS[ key ] === nodeId
? customerData.shippingAddress
: customerData.billingData ||
customerData.billingAddress;

if ( key === 'line1' ) {
customerAddress.address_1 = address.address[ key ];
} else if ( key === 'line2' ) {
customerAddress.address_2 = address.address[ key ];
} else if ( key === 'postal_code' ) {
customerAddress.postcode = address.address[ key ];
} else {
customerAddress[ key ] = address.address[ key ];
onAutofill: ( billingAddress, shippingAddress ) => {
// in some cases (e.g.: customer doesn't select the payment method in the Link modal), the billing address is empty.
if ( billingAddress ) {
// setting the country first, in case the "state"/"county"/"province"
// select changes from a select to a text field (or vice-versa).
setBillingAddress( {
country: billingAddress.country,
} );
// after the country, we can safely set the other fields
setBillingAddress( {
...billingAddress,
} );
}

setAddress( customerAddress );

if ( customerData.billingData ) {
customerData.billingData.email = getBlocksEmailValue();
customerData.setBillingData( customerData.billingData );
} else {
customerData.billingAddress.email = getBlocksEmailValue();
customerData.setBillingAddress(
customerData.billingAddress
);
// in some cases (e.g.: customer doesn't select the shipping address method in the Link modal),
// the shipping address is empty.
if ( shippingAddress ) {
// setting the country first, in case the "state"/"county"/"province"
// select changes from a select to a text field (or vice-versa).
setShippingAddress( {
country: shippingAddress.country,
} );
// after the country, we can safely set the other fields
setShippingAddress( {
...shippingAddress,
} );
}

// after all the above, we can now set the email field by getting its value from the DOM.
setBillingAddress( {
email: getBlocksEmailValue(),
} );
setShippingAddress( {
email: getBlocksEmailValue(),
} );
},
show_button: blocksShowLinkButtonHandler,
shipping_fields: BLOCKS_SHIPPING_ADDRESS_FIELDS,
billing_fields: BLOCKS_BILLING_ADDRESS_FIELDS,
complete_shipping: () => {
return (
document.getElementById( 'shipping-address_1' ) !== null
);
},
complete_billing: () => {
return (
document.getElementById( 'billing-address_1' ) !== null
);
},
onButtonShow: blocksShowLinkButtonHandler,
} );
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [ elements ] );
}, [
api,
elements,
paymentMethodsConfig,
setBillingAddress,
setShippingAddress,
] );

useEffect(
() =>
Expand Down
Loading
Loading