Auto-add WiFi passcode when Adding Order

yes, that was I thought about this morning, But I don’t know how to update the order tags by pass-code, samba just keep to get my last value, LOL
could you please show me how to do that, ^_^!

Not wanting to but in but If you used tags would get just one code per line? Ie if you range in 4xcoffee there would only be one tag line for the order wouldn’t there??
If that’s the case if you needed 4 codes in the above situation you would have to ring in 4 separate coffee I think?

Yes, correct. More Automation would be required to overcome this. The setup assumes you ring in 1 coffee at a time. It could be expanded to check the Quantity, and generate x number of codes. Again, you need to decide how many you allow for on a single order line … , 5?, 10? 20?

could we rearrange all ORDER TAGS at the last line?

By default, Order Tags are Displayed and Printed according to the sort order here…

You can re-arrange them to print/display them in whatever order you wish.

I meant
we arrange the printer template like this:

1 Coffee.Large 60.00
1 coffee.small 40.00
2 milk cofee 100.00

================================
Code: HYDKJU2 5UVRTQWU
UFTCF2S 5S98HYIO

In short, no, not using Order Tags.

You could use Program Settings to do it though - just place these at the end of the main [LAYOUT] section, prior to any other [sections] …

<L00>Code(s): {SETTING:WiFiCode1} {SETTING:WiFiCode2} {SETTING:WiFiCode3}

Is 0 priced products enabled?
Would the easiest way to decide the number of codes required be to have a wifi code product? And apply the tag to that? Then you could simple choose the number of codes required?
Without completly knowing the setup not sure how/what products would warrant a code?
Imagine there are many types of coffee which could be associated with the tag but then also other products which may or may not qualify.
What if I (one person) ordered say a coffe, a muffin and a bottle of water to take away? I wouldn’t need 3 or even two codes, but someone could have say a bottle of water and eat in?
A product wifi code would allow you to add say any number of codes required depending on the situation!

1 Like

hi QMcKay,

I’m flowing your 1st solution,
How can I add more than 1 “Wifi Generate and Store Code” action into the “WiFi Reset Iterator” rule?
Samba doesn’t allow me to do that, I’m stucking at this step,

I figured out, you cloned the Actions,
I dont know Samba allow the duplicate actions name T_T

In the Rule, click Select Actions, then Right-click in the left side of the Action Chooser, and click Display All Values. Used Actions will appear at the bottom of the list on the left. You can then add them again to the Right side. You will need to do this multiple times.

I did exactly what you show, but I got the wrong value, it always get the “}” symbol to insert to command,
But when I print the (SETTING:WiFiCode1} {…Code2} it return the correct value

when I add the {SETTING:WiFiCode{SETTING:WiFi Iterator}}
to the printer template it also print out the “}” humm

Something wrong in your Rules or Actions. You have a Typo somewhere. Show screenshots

<J00>{TICKET DATE} {TICKET TIME}|Server: {USER NAME}  #{TICKET NO}
{ENTITIES}
<EB>
[<L00>NOTE: {NOTE}]
<DB>
<F>-
{ORDERS}
<F>=
<L00>Codes: {SETTING:WifiCode1} {SETTING:WifiCode2} {SETTING:WifiCode3} {SETTING:WifiCode4}
<F>=

when you print the {SETTING:WiFiCode1} … {SETTING:WiFiCode4}
it return correct, but when you print the {SETTING:WiFiCode{SETTING:WiFi Iterator}} it always return “}”
my previous screenshot show clearly
it make the “code” return wrong,
the code was stored is correct, but the return with {SETTING:WiFiCode{SETTING:WiFi Iterator}} is wrong

Then don’t use that in the Printer Template. Use what I showed.


On to the other issue for the Start Process, I see the issue… I will post a fix soon. This will take me some time. There appears to be a limitation when embedding more than 1 SETTING to set a new value. Interesting…

EDIT: Ok, got it beat. Had to separate the Generation from the Insert… will post solution soon…

Add new Action

Change the Rule for Order Added to Ticket

Add new Rule to capture Automation Command Executed


BAT file:

@echo off
cls

set newpass=%1

@echo Newest Code is %newpass%

timeout 2
pause
1 Like

I lost at {SETTING:[:CommandValue]}
and did we have to create the automation command name “Insert Wifi” to catch the WiFi Code Insert rule?

oh It worked like a charm,
I really really appreciate for your very kindly Support, QMcKay!
You are my saver,
Went through this issue, I could get more understand how the Samba work,
Thanks again you guys!

1 Like