forked from Wavyzz/dolibarr
Merge pull request #20012 from atm-adrien/NEW_rec_invoices_15.0_newPR
NEW Recurring vendor invoices
This commit is contained in:
@@ -3385,7 +3385,7 @@ abstract class CommonObject
|
||||
$MODULE = "MODULE_DISALLOW_UPDATE_PRICE_ORDER";
|
||||
} elseif ($this->element == 'facture' || $this->element == 'invoice') {
|
||||
$MODULE = "MODULE_DISALLOW_UPDATE_PRICE_INVOICE";
|
||||
} elseif ($this->element == 'facture_fourn' || $this->element == 'supplier_invoice' || $this->element == 'invoice_supplier') {
|
||||
} elseif ($this->element == 'facture_fourn' || $this->element == 'supplier_invoice' || $this->element == 'invoice_supplier' || $this->element == 'invoice_supplier_rec') {
|
||||
$MODULE = "MODULE_DISALLOW_UPDATE_PRICE_SUPPLIER_INVOICE";
|
||||
} elseif ($this->element == 'order_supplier' || $this->element == 'supplier_order') {
|
||||
$MODULE = "MODULE_DISALLOW_UPDATE_PRICE_SUPPLIER_ORDER";
|
||||
@@ -3430,6 +3430,9 @@ abstract class CommonObject
|
||||
$fieldtva = 'tva';
|
||||
$fieldup = 'pu_ht';
|
||||
}
|
||||
if ($this->element == 'invoice_supplier_rec') {
|
||||
$fieldup = 'pu_ht';
|
||||
}
|
||||
if ($this->element == 'expensereport') {
|
||||
$fieldup = 'value_unit';
|
||||
}
|
||||
@@ -3580,7 +3583,7 @@ abstract class CommonObject
|
||||
if ($this->element == 'facture' || $this->element == 'facturerec') {
|
||||
$fieldtva = 'total_tva';
|
||||
}
|
||||
if ($this->element == 'facture_fourn' || $this->element == 'invoice_supplier') {
|
||||
if ($this->element == 'facture_fourn' || $this->element == 'invoice_supplier' || $this->element == 'invoice_supplier_rec') {
|
||||
$fieldtva = 'total_tva';
|
||||
}
|
||||
if ($this->element == 'propal') {
|
||||
@@ -8043,6 +8046,8 @@ abstract class CommonObject
|
||||
$element = $this->element;
|
||||
if ($element == 'facturerec') {
|
||||
$element = 'facture';
|
||||
} elseif ($element == 'invoice_supplier_rec') {
|
||||
return $user->rights->fournisseur->facture;
|
||||
}
|
||||
|
||||
return $user->rights->{$element};
|
||||
|
||||
Reference in New Issue
Block a user