- Notifications
You must be signed in to change notification settings - Fork3.9k
feat(payment-link): alternate text for manual captures#7574
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
semanticdiff-combot commentedMar 19, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Changed Files
|
crates/router/src/core/payment_link/payment_link_initiate/payment_link.js OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
4c46287
tof796402
CompareUh oh!
There was an error while loading.Please reload this page.
f796402
tocaba777
Comparecaba777
to7f9afb2
CompareUh oh!
There was an error while loading.Please reload this page.
8d21c90
toa8b9748
Compareif (paymentDetails.payment_button_text) { | ||
payNowButtonText.textContent = paymentDetails.payment_button_text; | ||
} else if (paymentDetails.is_setup_mandate_flow || (paymentDetails.amount==="0.00" && paymentDetails.setup_future_usage_applied ==="off_session")) { | ||
payNowButtonText.textContent = translations.addPaymentMethod; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Ideally we should compute in rust code and send the computed value to JS bro,
Let's refactor in the subsequent PR
fa46593
Uh oh!
There was an error while loading.Please reload this page.
Junjun13910 commentedApr 25, 2025 via email
How to do itAdrian …On Fri, Apr 25, 2025 at 6:17 AM likhinbopanna ***@***.***> wrote: Merged#7574 <#7574> into main. — Reply to this email directly, view it on GitHub <#7574 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/BJVKREALZJFCMMUZQOBEVYD23IRT7AVCNFSM6AAAAABZKU33I2VHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJXGQYDKNRQGEZDGOI> . You are receiving this because you commented.Message ID: ***@***.***> |
Uh oh!
There was an error while loading.Please reload this page.
Type of Change
Description
Payment links will have
Add Payment Method
as button text in case merchant send is_setup_mandate_flow astrue
in payment_link_config,Authorize Payment
in case of manual capture payments andPay Now
in automatic captures.is_setup_mandate_flow field is only used to alter the text in payment button our core flow of setup mandate remains the same i.e setup mandate flow is used only if amount is zero other authorize flow is used in payments core.
Priority given according to below:
Additional Changes
Motivation and Context
Payment links created with capture_method: manual - where the intention is to authorize the customer for some non zero amount, and capture the authorized amount at some later point in time. In such scenarios, the text Pay Now is incorrect as the user is not actually paying in that moment.
How did you test it?
Curls involved to test the flows:
Automatic captures:
Manual Captures:
setup_mandate_flow
setup_mandate_flow with zero amount
Checklist
cargo +nightly fmt --all
cargo clippy