mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-07 16:41:48 +01:00
add new dolGetStatus to LibStatut in common invoice class
This commit is contained in:
@@ -3428,46 +3428,46 @@ class Commande extends CommonOrder
|
||||
if ($statut==self::STATUS_CANCELED){
|
||||
$labelstatut = $langs->trans('StatusOrderCanceled');
|
||||
$labelstatutShort = $langs->trans('StatusOrderCanceledShort');
|
||||
$statuttrans='status5';
|
||||
$statusType='status5';
|
||||
}
|
||||
elseif ($statut==self::STATUS_DRAFT){
|
||||
$labelstatut = $langs->trans('StatusOrderDraft');
|
||||
$labelstatutShort = $langs->trans('StatusOrderDraftShort');
|
||||
$statuttrans='status0';
|
||||
$statusType='status0';
|
||||
}
|
||||
elseif ($statut==self::STATUS_VALIDATED){
|
||||
$labelstatut = $langs->trans('StatusOrderValidated').$billedtext;
|
||||
$labelstatutShort = $langs->trans('StatusOrderValidatedShort').$billedtext;
|
||||
$statuttrans='status1';
|
||||
$statusType='status1';
|
||||
}
|
||||
elseif ($statut==self::STATUS_SHIPMENTONPROCESS){
|
||||
$labelstatut = $langs->trans('StatusOrderSentShort').$billedtext;
|
||||
$labelstatutShort = $langs->trans('StatusOrderSentShort').$billedtext;
|
||||
$statuttrans='status3';
|
||||
$statusType='status3';
|
||||
}
|
||||
elseif ($statut==self::STATUS_CLOSED && (! $billed && empty($conf->global->WORKFLOW_BILL_ON_SHIPMENT))){
|
||||
$labelstatut = $langs->trans('StatusOrderToBill');
|
||||
$labelstatutShort = $langs->trans('StatusOrderToBillShort');
|
||||
$statuttrans='status4';
|
||||
$statusType='status4';
|
||||
}
|
||||
elseif ($statut==self::STATUS_CLOSED && ($billed && empty($conf->global->WORKFLOW_BILL_ON_SHIPMENT))){
|
||||
$labelstatut = $langs->trans('StatusOrderProcessed').$billedtext;
|
||||
$labelstatutShort = $langs->trans('StatusOrderProcessed').$billedtext;
|
||||
$statuttrans='status6';
|
||||
$statusType='status6';
|
||||
}
|
||||
elseif ($statut==self::STATUS_CLOSED && (! empty($conf->global->WORKFLOW_BILL_ON_SHIPMENT))){
|
||||
$labelstatut = $langs->trans('StatusOrderDelivered');
|
||||
$labelstatutShort = $langs->trans('StatusOrderDelivered');
|
||||
$statuttrans='status6';
|
||||
$statusType='status6';
|
||||
}
|
||||
else{
|
||||
$labelstatut = $langs->trans('Unknown');
|
||||
$labelstatutShort = '';
|
||||
$statuttrans='';
|
||||
$statusType='';
|
||||
$mode = 0;
|
||||
}
|
||||
|
||||
return dolGetStatus($labelstatut, $labelstatutShort, '', $statuttrans, $mode);
|
||||
return dolGetStatus($labelstatut, $labelstatutShort, '', $statusType, $mode);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user