Hi all:
This function looks so weird to me. It seems that it just returns 1 but it is used around Dolibarr:
Contrat::adline
Contrat::updateline
ContratLigne::update
ContratTest::testContratValid
Is it supposed to do something or should it be removed?
/**
* Update statut of contract according to services
*
* @param User $user Object user
* @return int <0 if KO, >0 if OK
*/
function update_statut($user)
{
// If draft, we keep it (should not happen)
if ($this->statut == 0) return 1;
// Load $this->lines array
// $this->fetch_lines();
$newstatut=1;
foreach($this->lines as $key => $contractline)
{
// if ($contractline) // Loop on each service
}
return 1;
}