Open lanitochka17 opened 6 days ago
Triggered auto assignment to @MitchExpensify (Bug
), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.
Edited by proposal-police: This proposal was edited at 2024-11-19 19:02:17 UTC.
Invoices - No sound when paying invoice
We aren't calling playSound(SOUNDS.SUCCESS)
here:
https://github.com/Expensify/App/blob/2fe1a064b38a9422dc58b6675fa51de6ef13bfc2/src/components/ReportActionItem/ReportPreview.tsx#L204-L226
We should play sound playSound(SOUNDS.DONE)
or playSound(SOUNDS.SUCCESS)
before IOU.payInvoice
.
Edited by proposal-police: This proposal was edited at 2024-11-19 19:15:29 UTC.
No sound when paying invoice
The sounds work as expected when paying someone, but they do not trigger for invoices. This is because the sound is played when selecting the payment type
https://github.com/Expensify/App/blob/2fe1a064b38a9422dc58b6675fa51de6ef13bfc2/src/components/SettlementButton/index.tsx#L217 But no sound is played when the button is pressed for the "Pay Elsewhere" option in invoices because here we are not playing any sound https://github.com/Expensify/App/blob/2fe1a064b38a9422dc58b6675fa51de6ef13bfc2/src/components/SettlementButton/index.tsx#L156 https://github.com/Expensify/App/blob/2fe1a064b38a9422dc58b6675fa51de6ef13bfc2/src/components/SettlementButton/index.tsx#L140
We should add playSound(SOUNDS.SUCCESS);
for these two cases too
https://github.com/Expensify/App/blob/2fe1a064b38a9422dc58b6675fa51de6ef13bfc2/src/components/SettlementButton/index.tsx#L156
https://github.com/Expensify/App/blob/2fe1a064b38a9422dc58b6675fa51de6ef13bfc2/src/components/SettlementButton/index.tsx#L140
We can do something like this
onSelected: () => {
playSound(SOUNDS.SUCCESS);
onPress(CONST.IOU.PAYMENT_TYPE.ELSEWHERE, true);
},
Optional: We can play sound of our choice. For example Done
sound
Pressing the invoice pay button doesn't play a sound.
For non-invoice, when we press the pay button, it will call selectPaymentType
which plays the sound if there is no held expenses.
https://github.com/Expensify/App/blob/9368566b52364a34747d8f97d3de7f427b3e0712/src/components/SettlementButton/index.tsx#L216-L219
But for invoice, it will show a popover menu which when we select the individual > pay elsewhere option, it only calls the SettlementButton onPress
without playing any sound.
https://github.com/Expensify/App/blob/9368566b52364a34747d8f97d3de7f427b3e0712/src/components/SettlementButton/index.tsx#L129-L143
Similar to https://github.com/Expensify/App/issues/50572, I suggested to play the sound inside the pay function, such as payMoneyRequest, payInvoice, sendMoneyElsewhere, and sendMoneyWithWallet. We will follow the same pattern as completing a task. If we want to handle this for payInvoice, then we can only do it for payInvoice.
If we want to apply to all pay, then we need to remove the play sound from some places like in SettlementButton to not have duplicated sound.
Job added to Upwork: https://www.upwork.com/jobs/~021859385613425085004
Triggered auto assignment to Contributor-plus team member for initial proposal review - @rushatgabhane (External
)
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: 9.0.64-1 Reproducible in staging?: Y Reproducible in production?: Y If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: N/A Issue reported by: Applause - Internal Team
Action Performed:
Precondition:
Expected Result:
There should be sound when paying invoice
Actual Result:
There is no sound when paying invoice
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
https://github.com/user-attachments/assets/b4a182fe-7456-4275-b1b5-76e08299c4ef
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @rushatgabhane