mirror of
https://github.com/ACSPRI/queXS
synced 2024-04-02 12:12:16 +00:00
Should fail transaction when trying to update where already assigned
This commit is contained in:
@@ -456,9 +456,10 @@ function get_case_id($operator_id, $create = false)
|
|||||||
|
|
||||||
$sql = "UPDATE `case`
|
$sql = "UPDATE `case`
|
||||||
SET current_operator_id = '$operator_id'
|
SET current_operator_id = '$operator_id'
|
||||||
WHERE case_id = '$case_id'";
|
WHERE current_operator_id IS NULL
|
||||||
|
AND case_id = '$case_id'";
|
||||||
|
|
||||||
|
//should fail transaction if already assigned to another case
|
||||||
$db->Execute($sql);
|
$db->Execute($sql);
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user