|
@@ -26,7 +26,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
|
|
|
/**
|
|
|
* File of class to manage predefined price products or services by customer
|
|
|
*/
|
|
|
-class Productcustomerprice extends CommonObject
|
|
|
+class ProductCustomerPrice extends CommonObject
|
|
|
{
|
|
|
/**
|
|
|
* @var string ID to identify managed object
|
|
@@ -850,7 +850,7 @@ class Productcustomerprice extends CommonObject
|
|
|
|
|
|
while (($obj = $this->db->fetch_object($resql)) && (empty($error))) {
|
|
|
// find if there is an existing line for the product and the subsidiaries
|
|
|
- $prodsocprice = new Productcustomerprice($this->db);
|
|
|
+ $prodsocprice = new ProductCustomerPrice($this->db);
|
|
|
|
|
|
$filter = array(
|
|
|
't.fk_product' => $this->fk_product, 't.fk_soc' => $obj->rowid
|
|
@@ -865,7 +865,7 @@ class Productcustomerprice extends CommonObject
|
|
|
if (count($prodsocprice->lines) > 0) {
|
|
|
// If force update => Update
|
|
|
if (!empty($forceupdateaffiliate)) {
|
|
|
- $prodsocpriceupd = new Productcustomerprice($this->db);
|
|
|
+ $prodsocpriceupd = new ProductCustomerPrice($this->db);
|
|
|
$prodsocpriceupd->fetch($prodsocprice->lines [0]->id);
|
|
|
|
|
|
$prodsocpriceupd->price = $this->price;
|
|
@@ -882,7 +882,7 @@ class Productcustomerprice extends CommonObject
|
|
|
}
|
|
|
} else {
|
|
|
// If line do not exits then create it
|
|
|
- $prodsocpricenew = new Productcustomerprice($this->db);
|
|
|
+ $prodsocpricenew = new ProductCustomerPrice($this->db);
|
|
|
$prodsocpricenew->fk_soc = $obj->rowid;
|
|
|
$prodsocpricenew->ref_customer = $obj->ref_customer;
|
|
|
$prodsocpricenew->fk_product = $this->fk_product;
|
|
@@ -971,7 +971,7 @@ class Productcustomerprice extends CommonObject
|
|
|
{
|
|
|
$error = 0;
|
|
|
|
|
|
- $object = new Productcustomerprice($this->db);
|
|
|
+ $object = new ProductCustomerPrice($this->db);
|
|
|
|
|
|
$this->db->begin();
|
|
|
|