mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-01-03 07:32:32 +01:00
Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2
This commit is contained in:
@@ -380,9 +380,6 @@ class Societe extends CommonObject
|
||||
|
||||
dol_syslog(get_class($this)."::Update id=".$id." call_trigger=".$call_trigger." allowmodcodeclient=".$allowmodcodeclient." allowmodcodefournisseur=".$allowmodcodefournisseur);
|
||||
|
||||
// For triggers
|
||||
if ($call_trigger) $this->oldobject = dol_clone($this);
|
||||
|
||||
$now=dol_now();
|
||||
|
||||
// Clean parameters
|
||||
|
||||
@@ -102,7 +102,11 @@ if (empty($reshook))
|
||||
{
|
||||
require_once(DOL_DOCUMENT_ROOT."/core/lib/functions2.lib.php");
|
||||
|
||||
if ($action == 'update') $object->fetch($socid);
|
||||
if ($action == 'update')
|
||||
{
|
||||
$ret=$object->fetch($socid);
|
||||
$object->oldcopy=dol_clone($object);
|
||||
}
|
||||
else $object->canvas=$canvas;
|
||||
|
||||
if (GETPOST("private") == 1)
|
||||
@@ -317,8 +321,6 @@ if (empty($reshook))
|
||||
exit;
|
||||
}
|
||||
|
||||
$object->oldcopy=dol_clone($object);
|
||||
|
||||
// To not set code if third party is not concerned. But if it had values, we keep them.
|
||||
if (empty($object->client) && empty($object->oldcopy->code_client)) $object->code_client='';
|
||||
if (empty($object->fournisseur)&& empty($object->oldcopy->code_fournisseur)) $object->code_fournisseur='';
|
||||
|
||||
Reference in New Issue
Block a user