Merge branch '8.0' of git@github.com:Dolibarr/dolibarr.git into 9.0
This commit is contained in:
commit
6cdf5c5673
@ -3011,8 +3011,13 @@ else
|
|||||||
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&action=edit">'.$langs->trans('Modify').'</a></div>';
|
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&action=edit">'.$langs->trans('Modify').'</a></div>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$discount = new DiscountAbsolute($db);
|
||||||
|
$result = $discount->fetch(0, 0, $object->id);
|
||||||
|
|
||||||
// Reopen a standard paid invoice
|
// Reopen a standard paid invoice
|
||||||
if (($object->type == FactureFournisseur::TYPE_STANDARD || $object->type == FactureFournisseur::TYPE_REPLACEMENT) && ($object->statut == 2 || $object->statut == 3)) // A paid invoice (partially or completely)
|
if (($object->type == FactureFournisseur::TYPE_STANDARD || $object->type == FactureFournisseur::TYPE_REPLACEMENT
|
||||||
|
|| ($object->type == FactureFournisseur::TYPE_CREDIT_NOTE && empty($discount->id)))
|
||||||
|
&& ($object->statut == 2 || $object->statut == 3)) // A paid invoice (partially or completely)
|
||||||
{
|
{
|
||||||
if (! $facidnext && $object->close_code != 'replaced' && $user->rights->fournisseur->facture->creer) // Not replaced by another invoice
|
if (! $facidnext && $object->close_code != 'replaced' && $user->rights->fournisseur->facture->creer) // Not replaced by another invoice
|
||||||
{
|
{
|
||||||
|
|||||||
@ -44,6 +44,7 @@ class Entrepot extends CommonObject
|
|||||||
public $table_element='entrepot';
|
public $table_element='entrepot';
|
||||||
|
|
||||||
public $picto='stock';
|
public $picto='stock';
|
||||||
|
public $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Warehouse closed, inactive
|
* Warehouse closed, inactive
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user