Merge branch '10.0' of git@github.com:Dolibarr/dolibarr.git into 11.0

Conflicts:
	htdocs/main.inc.php
	htdocs/product/class/productcustomerprice.class.php
This commit is contained in:
Laurent Destailleur 2020-10-26 19:05:30 +01:00
commit 78a52eda96
2 changed files with 17 additions and 28 deletions

View File

@ -1591,6 +1591,7 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead
if (!empty($conf->global->MAIN_FEATURES_LEVEL)) $appli .= "<br>".$langs->trans("LevelOfFeature").': '.$conf->global->MAIN_FEATURES_LEVEL;
$logouttext = '';
$logouthtmltext = '';
if (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER))
{
//$logouthtmltext=$appli.'<br>';

View File

@ -219,15 +219,10 @@ class Productcustomerprice extends CommonObject
$this->id = $this->db->last_insert_id(MAIN_DB_PREFIX."product_customer_price");
if (!$notrigger) {
// Uncomment this and change MYOBJECT to your own tag if you
// want this action calls a trigger.
// // Call triggers
// include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
// $interface=new Interfaces($this->db);
// $result=$interface->run_triggers('MYOBJECT_CREATE',$this,$user,$langs,$conf);
// if ($result < 0) { $error++; $this->errors=$interface->errors; }
// // End call triggers
$result = $this->call_trigger('PRODUCT_CUSTOMER_PRICE_CREATE', $user);
if ($result < 0) {
$error++;
}
}
}
@ -708,14 +703,12 @@ class Productcustomerprice extends CommonObject
$this->errors [] = "Error ".$this->db->lasterror();
}
if (!$error) {
if (!$notrigger) {
// Call triggers
include_once DOL_DOCUMENT_ROOT.'/core/class/interfaces.class.php';
$interface = new Interfaces($this->db);
$result = $interface->run_triggers('PRODUCT_CUSTOMER_PRICE_UPDATE', $this, $user, $langs, $conf);
if ($result < 0) { $error++; $this->errors = $interface->errors; }
// End call triggers
if (! $error) {
if (! $notrigger) {
$result = $this->call_trigger('PRODUCT_CUSTOMER_PRICE_UPDATE', $user);
if ($result < 0) {
$error++;
}
}
}
@ -849,17 +842,12 @@ class Productcustomerprice extends CommonObject
$this->db->begin();
if (!$error) {
if (!$notrigger) {
// Uncomment this and change MYOBJECT to your own tag if you
// want this action calls a trigger.
// // Call triggers
// include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
// $interface=new Interfaces($this->db);
// $result=$interface->run_triggers('MYOBJECT_DELETE',$this,$user,$langs,$conf);
// if ($result < 0) { $error++; $this->errors=$interface->errors; }
// // End call triggers
if (! $error) {
if (! $notrigger) {
$result = $this->call_trigger('PRODUCT_CUSTOMER_PRICE_DELETE', $user);
if ($result < 0) {
$error++;
}
}
}