VIP & Happy Hour (or timed special) Discounts without Triggers

I changed the weekdays, but not working.
but when i removed the constraint it work Perfect

It is case sensitive. On your message box it appears as ter not Ter

2 Likes

Also your windows regional settings must be set to your language.

Yeah! @emre is ter not Ter

I disabled the uppercase and is working perfectly
and also I checked my windows regional system.
Thank you all thank you

Hello! Thank you for posting this helpful tutorial! I’ve tested it and made some changes to give discount in percentage instead of fixed amount. Later i will share my rules. May be someone would need this. And also i found a bug with time.

When we have Happy Hour for example from 6 p.m. (which defined as 1800 in digits) to 2 a.m. (0200 in digits), rule won’t execute since if we make order on 6:36pm(1836 in digits), then rule constraint won’t be satisfied because 1836 greater than 0200, which must be less. Can somebody help me to solve this problem? I have an idea to create one more HHstartTime and HHendTime settings to set time from 0000 to 0200 and change first one to 1800 to 2360.
If you have any idea please share. And thank you!

1 Like

Use two constraints to satisfy the 24 hour switch.

One to check 1800-2400 and one to check 0000-0200

3 Likes

Thank You! This is how i solved it:
(('[=FD('{ORDER DATE}','ddd')]' == '{SETTING:HHstartDay}' && [=TN(FD('{ORDER TIME}','HHmm'))] > [=TN('{SETTING:HHstartTime}')] && [=TN(FD('{ORDER TIME}','HHmm'))] > 1001 &&[=TN('{SETTING:HHendTime}')] < 1000) || ([=TN('{SETTING:HHendTime}')] < 1000 && [=TN(FD('{ORDER TIME}','HHmm'))] <[=TN('{SETTING:HHendTime}')]) || ('[=FD('{ORDER DATE}','ddd')]' =='{SETTING:HHstartDay}'&& [=TN(FD('{ORDER TIME}','HHmm'))] > [=TN('{SETTING:HHstartTime}')] && [=TN(FD('{ORDER TIME}','HHmm'))] <[=TN('{SETTING:HHendTime}')])) && [=TN('{ITEM TAG:HH}')] > 1
This is for HH!

And for ND below:

((('[=FD('{ORDER DATE}','ddd')]' != '{SETTING:HHstartDay}' || [=TN(FD('{ORDER TIME}','HHmm'))] < [=TN('{SETTING:HHstartTime}')]) && [=TN(FD('{ORDER TIME}','HHmm'))] > 1001 && [=TN('{SETTING:HHendTime}')] < 1000) && ([=TN('{SETTING:HHendTime}')] < 1000 && [=TN(FD('{ORDER TIME}','HHmm'))] < 1000) && ('[=FD('{ORDER DATE}','ddd')]' != '{SETTING:HHstartDay}' || [=TN(FD('{ORDER TIME}','HHmm'))] < [=TN('{SETTING:HHstartTime}')] || [=TN(FD('{ORDER TIME}','HHmm'))] > [=TN('{SETTING:HHendTime}')])) || [=TN('{ITEM TAG:HH}')] < 1

1000 - this is time of opening of restaurant. You can change it to yours time!

Cheer guys!

1 Like

Happy Hour with an amount of less than 1 doesn’t seem to work. Is there a way I can allow it to take of 0.50?

Kind regards

Matt

It works for me. Please be more specific. Show the Rule that tags the Order with the Discount, and the Product Tag Editor showing the values you are using.

Also, do you have any Rounding functions enabled?

hmm, ok thats weird. What do you mean by rounding functions enabled?

Ill paste the rules in here and product tags 2 secs


edit: for the record, ive installed this on a new install of samba and its a stock install? I havent edited anything.

Matt


Hi QMckay,
Is there tutorial to implement percentage discount instead of fixed value?

For the VIP discount I have used the ‘Rate’ instead of price. the discount is calculated correctly for the item but instead of subtracting the discount it adds on the ticket. can you pint me to wright direction. thanks

VIP1 5%
VIP2 10%
VIP3 15%

Set it as a negative rate see what happens.

3 Likes

That did the trick, thanks
:joy::scream:

I was following tutorial, But how can I use multiple same action in one rule?
if i use HH Store HH DateTime, can not use it again.

Am I missing something? please help

@jayguar6 once you use “Select Actions” then Right Mouse Click on the Actions List to get a “Display All Values” to display any used Actions.

Hidden feature :smile:

3 Likes

Thanks, great help~
solved!

Hello All -

I’ve had the VIP/HH discounts implemented since V4. Recently I had the need to research a customers history and noticed the tags for HH discounts on all tickets had been removed. With this, it shows a balance on each applicable ticket for the total amount of the HH discounts however VIP tags remained. Is this normal? It doesn’t seem to be affecting anything in accounting, however our owner is concerned that this will alter reporting.

Upon investigating I’ve noticed that the tags are fine throughout the current work period and remain up to around 48 hours and then suddenly they vanish.

Is anyone else seeing similar behaviors?

Hmm
 how are you doing this “research”? By displaying the Ticket via the Ticket Explorer or the Account “Find Ticket” button, I am guessing? I hope you’re not using the “Reopen/Cancel Payments” method


In any case, the Tutorial is designed to have VIP override HH, so in most cases, there should be no mixing of HH and VIP Order Tags in a Ticket. It should be one or the other.

Can you possibly show some screenshots of this behavior?

You could try adding another Constraint to this Rule, just in case:

{TICKET STATE:Status} Not Equals Paid

Is there a way to give a “percent” off on an item as opposed to a monetary amount? Like 10% off an item for VIP? Or should I just figure out the 10% for each item and mark the monetary amount?

Have not used this exact setup before but as far as I can tell you would just need to edit the formula which calculates the tag value for discount.

[=-1*(TN('{ITEMTAG:VIP{ENTITY DATA:Customer:VIP Level}}')*(TN('{ORDER PRICE}'))]

Please check {ORDER PRICE} 99% sure thats wrong but but not at Samba PC atm to check correct tag but if VIP1 was set to 0.1 (10%) and order was £10 it would be -1 x 0.1 x 10 = -1
 (£1 off £10 item so 10% off)