odoo icon indicating copy to clipboard operation
odoo copied to clipboard

[FIX] pos_restaurant: deleted order is accessible

Open caburj opened this issue 6 months ago • 1 comments

Steps to reproduce

  1. Open restaurant.
  2. In a different tab, delete the order in table 1.
  3. In the opened restaurant, open table 1.
  4. [ISSUE 1] the table has an order.
  5. [ISSUE 2] try paying the order, you get a server error: Record does not exist or has been deleted. (Record: pos.order(11,), User: 2)

Fix description

The issue is caused by not removing the locally created order if its corresponding record in the server is already paid. So in this commit, we check if the local order can be deleted or not by checking its copy in the server.

caburj avatar Aug 29 '24 12:08 caburj