Merge branch '15.0' of git@github.com:Dolibarr/dolibarr.git into 15.0
This commit is contained in:
commit
c104e6850d
@ -4905,7 +4905,7 @@ class Facture extends CommonInvoice
|
||||
|
||||
/**
|
||||
* @param int $rounding Minimum number of decimal to show. If 0, no change, if -1, we use min($conf->global->MAIN_MAX_DECIMALS_UNIT,$conf->global->MAIN_MAX_DECIMALS_TOT)
|
||||
* @return number or -1 if not available
|
||||
* @return float or -1 if not available
|
||||
*/
|
||||
public function getRetainedWarrantyAmount($rounding = -1)
|
||||
{
|
||||
|
||||
@ -1016,6 +1016,19 @@ class Ticket extends CommonObject
|
||||
}
|
||||
}
|
||||
|
||||
// Delete all child tables
|
||||
|
||||
if (!$error) {
|
||||
$sql = "DELETE FROM ".MAIN_DB_PREFIX."categorie_ticket";
|
||||
$sql .= " WHERE fk_ticket = ".(int) $this->id;
|
||||
|
||||
$result = $this->db->query($sql);
|
||||
if (!$result) {
|
||||
$error++;
|
||||
$this->errors[] = $this->db->lasterror();
|
||||
}
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$sql = "DELETE FROM ".MAIN_DB_PREFIX."ticket";
|
||||
$sql .= " WHERE rowid=".((int) $this->id);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user