Help me please, how to create the mechanism for calculating staff commission for sale products from a certain category.
When add a product to the ticket, need to choose which of the staff sold the product. And at the end of the day have to pay to each staff a fixed amount for each sold product from cash drawer.
When add product#1 to ticket, I choose staff name using order tags
At the end of day we know how many products was sold by every staff
Staff#1 - 2 products
Staff#2 - 5 products
At the end of day I want to press on button “Pay comission” which will transfer money to staff accounts from cash drawer
Staff#1 account - 2 * fixed amount
Staff#2 account - 5 * fixed amount
Several approaches can be made for this. I recommend using Employee Entities. So create an Entity Type call it Employees Then create your employee entities. We can automate assigning them to tickets when they start a ticket if you like. It can be a simple pin entered when they click POS button or it can be triggered to ask them to enter a pin when order first added to ticket. When they enter the pin it adds them to ticket.
Once your employee entity is added to ticket then its simple in reports to report on them. Answer this question what would you like the report to look like? Can you give us example of what you want in it and how you vision it to look?
BTW it doesnt have to be pin you can make them typ0e first name, Click a button whatever you wish.
You cannot assign Entities at the Order-level. They can only be assigned at the Ticket-level. That said, it wouldn’t hurt to create Employee Entities anyway, and have associated Accounts for them as well. Then you can automate the account transactions in the future which would be beneficial. EDIT: I see you mentioned already having Staff Accounts, so that is good.
Since you may have multiple Employees assigned on a single Ticket, you only have 2 options for Order-level assignment: Order Tags and Order States. You can report on both. I can’t immediately think of any reason why you would choose one over the other in this scenario, suffice it to say the display of information will look different on the Ticket. So you can stick with Order Tags.
You might consider making the Account Transactions when the Order is Tagged, rather than trying to do it at the end of the day. It will be simpler to do. Or, if you don’t want to make an actual Transaction, you could possibly store a running Total in an Entity Custom Data Field.