question

dima avatar image
dima asked dima commented

How to add tips at custom tender?

I created a custom tender and now I want to show a screen to add tips, but I don't know how. It doesn't appear by default, and when I trying to use an intent for that, I wrote:

Intent intent = new Intent(Intents.ACTION_ADD_TIP);
startActivity(intent);

but the opened window says: "All tips entered for All Employees" and a back button. What does it mean?

Thanks!

1 comment
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

dima avatar image dima commented ·

I'm still waiting for any help

0 Likes 0 ·
Jacob Abrams avatar image
Jacob Abrams answered

You want to show a customer facing screen? The Intents.ACTION_ADD_TIP is for employees to enter the tip written on a paper receipt by a customer. You are probably looking for Intents.ACTION_CUSTOMER_ADD_TIP.

You should use startActivityForResult and pass a long value Intents.EXTRA_AMOUNT. You will receive a long Intents.EXTRA_TIP_AMOUNT in the result Bundle.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Jeffrey Blattman avatar image
Jeffrey Blattman answered dima commented

Proper tips are not supported for custom tenders. You can start the tip UI, but this won't add the tip to the payment.

You can however, return an amount extra from your tender that's greater than the requested amount. This won't show as a tip on the payment or be considered in any sort of tip reporting.

2 comments
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

dima avatar image dima commented ·

Thanks a lot. Now I see. Maybe is there a way to add proper tips via REST API?

0 Likes 0 ·
Jeffrey Blattman avatar image Jeffrey Blattman ♦♦ commented ·

No, there is not an API to add tips, sorry.

0 Likes 0 ·

Welcome to the
Clover Developer Community