Author Topic: Print Template missing tags  (Read 14423 times)

jenem

  • Full Member
  • ***
  • Posts: 154
Print Template missing tags
« on: January 07, 2012, 05:16:12 am »
Hi Emre,
I may be missing something but looking at the recipt print temple that I am unable to find a tag for payment entered and change given.

On a printed receipt I want to record payment given

IE Cost = 4.80
Payment given £10
Change given 5.20

This would cut down on people trying to say they had given a bigger amount than they really had.

I cant seem to identify the template Tags to set this up on the printed receipt.

Edgar

JohnS

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 677
Re: Print Template missing tags
« Reply #1 on: January 07, 2012, 05:40:10 am »
I can answer this :)

Had to do this for our pole display.

Two Actions

Action Name - Update Tendered Amount
Action Type - Update Program Setting
Setting Name - TENDERED
Setting Value - [Setting Value]
Update Type - Update

Action Name - Update Change Due
Action Type - Update Program Setting
Setting Name - CHANGEDUE
Setting Value - [Setting Value]
Update Type - Update

One Rule

Rule Name - Change Updated
Event Name - Change Amount Updated
Actions - Update Tendered Amount
Setting Value - [TenderedAmount]
Actions - Update Change Due
Settings Value - [ChangeAmount]


Printer Template

Add the following to the Footer

<J00>Tendered|${SETTING:TENDERED}
<J00>Change Due|${SETTING:CHANGEDUE}


This is a quick run down, you can use this link as a reference for more detailed step by step - http://forum2.sambapos.org/index.php/topic,80.msg379.html#msg379

Have Fun.
« Last Edit: January 07, 2012, 07:11:00 am by JohnSCS »
SambaPOS - POS'n the World, one Terminal at a time.

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #2 on: January 07, 2012, 06:23:16 am »
As ever John,

Ta!

You are getting too good!!

I will try it later.

Thanks

Edgar

PS I should have used search function on forum.
« Last Edit: January 07, 2012, 06:26:00 am by jenem »

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #3 on: January 08, 2012, 02:14:00 am »
Thanks for your help John.

I got a bit confused with setting actions but all ok now.
I couldn't see the drop down box in action list. This was because I occidentally used {} instead of []

Edgar

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #4 on: January 09, 2012, 11:52:17 am »
Hi John, Emre.

Receipts printing OK showing Tendered amount and Change to give and printing fine.

Problem If you next enter cash, the receipt prints the previous amount tendered and change given.

 I have tried to create action and update rule to clear previous amounts but at the moment nothing seems to work.

Any advice on setting rules and actions would be of great help.

Edgar

emre

  • SambaPOS Developer
  • Samba Team
  • Hero Member
  • *****
  • Posts: 1564
Re: Print Template missing tags
« Reply #5 on: January 09, 2012, 01:03:30 pm »
I'm not in front of my development machine but as I can remember you can create a rule for "Ticket Closed" event. Can you can try resetting these values to empty value on closing the ticket?

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #6 on: January 09, 2012, 01:24:03 pm »
Hi Emre,

I had a try with ticket closed but It didn't seem to clear. I'll try again later.

Thanks for your help.

Edgar

JohnS

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 677
Re: Print Template missing tags
« Reply #7 on: January 09, 2012, 08:07:31 pm »
Try adding these Actions to a Ticket Closed Rule

Actions - Update Tendered Amount
Setting Value - 0
Actions - Update Change Due
Settings Value - 0
SambaPOS - POS'n the World, one Terminal at a time.

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #8 on: January 10, 2012, 01:28:02 am »
Hi John,

Thanks I will try later.

From what you have found out, the setting rule can be a system variable or a user numeric or text value which you can test ?

How do you know what system variables are available? did you look through the source code?

As always,

Thanks

Edgar

JohnS

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 677
Re: Print Template missing tags
« Reply #9 on: January 10, 2012, 01:34:02 am »
The drop down lists in the different Rules & Actions, printer tags and by trial and error.
SambaPOS - POS'n the World, one Terminal at a time.

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #10 on: January 10, 2012, 01:47:25 am »
My way of working but you are better than me!!

Edgar

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #11 on: January 10, 2012, 02:07:33 am »
John,

"Try adding these Actions to a Ticket Closed Rule

Actions - Update Tendered Amount
Setting Value - 0
Actions - Update Change Due
Settings Value - 0"

I tried this but wouldn't work. This is because ticket is closed before being printed. The printed tendered value, change value is zero whatever amount is tendered.

I used the rule with open ticket rule and set the same action and its works ok except tendered amount shows 0 when exact money is tendered.
On the upside at least previous tendered amount and change is cleared!!

Idealy what is required is combining exact cash and tendered amount into one variable.

Edgar 

JohnS

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 677
Re: Print Template missing tags
« Reply #12 on: January 10, 2012, 02:26:54 am »
OK, one step closer.

Try adding a rule when Payment Received, check if TENDERED = 0, add the Action Update Tendered Amount and set value to [Amount]

That should work. If not I will set up the Rules & Actions and test my end.
SambaPOS - POS'n the World, one Terminal at a time.

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #13 on: January 10, 2012, 02:30:11 am »
We're getting there! Got to go out now. Will try later but feeling confident we can crack it.

Edgar

jenem

  • Full Member
  • ***
  • Posts: 154
Re: Print Template missing tags
« Reply #14 on: January 10, 2012, 05:42:29 am »
Hi, John,

tried as you suggested and all works ok now. Phew!

Question.

Do you use split cheque on your system? How should it work?

When I tried it It shows correct split on screen but when split cash is entered it doesnt print a receipt until all amounts are paid and then it prints showing only the last amount entered.

Should SambaPos print 3 receipts for 3 amounts showing split payments?

I dont use split payments but just curious.

Edgar