mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-14 08:54:21 +01:00
Remove deprecated and useless hidden option
This commit is contained in:
@@ -785,7 +785,7 @@ class Contrat extends CommonObject
|
||||
|
||||
dol_syslog("Contrat::addline $desc, $pu_ht, $qty, $txtva, $fk_product, $remise_percent, $date_start, $date_end, $price_base_type, $pu_ttc, $info_bits");
|
||||
|
||||
if ($this->statut == 0 || ($this->statut >= 1 && empty($conf->global->CONTRAT_NOEDITWHENVALIDATED)))
|
||||
if ($this->statut >= 0)
|
||||
{
|
||||
$this->db->begin();
|
||||
|
||||
@@ -977,7 +977,7 @@ class Contrat extends CommonObject
|
||||
{
|
||||
global $conf, $langs;
|
||||
|
||||
if ($this->statut == 0 || ($this->statut >= 1 && empty($conf->global->CONTRAT_NOEDITWHENVALIDATED)) )
|
||||
if ($this->statut >= 0)
|
||||
{
|
||||
$sql = "DELETE FROM ".MAIN_DB_PREFIX."contratdet";
|
||||
$sql.= " WHERE rowid=".$idline;
|
||||
|
||||
@@ -851,7 +851,7 @@ else
|
||||
}
|
||||
// Icon move, update et delete (statut contrat 0=brouillon,1=valide,2=ferme)
|
||||
print '<td align="right" nowrap="nowrap">';
|
||||
if ($user->rights->contrat->creer && sizeof($arrayothercontracts) && ($contrat->statut == 0 || ($contrat->statut >= 1 && empty($conf->global->CONTRAT_NOEDITWHENVALIDATED))))
|
||||
if ($user->rights->contrat->creer && sizeof($arrayothercontracts) && ($contrat->statut >= 0))
|
||||
{
|
||||
print '<a href="fiche.php?id='.$contrat->id.'&action=move&rowid='.$objp->rowid.'">';
|
||||
print img_picto($langs->trans("MoveToAnotherContract"),'uparrow');
|
||||
@@ -860,7 +860,7 @@ else
|
||||
else {
|
||||
print ' ';
|
||||
}
|
||||
if ($user->rights->contrat->creer && ($contrat->statut == 0 || ($contrat->statut >= 1 && empty($conf->global->CONTRAT_NOEDITWHENVALIDATED))) )
|
||||
if ($user->rights->contrat->creer && ($contrat->statut >= 0))
|
||||
{
|
||||
print '<a href="fiche.php?id='.$contrat->id.'&action=editline&rowid='.$objp->rowid.'">';
|
||||
print img_edit();
|
||||
@@ -869,7 +869,7 @@ else
|
||||
else {
|
||||
print ' ';
|
||||
}
|
||||
if ( $user->rights->contrat->creer && ($contrat->statut == 0 || ($contrat->statut >= 1 && empty($conf->global->CONTRAT_NOEDITWHENVALIDATED))) )
|
||||
if ( $user->rights->contrat->creer && ($contrat->statut >= 0))
|
||||
{
|
||||
print ' ';
|
||||
print '<a href="fiche.php?id='.$contrat->id.'&action=deleteline&rowid='.$objp->rowid.'">';
|
||||
@@ -1188,8 +1188,7 @@ else
|
||||
/*
|
||||
* Ajouter une ligne produit/service
|
||||
*/
|
||||
if ($user->rights->contrat->creer &&
|
||||
($contrat->statut == 0 || ($contrat->statut >= 1 && empty($conf->global->CONTRAT_NOEDITWHENVALIDATED))) )
|
||||
if ($user->rights->contrat->creer && ($contrat->statut >= 0))
|
||||
{
|
||||
print '<br>';
|
||||
print '<table class="noborder" width="100%">'; // Array with (n*2)+1 lines
|
||||
|
||||
Reference in New Issue
Block a user