So i have a issue with the change screen menu action that seems to work fine until I add a second ticket to the table.
Here is the scenario I have a entity that’s called patron there all my and people like family orders will be put on this entity but now the issue I have is that it works fine on the first order but when there is a new ticket added to this table it doesn’t work anymore. Anyone have an idea how to fix this. Btw I use this menu change cause the patron menu has all items priced at 1 if there is no option to fix the change menu action then im also happy with a alternative way to get every order at a price of 1 on this entity
Here are my actions and rules used:
This action i made as a second way to get the wanted result as the patron price tag also is set to 1 on every product but this also doesn’t fix the prob when adding new ticket to the table
Yeah it indeed doesn’t need it just tested it, but even without that i still have the issue that when i add a extra ticket on the table it doesn’t work. Once table exist the menu change also doesn’t work but, then the price list change does so that issue I have fixed for now.
Its the add ticket button for when you already have a ticket on the entity open and want to have a second ticket on it like a separated bill or second group on the same entity, when i press that add ticket automation button everything reverts back to normal, menu and price tag.
Once a second ticket is Made the change menu action and rule for some reason don’t seem to work anymore unlike the change price tag that one seems to start working after there exists 2tickets with a order already on it(if its the first newly created ticket it doesn’t work same as first order of the second created ticket).
So at this point i just have a issue for the first order of a newly created ticket on the same entity.
It might be that the Entity Selected Rule is not being triggered for the new Ticket on the same Entity. You should put a Show Message action in that Rule to test that.
You might need to use either Ticket Entity Changed event, or maybe (probably) Ticket Created event would be better.
Thanks once I’m back at the restaurant i will try it and will also restart from scratch cause maybe it’s like @Jesse said that somewhere one of my rules is interfering.
Problem was indeed caused due when you add a second ticket to a entity it doesn’t trigger the select entity rule but just creates a new ticket on it and uses Update entity rule instead.
So the partial solution is very easy just add a second rule that triggers the change menu action whit the Entity Updated rule on the required entity.
here is my partial fix.
So there is 1 action required this is the one to change your menu with the adjusted prices.
Your issue is that selecting a ticket on that list is not selecting or updating ticket entity. It is just opening the ticket,.
If you had explained more thouroughly this would have already been commented on.
You can probably add a ticket key opened rule with an {ENTITY NAME:WhateverEntityTypeNamePatronIs} in the constraint
Sorry i tought i had explained the issue clearly enough😓.
Do i need to add the constraint in action part of the rule or in the custom constraint list cause i tried to add a custom constraint Entity Name>equals>patron in custom constraint list But this for some reason shuts down whole sambapos when selecting the ticket.
So i tried it but no luck and half of the time it shuts down sambapos (i tested rules to see if there is a conflict but it says rules work fine)
here is my rule and the debug log
The Entity Updated Event/Rule is not really Ticket-based. I would remove that Rule (just delete the mapping to disable it is enough), if you haven’t done so already. That Event is more for when you have updated Entity Data.
I think you are on the right track with the Ticket Opened Event.
What I don’t understand is why the “patron” menu is used when it matches either the “patron” or the “offert” Entity. Maybe that’s how you want it, but it doesn’t make sense to me. I would have though you would want the “offert” menu when using the “offert” Entity, but whatever, which means you would remove the “offert” constraint, clone the Rule, change the constraint to “offert” and change the action to load the “offert” menu.
Im pretty sure EntityName is not a valid value on ticket opened rule.
Thats why I sugested using the { curly print tag type expression } to call the enitty name.
i used the Entity Updated rule for when you press the add ticket button on a already existing ticket this was the only way to get the menu changed if there is already a ticket open on the entity
the offert table and patron table are basically the same the offert table is for items we gift to clients who frequent the restaurant on regular bases and the patron table is that of me, family and staff but we don’t want to gift the product instantly(this way i can still track what was gifted to who and how much was gifted) ,i also don’t want that the waiters to use those tickets to let clients pay and take the money