forked from Wavyzz/dolibarr
Merge branch 'theme_top_menu' of github.com:atm-john/dolibarr into theme_badge_status
This commit is contained in:
@@ -8043,14 +8043,12 @@ function dolGetStatus($statusLabel = '', $statusLabelShort = '', $html = '', $st
|
||||
else{ // $displayMode >= 6
|
||||
$return = $htmlLabel .' '. $htmlImg;
|
||||
}
|
||||
|
||||
}
|
||||
// Use new badge
|
||||
elseif(!empty($conf->global->MAIN_STATUS_USES_CSS) && !empty($displayMode)){
|
||||
|
||||
$statusLabelShort = !empty($statusLabelShort)?$statusLabelShort:$statusLabel;
|
||||
|
||||
|
||||
if($displayMode == 3){
|
||||
$return = dolGetBadge($statusLabel, '', $statusType, 'dot');
|
||||
}
|
||||
@@ -8060,7 +8058,6 @@ function dolGetStatus($statusLabel = '', $statusLabelShort = '', $html = '', $st
|
||||
else{
|
||||
$return = dolGetBadge($statusLabel, $html, $statusType);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return $return;
|
||||
|
||||
@@ -2200,11 +2200,11 @@ function colorStringToArray($stringcolor, $colorifnotfound = array(88,88,88))
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $color
|
||||
* @param boolean $allow_white
|
||||
* @param string $color the color you need to valid
|
||||
* @param boolean $allow_white in case of white isn't valid
|
||||
* @return boolean
|
||||
*/
|
||||
function colorValidateHex($color, $allow_white = false)
|
||||
function colorValidateHex($color, $allow_white = true)
|
||||
{
|
||||
|
||||
if(!$allow_white && ($color === '#fff' || $color === '#ffffff') ) return false;
|
||||
@@ -2218,8 +2218,8 @@ function colorValidateHex($color, $allow_white = false)
|
||||
|
||||
|
||||
/**
|
||||
* @param string $hex
|
||||
* @param integer $steps
|
||||
* @param string $hex color in hex
|
||||
* @param integer $steps Steps should be between -255 and 255. Negative = darker, positive = lighter
|
||||
* @return string
|
||||
*/
|
||||
function colorAdjustBrightness($hex, $steps)
|
||||
@@ -2247,7 +2247,7 @@ function colorAdjustBrightness($hex, $steps)
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $hex
|
||||
* @param string $hex color in hex
|
||||
* @param integer $percent 0 to 100
|
||||
* @return string
|
||||
*/
|
||||
@@ -2258,7 +2258,7 @@ function colorDarker($hex, $percent)
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $hex
|
||||
* @param string $hex color in hex
|
||||
* @param integer $percent 0 to 100
|
||||
* @return string
|
||||
*/
|
||||
@@ -2270,9 +2270,9 @@ function colorLighten($hex, $percent)
|
||||
|
||||
|
||||
/**
|
||||
* @param string $hex
|
||||
* @param string $hex color in hex
|
||||
* @param float $alpha 0 to 1
|
||||
* @param bool $returnArray :
|
||||
* @param bool $returnArray
|
||||
* @return string
|
||||
*/
|
||||
function colorHexToRgb($hex, $alpha = false, $returnArray = false)
|
||||
|
||||
@@ -76,5 +76,3 @@ $badgeStatus6='#cad2d2';
|
||||
$badgeStatus7='#baa32b';
|
||||
$badgeStatus8='#be3013';
|
||||
$badgeStatus9='#e7f0f0';
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user