Merge pull request #15296 from fappels/13_reception

Add OK return value to reception->addline
This commit is contained in:
Laurent Destailleur 2020-11-04 18:09:44 +01:00 committed by GitHub
commit a283b771cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -704,7 +704,7 @@ class Reception extends CommonObject
* @param integer $eatby eat-by date
* @param integer $sellby sell-by date
* @param string $batch Lot number
* @return int <0 if KO, >0 if OK
* @return int <0 if KO, index of line if OK
*/
public function addline($entrepot_id, $id, $qty, $array_options = 0, $comment = '', $eatby = '', $sellby = '', $batch = '')
{
@ -752,6 +752,8 @@ class Reception extends CommonObject
$line->fk_reception = $this->id;
$this->lines[$num] = $line;
return $num;
}