Rounding and issuing change in multiple currencies

Wow - What else can I say. This is really exciting and I appreciate all your work so much.

I was just making some images to try to demostrate how I thought this could be achieved, but what you have put together is so much quicker and easier than what I could come up with. You have a great eye for User Interface design and functionality.

Congratulations. I can’t wait to check-out the latest beta of v5 - So if possible, please add me to the group.

Just one (extra) wish…

Could we have a recipt that looks something like this? (I think probably everything could be acomplished with the variables that are already exposed, but I haven’t looked closely at this yet…)

In this example I am usinging exchange rates which are changing day-by-day as clients make multiple partial payments each day

DIVE CENTER

1 x DIVE      $70
1 x GO-PRO    $30
==================
TOTAL:        $100
==================

PAID: 50 USD  08-NOV-2016
PAID: 200 MXN 08-NOV-2016 (10.26 @ 19.50 MXN/USD)
PAID: 50 CAD  09-NOV-2016 (37.04 USD @ 1.35 CAD/USD)
PAID: 200 MXN 10-NOV-2016 (9.62 @ 20.80 MXN/USD)

---------------------
TOTAL PAID:   $106.92
CHANGE DUE: $6.92
---------------------

CHANGE GIVEN: 5 USD
CHANGE GIVEN: 40 MXN (1.90 USD @ 21 MXN/USD)
------------------------------------------
TOTAL CHANGE GIVEN: $6.90 ($0.02 ROUNDING)

2 Likes

I am sure Emre will give us the necessary Printer Tags to achieve this. Most of it is already there (ie. XR Tags), save for {CHANGE AMOUNT:x} and {TENDERED AMOUNT:x} which will require sub-selection.

1 Like

@QMcKay is it related?

Yes, exactly. We currently have Tags for Change and Tendered, but they are based on default Currency. We will need to be able to drill-down those Tags so we can show how much was paid and how much change was given in each currency. So I think we need “sub-selection” added to those Tags, for example:

{TENDERED AMOUNT:<currency>}
{CHANGE AMOUNT:<currency>}

There might be others that I can’t think of right now, but those a 2 that come to mind.

Well we store no currency info within payments. I’ll try to find a way to fetch them from accounting.

@mjb2000 I uploaded the update and added you to beta group. Search for 5.1.61 topic for updates.

1 Like

Hi @emre

Thanks so much for all your help on this. I have downloaded the very latest version from the Beta group and the inverse exchange rate is working perfectly, but I am only able to get change in the currency which was last tendered. I seem to have taken a step backwards as before I was able to issue USD when someone paid with MXN, but now it jumps straight to issueing change with no buttons at all.

From a vanilla install, I have

  • Created a new currency called MXN
  • Created a new account called Cash (MX) (default currency is selected as MXN)
  • Created an account transaction called Change Transaction (this is a reversed clone of payment transaction)
  • Created a change transaction type called Change MX and Change US each of this has * mappings and " Change transaction" selected as the transaction type. I have also tried setting these with and without the respective cash accounts selected.

Whatever I do I only ever seem to be offered change in the last currency tendered.

What do you think I might have missed?

I just tried this and had the same problem. Needed an additional Change Transaction Type.

This is backwards from what you want (my foreign is USD), but you should get the idea…

1 Like

And here is additional for using Change amount to Credit Customer Account …

Although I didn’t tested it looks like a valid setup. I’ll check that.

Edit: I uploaded a new update. It should handle that setup fine.

Thanks so much @emre
The latest update seems to work great with multiple change currency. I really appreciate your time in helping with this.

I am not sure if you have seen my post in another thread, but I am trying to buy SambaPOS right now, but at the moment the payment doesn’t seem to be working.

I am looking forward to seeing the future development of SambaPOS, in particular I’d be really excited if we can get recipts printed detailing the amounts paid in the various currencies.

I think we might already have the needed Printer Tags …

--Payment Values-- 
PAYMENT AMOUNT Payment Amount
PAYMENT NAME Payment Name
PAYMENT TYPE NAME Payment Name
TENDERED Tendered Amount
CHANGE Change Amount
DESCRIPTION Description

--Change Payment Values-- 
CHANGE PAYMENT AMOUNT Change Payment Amount
CHANGE PAYMENT NAME Change Payment Name

