Merge pull request #8678 from defrance/patch-111

add $user on delete line
This commit is contained in:
Laurent Destailleur 2018-04-27 10:31:19 +02:00 committed by GitHub
commit 0a4bd14bc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2762,6 +2762,8 @@ class SupplierInvoiceLine extends CommonObjectLine
*/ */
public function delete($notrigger = 0) public function delete($notrigger = 0)
{ {
global $user;
dol_syslog(get_class($this)."::deleteline rowid=".$this->id, LOG_DEBUG); dol_syslog(get_class($this)."::deleteline rowid=".$this->id, LOG_DEBUG);
$error = 0; $error = 0;
@ -2769,7 +2771,7 @@ class SupplierInvoiceLine extends CommonObjectLine
$this->db->begin(); $this->db->begin();
if (!$notrigger) { if (!$notrigger) {
if ($this->call_trigger('LINEBILL_SUPPLIER_DELETE',$user) < 0) { if ($this->call_trigger('LINEBILL_SUPPLIER_DELETE', $user) < 0) {
$error++; $error++;
} }
} }