Fixed: Contract must use serpis if no config set
Fixed: Missing fetch_thirdparty.
This commit is contained in:
parent
67cf3cb99b
commit
a4e0de0d8a
@ -538,7 +538,7 @@ else if ($action == 'addline' && $user->rights->contrat->creer)
|
|||||||
}
|
}
|
||||||
|
|
||||||
$ret = $object->fetch($id); // Reload to get new records
|
$ret = $object->fetch($id); // Reload to get new records
|
||||||
|
|
||||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -847,7 +847,7 @@ $formfile = new FormFile($db);
|
|||||||
$objectlignestatic=new ContratLigne($db);
|
$objectlignestatic=new ContratLigne($db);
|
||||||
|
|
||||||
// Load object modContract
|
// Load object modContract
|
||||||
$module=(! empty($conf->global->CONTRACT_ADDON)?$conf->global->CONTRACT_ADDON:'mod_contract_olive');
|
$module=(! empty($conf->global->CONTRACT_ADDON)?$conf->global->CONTRACT_ADDON:'mod_contract_serpis');
|
||||||
if (substr($module, 0, 13) == 'mod_contract_' && substr($module, -3) == 'php')
|
if (substr($module, 0, 13) == 'mod_contract_' && substr($module, -3) == 'php')
|
||||||
{
|
{
|
||||||
$module = substr($module, 0, dol_strlen($module)-4);
|
$module = substr($module, 0, dol_strlen($module)-4);
|
||||||
@ -1043,6 +1043,8 @@ else
|
|||||||
|
|
||||||
if ($object->id > 0)
|
if ($object->id > 0)
|
||||||
{
|
{
|
||||||
|
$object->fetch_thirdparty();
|
||||||
|
|
||||||
$result=$object->fetch_lines(); // This also init $this->nbofserviceswait, $this->nbofservicesopened, $this->nbofservicesexpired=, $this->nbofservicesclosed
|
$result=$object->fetch_lines(); // This also init $this->nbofserviceswait, $this->nbofservicesopened, $this->nbofservicesexpired=, $this->nbofservicesclosed
|
||||||
if ($result < 0) dol_print_error($db,$object->error);
|
if ($result < 0) dol_print_error($db,$object->error);
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user