Those Tags would be used in the following sections:

{PAYMENTS}
{CHANGES}

For example:

[PAYMENTS]
<J00>{PAYMENT NAME}| {PAYMENT AMOUNT}

[CHANGES]
<J00>{CHANGE PAYMENT NAME}| {CHANGE PAYMENT AMOUNT}
1 Like

Ahh - awesome. Thanks @QMcKay

It looks like I have a lot more learning still ahread of me. But I am looking forward to it now! :slight_smile:

This:

<EB>
<J10>TOTAL:|($[=F(TN('{TICKET TOTAL}')/TN('{EXCHANGE RATE:USD}'))]) L{TICKET TOTAL}
<L00>{CALL:num.numToSpanish('{TICKET TOTAL}'.slice(0,-3))} Lempira
<DB>
<F>-
<EB>
<C10>Tip / Propina NOT INCLUDED!
<DB>
<L00>Suggested Amounts:
<J00>10%:|($[=F(TN('{TICKET TOTAL}')/TN('{EXCHANGE RATE:USD}') * 0.10)]) L[=F(TN('{TICKET TOTAL}') * 0.10)]
<J00>15%:|($[=F(TN('{TICKET TOTAL}')/TN('{EXCHANGE RATE:USD}') * 0.15)]) L[=F(TN('{TICKET TOTAL}') * 0.15)]
<J00>20%:|($[=F(TN('{TICKET TOTAL}')/TN('{EXCHANGE RATE:USD}') * 0.20)]) L[=F(TN('{TICKET TOTAL}') * 0.20)]
<EB>
<C00>ALL TIPS go to our Awesome Staff!
<DB>
<F>-
{PAYMENTS}
[<L00>CC Info: {TICKET TAG:CCtype} ({TICKET TAG:CCdigits})]
-- [<J00>CHANGE:|[=F(TN('{CHANGE TOTAL}'))]]
{CHANGES}

[PAYMENTS]
<J00>PAID {PAYMENT NAME}: | ($[=F(TN('{PAYMENT AMOUNT}')/TN('{EXCHANGE RATE:USD}'))]) L{PAYMENT AMOUNT}

[CHANGES]
<J00>CHANGE {CHANGE PAYMENT NAME}: | ($[=F(TN('{CHANGE PAYMENT AMOUNT}')/TN('{EXCHANGE RATE:USD}'))]) L{CHANGE PAYMENT AMOUNT}

Produces this:

TOTAL:                           ($6.00) L120.00
CIENTO VEINTE Lempira                           
------------------------------------------------
          Tip / Propina NOT INCLUDED!           
Suggested Amounts:                              
10%:                              ($0.60) L12.00
15%:                              ($0.90) L18.00
20%:                              ($1.20) L24.00
       ALL TIPS go to our Awesome Staff!        
------------------------------------------------
PAID Cash USD:                  ($10.00) L200.00
CHANGE Cash USD:                  ($2.00) L40.00
CHANGE Cash:                      ($2.00) L40.00

That indicates the Ticket was Paid with $10 and Change was issued partially as $2 and L40.

1 Like

Thanks @QMcKay that looks great. Can’t wait to tell you guys once I have it all up and running!

These look new to me in latest beta .61 refresh…

--Change Payment Values-- 
{CHANGE PAYMENT AMOUNT} Change Payment Amount
{CHANGE PAYMENT NAME} Change Payment Name
1 Like

I am switching my Foreign Currency to be HNL with USD being the Default Currency.

Current Rate is 23 HNL to 1 USD (0.043478).


Can someone please tell me how to set Rounding (and where - there are multiple areas to configure this) so that I have .00 after the decimal because we do not use ANY coins in EITHER Currency.

So I want rounding to the nearest WHOLE number, and if possible it might be even better if I could round to the nearest 5 rather than 1 (ie. L303 would become L505) so that I don’t need singles HNL bills in my float.

For the areas indicated …


I probably need to set this Calculation too?


Maybe this?

Try increasing Database decimal places to 4 or 5

Increased to 5 decimal place.

Nothing different visually. L500 still shows as 500.02

I sort of got this working, but not quite… the issue is still the ‘.02’ on the end, in particular now, on the Change Amount.

You can see the Payment button no longer contains the ‘.02’ but the Change Amount still does, which it should not.