forked from Wavyzz/dolibarr
Qual: Fix phan notices for commande
This commit is contained in:
@@ -1019,14 +1019,14 @@ class Commande extends CommonOrder
|
||||
$sql .= " VALUES ('(PROV)', ".((int) $this->socid).", '".$this->db->idate($now)."', ".((int) $user->id);
|
||||
$sql .= ", ".($this->fk_project > 0 ? ((int) $this->fk_project) : "null");
|
||||
$sql .= ", '".$this->db->idate($date)."'";
|
||||
$sql .= ", ".($this->source >= 0 && $this->source != '' ? $this->db->escape($this->source) : 'null');
|
||||
$sql .= ", ".($this->source >= 0 && $this->source != '' ? $this->db->escape((string) $this->source) : 'null');
|
||||
$sql .= ", '".$this->db->escape($this->note_private)."'";
|
||||
$sql .= ", '".$this->db->escape($this->note_public)."'";
|
||||
$sql .= ", ".($this->ref_ext ? "'".$this->db->escape($this->ref_ext)."'" : "null");
|
||||
$sql .= ", ".($this->ref_client ? "'".$this->db->escape($this->ref_client)."'" : "null");
|
||||
$sql .= ", '".$this->db->escape($this->model_pdf)."'";
|
||||
$sql .= ", ".($this->cond_reglement_id > 0 ? ((int) $this->cond_reglement_id) : "null");
|
||||
$sql .= ", ".(!empty($this->deposit_percent) ? "'".$this->db->escape($this->deposit_percent)."'" : "null");
|
||||
$sql .= ", ".(!empty($this->deposit_percent) ? "'".$this->db->escape((string) $this->deposit_percent)."'" : "null");
|
||||
$sql .= ", ".($this->mode_reglement_id > 0 ? ((int) $this->mode_reglement_id) : "null");
|
||||
$sql .= ", ".($this->fk_account > 0 ? ((int) $this->fk_account) : 'NULL');
|
||||
$sql .= ", ".($this->availability_id > 0 ? ((int) $this->availability_id) : "null");
|
||||
@@ -1114,7 +1114,7 @@ class Commande extends CommonOrder
|
||||
$line->label,
|
||||
$line->array_options,
|
||||
$line->fk_unit,
|
||||
$origintype,
|
||||
(string) $origintype,
|
||||
$originid,
|
||||
0,
|
||||
$line->ref_ext,
|
||||
@@ -1680,7 +1680,7 @@ class Commande extends CommonOrder
|
||||
$txtva = preg_replace('/\s*\(.*\)/', '', $txtva); // Remove code into vatrate.
|
||||
}
|
||||
|
||||
$tabprice = calcul_price_total($qty, $pu, $remise_percent, $txtva, $txlocaltax1, $txlocaltax2, 0, $price_base_type, $info_bits, $product_type, $mysoc, $localtaxes_type, 100, $this->multicurrency_tx, $pu_ht_devise);
|
||||
$tabprice = calcul_price_total($qty, (float) $pu, $remise_percent, $txtva, (float) $txlocaltax1, (float) $txlocaltax2, 0, $price_base_type, $info_bits, $product_type, $mysoc, $localtaxes_type, 100, $this->multicurrency_tx, (float) $pu_ht_devise);
|
||||
|
||||
/*var_dump($txlocaltax1);
|
||||
var_dump($txlocaltax2);
|
||||
@@ -3140,7 +3140,7 @@ class Commande extends CommonOrder
|
||||
$txtva = preg_replace('/\s*\(.*\)/', '', $txtva); // Remove code into vatrate.
|
||||
}
|
||||
|
||||
$tabprice = calcul_price_total($qty, $pu, $remise_percent, $txtva, $txlocaltax1, $txlocaltax2, 0, $price_base_type, $info_bits, $type, $mysoc, $localtaxes_type, 100, $this->multicurrency_tx, $pu_ht_devise);
|
||||
$tabprice = calcul_price_total($qty, (float) $pu, $remise_percent, $txtva, $txlocaltax1, $txlocaltax2, 0, $price_base_type, $info_bits, $type, $mysoc, $localtaxes_type, 100, $this->multicurrency_tx, (float) $pu_ht_devise);
|
||||
|
||||
$total_ht = $tabprice[0];
|
||||
$total_tva = $tabprice[1];
|
||||
|
||||
Reference in New Issue
Block a user