diff --git a/changelog/add-7289-remove-transaction-dispute-details-feature-flag b/changelog/add-7289-remove-transaction-dispute-details-feature-flag new file mode 100644 index 00000000000..4f7ee73ac77 --- /dev/null +++ b/changelog/add-7289-remove-transaction-dispute-details-feature-flag @@ -0,0 +1,4 @@ +Significance: major +Type: add + +Display dispute information, recommended resolution steps, and actions directly on the transaction details screen to help merchants with dispute resolution. diff --git a/client/globals.d.ts b/client/globals.d.ts index c81c7ab4181..54d56edfc7d 100644 --- a/client/globals.d.ts +++ b/client/globals.d.ts @@ -15,7 +15,6 @@ declare global { customSearch: boolean; isAuthAndCaptureEnabled: boolean; paymentTimeline: boolean; - isDisputeOnTransactionPageEnabled: boolean; }; fraudServices: unknown[]; testMode: boolean; diff --git a/client/index.js b/client/index.js index 681ff13479b..3615fe1d07b 100644 --- a/client/index.js +++ b/client/index.js @@ -20,7 +20,6 @@ import DepositDetailsPage from 'deposits/details'; import TransactionsPage from 'transactions'; import PaymentDetailsPage from 'payment-details'; import DisputesPage from 'disputes'; -import LegacyDisputeDetailsPage from 'disputes/details'; import RedirectToTransactionDetails from 'disputes/redirect-to-transaction-details'; import DisputeEvidencePage from 'disputes/evidence'; import AdditionalMethodsPage from 'wcpay/additional-methods-setup'; @@ -152,14 +151,8 @@ addFilter( capability: 'manage_woocommerce', } ); - // If disputes on transaction page feature is enabled, set up a soft - // redirect component; otherwise register the (legacy) dispute details page. - const isDisputeOnTransactionPageEnabled = - window.wcpaySettings.featureFlags.isDisputeOnTransactionPageEnabled; pages.push( { - container: isDisputeOnTransactionPageEnabled - ? RedirectToTransactionDetails - : LegacyDisputeDetailsPage, + container: RedirectToTransactionDetails, path: '/payments/disputes/details', wpOpenMenu: menuID, breadcrumbs: [ @@ -171,9 +164,7 @@ addFilter( __( 'Dispute details', 'woocommerce-payments' ), ], navArgs: { - id: isDisputeOnTransactionPageEnabled - ? 'wc-payments-disputes-details-legacy-redirect' - : 'wc-payments-disputes-details', + id: 'wc-payments-disputes-details-legacy-redirect', parentPath: '/payments/disputes', }, capability: 'manage_woocommerce', diff --git a/client/payment-details/summary/index.tsx b/client/payment-details/summary/index.tsx index 2cf9d668b75..cc3866dd085 100644 --- a/client/payment-details/summary/index.tsx +++ b/client/payment-details/summary/index.tsx @@ -167,10 +167,7 @@ const PaymentDetailsSummary: React.FC< PaymentDetailsSummaryProps > = ( { charge.currency && balance.currency !== charge.currency; const { - featureFlags: { - isAuthAndCaptureEnabled, - isDisputeOnTransactionPageEnabled, - }, + featureFlags: { isAuthAndCaptureEnabled }, } = useContext( WCPaySettingsContext ); // We should only fetch the authorization data if the payment is marked for manual capture and it is not already captured. @@ -463,7 +460,7 @@ const PaymentDetailsSummary: React.FC< PaymentDetailsSummaryProps > = ( { - { isDisputeOnTransactionPageEnabled && charge.dispute && ( + { charge.dispute && ( <> { isAwaitingResponse( charge.dispute.status ) ? ( - - -`; - -exports[`PaymentDetailsSummary renders the information of a disputed charge 1`] = ` -
-
-
-

- $20.00 - - usd - - - Disputed: Under review - -

-
-

- Deducted: - $-20.00 -

-

- Fees: - $-15.70 - -

- -

- Net: - $-15.70 -

-
+ Learn more about preventing disputes + + .
-
- Payment ID: - ch_38jdHA39KKA -
+ +
- -
- -