Thanks in advance for your answers.
I have a php system in which several users work at the same time. It happens that a work order is loaded labor and spare parts. Different users can edit the same order. The problem is that when a user edits the order at the same time as another user on another machine is editing the same order, the data that the first was adding, or only saved is lost.
How can I do to validate that the work order can not be edited while it is being edited by another user on another machine?