mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
All triggers with a name XXX_UPDATE have been renamed XXX_MODIFY for
code consistency purpose.
This commit is contained in:
parent
2eaae819f2
commit
5b91ae062f
|
|
@ -21,14 +21,14 @@ NEW: Experimental module Partnership Management
|
|||
For developers:
|
||||
---------------
|
||||
|
||||
NEW:
|
||||
NEW: A lot of addition of hooks.
|
||||
|
||||
|
||||
|
||||
Following changes may create regressions for some external modules, but were necessary to make Dolibarr better:
|
||||
* verifCond('stringtoevaluate') now return false when string contains a bad syntax content instead of true.
|
||||
* The deprecated mdethod thirdparty_doc_create() has been removed. You can use the generateDocument() instead.
|
||||
|
||||
* The deprecated method thirdparty_doc_create() has been removed. You can use the generateDocument() instead.
|
||||
* All triggers with a name XXX_UPDATE have been rename with name XXX_MODIFY for code consistency purpose.
|
||||
|
||||
|
||||
***** ChangeLog for 15.0.1 compared to 15.0.0 *****
|
||||
|
|
|
|||
|
|
@ -4426,7 +4426,7 @@ class PropaleLigne extends CommonObjectLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINEPROPAL_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINEPROPAL_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$this->db->rollback();
|
||||
return -1;
|
||||
|
|
|
|||
|
|
@ -4637,7 +4637,7 @@ class OrderLine extends CommonOrderLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINEORDER_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINEORDER_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -866,7 +866,7 @@ class Account extends CommonObject
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('BANKACCOUNT_UPDATE', $user);
|
||||
$result = $this->call_trigger('BANKACCOUNT_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2176,7 +2176,7 @@ class FactureLigneRec extends CommonInvoiceLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINEBILLREC_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINEBILLREC_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5775,7 +5775,7 @@ class FactureLigne extends CommonInvoiceLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINEBILL_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINEBILL_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$this->db->rollback();
|
||||
return -2;
|
||||
|
|
|
|||
|
|
@ -1798,7 +1798,7 @@ class Contrat extends CommonObject
|
|||
|
||||
if (empty($error)) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINECONTRACT_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINECONTRACT_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$this->db->rollback();
|
||||
return -3;
|
||||
|
|
@ -3196,7 +3196,7 @@ class ContratLigne extends CommonObjectLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINECONTRACT_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINECONTRACT_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
$this->db->rollback();
|
||||
|
|
|
|||
|
|
@ -4024,7 +4024,7 @@ abstract class CommonObject
|
|||
$this->context['link_source_type'] = $sourcetype;
|
||||
$this->context['link_target_id'] = $targetid;
|
||||
$this->context['link_target_type'] = $targettype;
|
||||
$result = $this->call_trigger('OBJECT_LINK_UPDATE', $f_user);
|
||||
$result = $this->call_trigger('OBJECT_LINK_MODIFY', $f_user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -245,7 +245,7 @@ class CoreObject extends CommonObject
|
|||
|
||||
$res = $this->updateCommon($user);
|
||||
if ($res) {
|
||||
$result = $this->call_trigger(strtoupper($this->element).'_UPDATE', $user);
|
||||
$result = $this->call_trigger(strtoupper($this->element).'_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -3031,7 +3031,7 @@ class ExpeditionLigne extends CommonObjectLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINESHIPPING_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINESHIPPING_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$this->errors[] = $this->error;
|
||||
$error++;
|
||||
|
|
|
|||
|
|
@ -514,7 +514,7 @@ class ExpenseReport extends CommonObject
|
|||
if ($result) {
|
||||
if (!$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('EXPENSE_REPORT_UPDATE', $user);
|
||||
$result = $this->call_trigger('EXPENSE_REPORT_MODIFY', $user);
|
||||
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
|
|
@ -2159,7 +2159,7 @@ class ExpenseReport extends CommonObject
|
|||
|
||||
if ($result > 0 && !$notrigger) {
|
||||
// Call triggers
|
||||
$result = $this->call_trigger('EXPENSE_REPORT_DET_UPDATE', $user);
|
||||
$result = $this->call_trigger('EXPENSE_REPORT_DET_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1586,7 +1586,7 @@ class FichinterLigne extends CommonObjectLine
|
|||
if ($result > 0) {
|
||||
if (!$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINEFICHINTER_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINEFICHINTER_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3895,7 +3895,7 @@ class CommandeFournisseurLigne extends CommonOrderLine
|
|||
if (!$error && !$notrigger) {
|
||||
global $user;
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINEORDER_SUPPLIER_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINEORDER_SUPPLIER_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$this->db->rollback();
|
||||
return -1;
|
||||
|
|
|
|||
|
|
@ -410,7 +410,7 @@ class CommandeFournisseurDispatch extends CommonObjectLine
|
|||
|
||||
if (!$notrigger) {
|
||||
// Call triggers
|
||||
$result = $this->call_trigger('LINERECEPTION_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINERECEPTION_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2186,7 +2186,7 @@ class FactureFournisseurLigneRec extends CommonObjectLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINESUPPLIERBILLREC_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINESUPPLIERBILLREC_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1306,7 +1306,7 @@ class FactureFournisseur extends CommonInvoice
|
|||
if (!$error) {
|
||||
if (!$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('BILL_SUPPLIER_UPDATE', $user);
|
||||
$result = $this->call_trigger('BILL_SUPPLIER_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
@ -3704,7 +3704,7 @@ class SupplierInvoiceLine extends CommonObjectLine
|
|||
global $langs, $user;
|
||||
|
||||
// Call trigger
|
||||
if ($this->call_trigger('LINEBILL_SUPPLIER_UPDATE', $user) < 0) {
|
||||
if ($this->call_trigger('LINEBILL_SUPPLIER_MODIFY', $user) < 0) {
|
||||
$this->db->rollback();
|
||||
return -1;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -414,7 +414,7 @@ class ProductFournisseur extends Product
|
|||
$resql = $this->db->query($sql);
|
||||
if ($resql) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('SUPPLIER_PRODUCT_BUYPRICE_UPDATE', $user);
|
||||
$result = $this->call_trigger('SUPPLIER_PRODUCT_BUYPRICE_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -766,7 +766,7 @@ class Productcustomerprice extends CommonObject
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('PRODUCT_CUSTOMER_PRICE_UPDATE', $user);
|
||||
$result = $this->call_trigger('PRODUCT_CUSTOMER_PRICE_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3282,7 +3282,7 @@ class SupplierProposalLine extends CommonObjectLine
|
|||
|
||||
if (!$error && !$notrigger) {
|
||||
// Call trigger
|
||||
$result = $this->call_trigger('LINESUPPLIER_PROPOSAL_UPDATE', $user);
|
||||
$result = $this->call_trigger('LINESUPPLIER_PROPOSAL_MODIFY', $user);
|
||||
if ($result < 0) {
|
||||
$this->db->rollback();
|
||||
return -1;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user