forked from Wavyzz/dolibarr
Fix: [ bug #1451 ] Interrupted order clone through trigger, loads nonexistent order
This commit is contained in:
@@ -11,6 +11,7 @@ Fix: [ bug #1443 ] Payment conditions is erased after editing supplier invoice l
|
||||
limit date for payment
|
||||
Fix: [ bug #1449 ] Trigger ORDER_CREATE, LINEORDER_DELETE, LINEORDER_UPDATE and LINEORDER_INSERT ignore interception on error
|
||||
Fix: [ bug #1450 ] Several Customer order's triggers do not report the error from the trigger handler
|
||||
Fix: [ bug #1451 ] Interrupted order clone through trigger, loads nonexistent order
|
||||
|
||||
***** ChangeLog for 3.5.3 compared to 3.5.2 *****
|
||||
Fix: Error on field accountancy code for export profile of invoices.
|
||||
|
||||
@@ -112,6 +112,9 @@ if ($action == 'confirm_clone' && $confirm == 'yes' && $user->rights->commande->
|
||||
{
|
||||
if ($object->id > 0)
|
||||
{
|
||||
//Because createFromClone modifies the object, we must clone it so that we can restore it later
|
||||
$orig = clone $object;
|
||||
|
||||
$result=$object->createFromClone($socid);
|
||||
if ($result > 0)
|
||||
{
|
||||
@@ -121,6 +124,7 @@ if ($action == 'confirm_clone' && $confirm == 'yes' && $user->rights->commande->
|
||||
else
|
||||
{
|
||||
setEventMessage($object->error, 'errors');
|
||||
$object = $orig;
|
||||
$action='';
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user