2
0
forked from Wavyzz/dolibarr

The property ->brouillon has been removed from all classes. It was not

reliable and was a duplicate of ->status == self::STATUS_DRAFT.
This commit is contained in:
Laurent Destailleur
2023-08-06 00:16:25 +02:00
parent 0baf8d4117
commit 0076ec69b8
23 changed files with 155 additions and 215 deletions

View File

@@ -608,8 +608,8 @@ class Commande extends CommonOrder
// Set new ref and current status
if (!$error) {
$this->ref = $num;
$this->statut = self::STATUS_VALIDATED;
$this->brouillon = 0;
$this->statut = self::STATUS_VALIDATED; // deprecated
$this->status = self::STATUS_VALIDATED;
}
if (!$error) {
@@ -909,7 +909,6 @@ class Commande extends CommonOrder
$error = 0;
// Clean parameters
$this->brouillon = 1; // set command as draft
// Set tmp vars
$date = ($this->date_commande ? $this->date_commande : $this->date);
@@ -1989,10 +1988,6 @@ class Commande extends CommonOrder
$this->lines = array();
if ($this->statut == self::STATUS_DRAFT) {
$this->brouillon = 1;
}
// Retrieve all extrafield
// fetch optionals attributes and labels
$this->fetch_optionals();