Fix look and feel v11
This commit is contained in:
parent
7c71f6cae9
commit
49a8b4544e
@ -1291,7 +1291,6 @@ class FactureRec extends CommonInvoice
|
|||||||
*/
|
*/
|
||||||
public function getLibStatut($mode = 0, $alreadypaid = -1)
|
public function getLibStatut($mode = 0, $alreadypaid = -1)
|
||||||
{
|
{
|
||||||
|
|
||||||
return $this->LibStatut($this->frequency ? 1 : 0, $this->suspended, $mode, $alreadypaid, empty($this->type) ? 0 : $this->type);
|
return $this->LibStatut($this->frequency ? 1 : 0, $this->suspended, $mode, $alreadypaid, empty($this->type) ? 0 : $this->type);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1312,19 +1311,30 @@ class FactureRec extends CommonInvoice
|
|||||||
global $langs;
|
global $langs;
|
||||||
$langs->load('bills');
|
$langs->load('bills');
|
||||||
|
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
$statusType = 'status0';
|
||||||
|
|
||||||
//print "$recur,$status,$mode,$alreadypaid,$type";
|
//print "$recur,$status,$mode,$alreadypaid,$type";
|
||||||
if ($mode == 0)
|
if ($mode == 0)
|
||||||
{
|
{
|
||||||
$prefix = '';
|
$prefix = '';
|
||||||
if ($recur)
|
if ($recur)
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return $langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return $langs->trans('Active');
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return $langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return $langs->trans("Draft");
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$labelStatus = $langs->trans("Draft");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif ($mode == 1)
|
elseif ($mode == 1)
|
||||||
@ -1332,26 +1342,46 @@ class FactureRec extends CommonInvoice
|
|||||||
$prefix = 'Short';
|
$prefix = 'Short';
|
||||||
if ($recur)
|
if ($recur)
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return $langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return $langs->trans('Active');
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return $langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return $langs->trans("Draft");
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$labelStatus = $langs->trans("Draft");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif ($mode == 2)
|
elseif ($mode == 2)
|
||||||
{
|
{
|
||||||
if ($recur)
|
if ($recur)
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return img_picto($langs->trans('Disabled'), 'statut6').' '.$langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return img_picto($langs->trans('Active'), 'statut4').' '.$langs->trans('Active');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status4';
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return img_picto($langs->trans('Disabled'), 'statut6').' '.$langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return img_picto($langs->trans('Draft'), 'statut0').' '.$langs->trans('Draft');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status0';
|
||||||
|
$labelStatus = $langs->trans('Draft');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif ($mode == 3)
|
elseif ($mode == 3)
|
||||||
@ -1359,13 +1389,25 @@ class FactureRec extends CommonInvoice
|
|||||||
if ($recur)
|
if ($recur)
|
||||||
{
|
{
|
||||||
$prefix = 'Short';
|
$prefix = 'Short';
|
||||||
if ($status == self::STATUS_SUSPENDED) return img_picto($langs->trans('Disabled'), 'statut6');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return img_picto($langs->trans('Active'), 'statut4');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status4';
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return img_picto($langs->trans('Disabled'), 'statut6');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return img_picto($langs->trans('Draft'), 'statut0');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status0';
|
||||||
|
$labelStatus = $langs->trans('Draft');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif ($mode == 4)
|
elseif ($mode == 4)
|
||||||
@ -1373,13 +1415,25 @@ class FactureRec extends CommonInvoice
|
|||||||
$prefix = '';
|
$prefix = '';
|
||||||
if ($recur)
|
if ($recur)
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return img_picto($langs->trans('Disabled'), 'statut6').' '.$langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return img_picto($langs->trans('Active'), 'statut4').' '.$langs->trans('Active');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status4';
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return img_picto($langs->trans('Disabled'), 'statut6').' '.$langs->trans('Disabled');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return img_picto($langs->trans('Draft'), 'statut0').' '.$langs->trans('Draft');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status0';
|
||||||
|
$labelStatus = $langs->trans('Draft');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif ($mode == 5 || $mode == 6)
|
elseif ($mode == 5 || $mode == 6)
|
||||||
@ -1388,15 +1442,31 @@ class FactureRec extends CommonInvoice
|
|||||||
if ($mode == 5) $prefix = 'Short';
|
if ($mode == 5) $prefix = 'Short';
|
||||||
if ($recur)
|
if ($recur)
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return '<span class="xhideonsmartphone">'.$langs->trans('Disabled').' </span>'.img_picto($langs->trans('Disabled'), 'statut6');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return '<span class="xhideonsmartphone">'.$langs->trans('Active').' </span>'.img_picto($langs->trans('Active'), 'statut4');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status4';
|
||||||
|
$labelStatus = $langs->trans('Active');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($status == self::STATUS_SUSPENDED) return '<span class="xhideonsmartphone">'.$langs->trans('Disabled').' </span>'.img_picto($langs->trans('Disabled'), 'statut6');
|
if ($status == self::STATUS_SUSPENDED) {
|
||||||
else return $langs->trans('Draft').' '.img_picto($langs->trans('Active'), 'statut0');
|
$statusType = 'status6';
|
||||||
|
$labelStatus = $langs->trans('Disabled');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$statusType = 'status0';
|
||||||
|
$labelStatus = $langs->trans('Draft');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (empty($labelStatusShort)) $labelStatusShort = $labelStatus;
|
||||||
|
|
||||||
|
return dolGetStatus($labelStatus, $labelStatusShort, '', $statusType, $mode);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user