Fix do not share color for title of table and title of pages
This commit is contained in:
parent
2a6fbe3526
commit
3680202c1c
@ -85,7 +85,11 @@ if ($action == 'update')
|
||||
if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_BACKTITLE1', $conf->entity);
|
||||
else dolibarr_set_const($db, 'THEME_ELDY_BACKTITLE1', join(',',colorStringToArray(GETPOST('THEME_ELDY_BACKTITLE1'),array())),'chaine',0,'',$conf->entity);
|
||||
|
||||
if (GETPOST('THEME_ELDY_USE_HOVER') == '') dolibarr_del_const($db, "THEME_ELDY_USE_HOVER", $conf->entity);
|
||||
$val=(join(',',(colorStringToArray(GETPOST('THEME_ELDY_TEXTTITLENOTAB'),array()))));
|
||||
if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_TEXTTITLENOTAB', $conf->entity);
|
||||
else dolibarr_set_const($db, 'THEME_ELDY_TEXTTITLENOTAB', join(',',colorStringToArray(GETPOST('THEME_ELDY_TEXTTITLENOTAB'),array())),'chaine',0,'',$conf->entity);
|
||||
|
||||
if (GETPOST('THEME_ELDY_USE_HOVER') == '') dolibarr_del_const($db, "THEME_ELDY_USE_HOVER", $conf->entity);
|
||||
else dolibarr_set_const($db, "THEME_ELDY_USE_HOVER", $_POST["THEME_ELDY_USE_HOVER"], 'chaine', 0, '', $conf->entity);
|
||||
|
||||
$val=(join(',',(colorStringToArray(GETPOST('THEME_ELDY_TEXTLINK'),array()))));
|
||||
@ -157,7 +161,6 @@ if ($action == 'edit') // Edit
|
||||
clearstatcache();
|
||||
$var=true;
|
||||
|
||||
print load_fiche_titre($langs->trans("Language"),'','');
|
||||
print '<br>';
|
||||
print '<table summary="edit" class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td>'.$langs->trans("Parameters").'</td><td>'.$langs->trans("Value").'</td>';
|
||||
|
||||
@ -317,8 +317,8 @@ function show_theme($fuser,$edit=0,$foruserprofile=false)
|
||||
{
|
||||
print '<tr class="liste_titre"><th width="35%">'.$langs->trans("DefaultSkin").'</th>';
|
||||
print '<th align="right">';
|
||||
$url='http://www.dolistore.com/lang-en/4-skins';
|
||||
if (preg_match('/fr/i',$langs->defaultlang)) $url='http://www.dolistore.com/lang-fr/4-themes';
|
||||
$url='https://www.dolistore.com/lang-en/4-skins';
|
||||
if (preg_match('/fr/i',$langs->defaultlang)) $url='https://www.dolistore.com/fr/4-themes';
|
||||
//if (preg_match('/es/i',$langs->defaultlang)) $url='http://www.dolistore.com/lang-es/4-themes';
|
||||
print '<a href="'.$url.'" target="_blank">';
|
||||
print $langs->trans('DownloadMoreSkins');
|
||||
@ -506,6 +506,32 @@ function show_theme($fuser,$edit=0,$foruserprofile=false)
|
||||
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
// TextTitleColor
|
||||
if ($foruserprofile)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'>';
|
||||
print '<td>'.$langs->trans("TextTitleColor").'</td>';
|
||||
print '<td colspan="'.($colspan-1).'">';
|
||||
if ($edit)
|
||||
{
|
||||
print $formother->selectColor(colorArrayToHex(colorStringToArray($conf->global->THEME_ELDY_TEXTTITLENOTAB,array()),''),'THEME_ELDY_TEXTTITLENOTAB','formcolor',1).' ';
|
||||
}
|
||||
else
|
||||
{
|
||||
print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLENOTAB, $langs->trans("Default"));
|
||||
}
|
||||
print ' ('.$langs->trans("Default").': <strong>3c3c14</strong>, '.$langs->trans("NotSupportedByAllThemes").', '.$langs->trans("PressF5AfterChangingThis").')';
|
||||
print '</td>';
|
||||
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
// Use Hover
|
||||
$var=!$var;
|
||||
@ -539,7 +565,11 @@ function show_theme($fuser,$edit=0,$foruserprofile=false)
|
||||
{
|
||||
if ($conf->global->THEME_ELDY_USE_HOVER == '1') $color='edf4fb';
|
||||
else $color = colorArrayToHex(colorStringToArray($conf->global->THEME_ELDY_USE_HOVER,array()),'');
|
||||
if ($color) print '<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; width: 40px; background-color: #'.$color.'" value="'.$color.'">';
|
||||
if ($color)
|
||||
{
|
||||
if ($color != 'edf4fb') print '<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; width: 40px; background-color: #'.$color.'" value="'.$color.'">';
|
||||
else print $langs->trans("Default");
|
||||
}
|
||||
else print $langs->trans("None");
|
||||
}
|
||||
print ' ('.$langs->trans("Default").': <strong>edf4fb</strong>, '.$langs->trans("NotSupportedByAllThemes").', '.$langs->trans("PressF5AfterChangingThis").')';
|
||||
|
||||
@ -1664,6 +1664,7 @@ InstallModuleFromWebHasBeenDisabledByFile=Install of external module from applic
|
||||
ConfFileMuseContainCustom=Installing an external module from application save the module files into directory <strong>%s</strong>. To have this directory processed by Dolibarr, you must setup your <strong>conf/conf.php</strong> to have option<br>- <strong>$dolibarr_main_url_root_alt</strong> enabled to value <strong>$dolibarr_main_url_root_alt="/custom"</strong><br>- <strong>$dolibarr_main_document_root_alt</strong> enabled to value <strong>"%s/custom"</strong>
|
||||
HighlightLinesOnMouseHover=Highlight table lines when mouse move passes over
|
||||
HighlightLinesColor=Highlight color of the line when the mouse passes over (keep empty for no highlight)
|
||||
TextTitleColor=Color of page title
|
||||
LinkColor=Color of links
|
||||
PressF5AfterChangingThis=Press F5 on keyboard after changing this value to have it effective
|
||||
NotSupportedByAllThemes=Will works with eldy theme but is not supported by all themes
|
||||
|
||||
@ -90,7 +90,7 @@ $colorbacklinepair1='248,248,248'; // line pair
|
||||
$colorbacklinepair2='248,248,248'; // line pair
|
||||
$colorbacklinepairhover='238,246,252'; // line pair
|
||||
$colorbackbody='255,255,255';
|
||||
$colortexttitlenotab='80,80,0';
|
||||
$colortexttitlenotab='60,60,20';
|
||||
$colortexttitle='0,0,0';
|
||||
$colortext='0,0,0';
|
||||
$colortextlink='0,0,120';
|
||||
@ -100,11 +100,12 @@ $usegradient=1;
|
||||
$useboldtitle=1;
|
||||
|
||||
// Case of option always editable
|
||||
if (! isset($conf->global->THEME_ELDY_BACKBODY)) $conf->global->THEME_ELDY_BACKBODY='255,255,255';
|
||||
if (! isset($conf->global->THEME_ELDY_BACKBODY)) $conf->global->THEME_ELDY_BACKBODY=$colorbackbody;
|
||||
if (! isset($conf->global->THEME_ELDY_TOPMENU_BACK1)) $conf->global->THEME_ELDY_TOPMENU_BACK1='120,130,170';
|
||||
if (! isset($conf->global->THEME_ELDY_BACKTITLE1)) $conf->global->THEME_ELDY_BACKTITLE1='230,230,230';
|
||||
if (! isset($conf->global->THEME_ELDY_BACKTITLE1)) $conf->global->THEME_ELDY_BACKTITLE1=$colorbacktitle1;
|
||||
if (! isset($conf->global->THEME_ELDY_USE_HOVER)) $conf->global->THEME_ELDY_USE_HOVER=='238,246,252';
|
||||
if (! isset($conf->global->THEME_ELDY_TEXTLINK)) $conf->global->THEME_ELDY_TEXTLINK='0,0,120';
|
||||
if (! isset($conf->global->THEME_ELDY_TEXTTITLENOTAB)) $conf->global->THEME_ELDY_TEXTTITLENOTAB=$colortexttitlenotab;
|
||||
if (! isset($conf->global->THEME_ELDY_TEXTLINK)) $conf->global->THEME_ELDY_TEXTLINK=$colortextlink;
|
||||
|
||||
// Case of option editable only if option THEME_ELDY_ENABLE_PERSONALIZED is on
|
||||
if (empty($conf->global->THEME_ELDY_ENABLE_PERSONALIZED))
|
||||
@ -124,6 +125,7 @@ if (empty($conf->global->THEME_ELDY_ENABLE_PERSONALIZED))
|
||||
//var_dump($conf->global->THEME_ELDY_BACKBODY);
|
||||
//var_dump($user->conf->THEME_ELDY_BACKTITLE1);
|
||||
|
||||
|
||||
// Case of option availables only if THEME_ELDY_ENABLE_PERSONALIZED is on
|
||||
$colorbackhmenu1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TOPMENU_BACK1)?$colorbackhmenu1:$conf->global->THEME_ELDY_TOPMENU_BACK1) :(empty($user->conf->THEME_ELDY_TOPMENU_BACK1)?$colorbackhmenu1:$user->conf->THEME_ELDY_TOPMENU_BACK1);
|
||||
$colorbackvmenu1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_VERMENU_BACK1)?$colorbackvmenu1:$conf->global->THEME_ELDY_VERMENU_BACK1) :(empty($user->conf->THEME_ELDY_VERMENU_BACK1)?$colorbackvmenu1:$user->conf->THEME_ELDY_VERMENU_BACK1);
|
||||
@ -136,12 +138,12 @@ $colorbacklinepair1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty(
|
||||
$colorbacklinepair2 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_LINEPAIR2) ?$colorbacklinepair2:$conf->global->THEME_ELDY_LINEPAIR2) :(empty($user->conf->THEME_ELDY_LINEPAIR2)?$colorbacklinepair2:$user->conf->THEME_ELDY_LINEPAIR2);
|
||||
$colorbacklinepairhover=empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_LINEPAIRHOVER) ?$colorbacklinepairhover:$conf->global->THEME_ELDY_LINEPAIRHOVER) :(empty($user->conf->THEME_ELDY_LINEPAIRHOVER)?$colorbacklinepairhover:$user->conf->THEME_ELDY_LINEPAIRHOVER);
|
||||
$colorbackbody =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_BACKBODY) ?$colorbackbody:$conf->global->THEME_ELDY_BACKBODY) :(empty($user->conf->THEME_ELDY_BACKBODY)?$colorbackbody:$user->conf->THEME_ELDY_BACKBODY);
|
||||
$colortexttitle =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTTITLE) ?$colortext:$conf->global->THEME_ELDY_TEXTTITLE) :(empty($user->conf->THEME_ELDY_TEXTTITLE)?$colortexttitle:$user->conf->THEME_ELDY_TEXTTITLE);
|
||||
$colortexttitlenotab =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTTITLENOTAB)?$colortexttitlenotab:$conf->global->THEME_ELDY_TEXTTITLENOTAB) :(empty($user->conf->THEME_ELDY_TEXTTITLENOTAB)?$colortexttitlenotab:$user->conf->THEME_ELDY_TEXTTITLENOTAB);
|
||||
$colortexttitle =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTTITLE) ?$colortexttitle:$conf->global->THEME_ELDY_TEXTTITLE) :(empty($user->conf->THEME_ELDY_TEXTTITLE)?$colortexttitle:$user->conf->THEME_ELDY_TEXTTITLE);
|
||||
$colortext =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXT) ?$colortext:$conf->global->THEME_ELDY_TEXT) :(empty($user->conf->THEME_ELDY_TEXT)?$colortext:$user->conf->THEME_ELDY_TEXT);
|
||||
$colortextlink =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTLINK) ?$colortext:$conf->global->THEME_ELDY_TEXTLINK) :(empty($user->conf->THEME_ELDY_TEXTLINK)?$colortextlink:$user->conf->THEME_ELDY_TEXTLINK);
|
||||
$colortextlink =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTLINK) ?$colortextlink:$conf->global->THEME_ELDY_TEXTLINK) :(empty($user->conf->THEME_ELDY_TEXTLINK)?$colortextlink:$user->conf->THEME_ELDY_TEXTLINK);
|
||||
$fontsize =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_FONT_SIZE1) ?$fontsize:$conf->global->THEME_ELDY_FONT_SIZE1) :(empty($user->conf->THEME_ELDY_FONT_SIZE1)?$fontsize:$user->conf->THEME_ELDY_FONT_SIZE1);
|
||||
$fontsizesmaller =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_FONT_SIZE2) ?$fontsize:$conf->global->THEME_ELDY_FONT_SIZE2) :(empty($user->conf->THEME_ELDY_FONT_SIZE2)?$fontsize:$user->conf->THEME_ELDY_FONT_SIZE2);
|
||||
|
||||
// Hover color
|
||||
$colorbacklinepairhover=((! isset($conf->global->THEME_ELDY_USE_HOVER) || (string) $conf->global->THEME_ELDY_USE_HOVER === '0')?'':($conf->global->THEME_ELDY_USE_HOVER === '1'?'edf4fb':$conf->global->THEME_ELDY_USE_HOVER));
|
||||
if (! empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED))
|
||||
@ -186,6 +188,7 @@ $colorbacklinepair1=join(',',colorStringToArray($colorbacklinepair1));
|
||||
$colorbacklinepair2=join(',',colorStringToArray($colorbacklinepair2));
|
||||
if ($colorbacklinepairhover != '') $colorbacklinepairhover=join(',',colorStringToArray($colorbacklinepairhover));
|
||||
$colorbackbody=join(',',colorStringToArray($colorbackbody));
|
||||
$colortexttitlenotab=join(',',colorStringToArray($colortexttitlenotab));
|
||||
$colortexttitle=join(',',colorStringToArray($colortexttitle));
|
||||
$colortext=join(',',colorStringToArray($colortext));
|
||||
$colortextlink=join(',',colorStringToArray($colortextlink));
|
||||
@ -204,6 +207,7 @@ print 'colorbacklineimpair2='.$colorbacklineimpair2."\n";
|
||||
print 'colorbacklinepair1='.$colorbacklinepair1."\n";
|
||||
print 'colorbacklinepair2='.$colorbacklinepair2."\n";
|
||||
print 'colorbacklinepairhover='.$colorbacklinepairhover."\n";
|
||||
print '$colortexttitlenotab='.$colortexttitlenotab."\n";
|
||||
print '$colortexttitle='.$colortexttitle."\n";
|
||||
print '$colortext='.$colortext."\n";
|
||||
print '$colortextlink='.$colortextlink."\n";
|
||||
|
||||
@ -91,7 +91,7 @@ $colorbacklinepair1='250,250,250'; // line pair
|
||||
$colorbacklinepair2='248,248,248'; // line pair
|
||||
$colorbacklinepairhover='244,244,244'; // line pair
|
||||
$colorbackbody='255,255,255';
|
||||
$colortexttitlenotab='80,80,0';
|
||||
$colortexttitlenotab='90,90,90';
|
||||
$colortexttitle='0,0,0';
|
||||
$colortext='0,0,0';
|
||||
$colortextlink='0,0,120';
|
||||
@ -101,11 +101,12 @@ $usegradient=1;
|
||||
$useboldtitle=1;
|
||||
|
||||
// Case of option always editable
|
||||
if (! isset($conf->global->THEME_ELDY_BACKBODY)) $conf->global->THEME_ELDY_BACKBODY='255,255,255';
|
||||
if (! isset($conf->global->THEME_ELDY_TOPMENU_BACK1)) $conf->global->THEME_ELDY_TOPMENU_BACK1=join(',',colorStringToArray('#000000')); // topmenu (140,160,185)
|
||||
if (! isset($conf->global->THEME_ELDY_BACKTITLE1)) $conf->global->THEME_ELDY_BACKTITLE1='140,150,180'; // title of arrays TO MATCH ELDY (140,160,185)
|
||||
if (! isset($conf->global->THEME_ELDY_BACKBODY)) $conf->global->THEME_ELDY_BACKBODY=$colorbackbody;
|
||||
if (! isset($conf->global->THEME_ELDY_TOPMENU_BACK1)) $conf->global->THEME_ELDY_TOPMENU_BACK1='0,0,0';
|
||||
if (! isset($conf->global->THEME_ELDY_BACKTITLE1)) $conf->global->THEME_ELDY_BACKTITLE1=$colorbacktitle1;
|
||||
if (! isset($conf->global->THEME_ELDY_USE_HOVER)) $conf->global->THEME_ELDY_USE_HOVER=='238,246,252';
|
||||
if (! isset($conf->global->THEME_ELDY_TEXTLINK)) $conf->global->THEME_ELDY_TEXTLINK='0,0,120';
|
||||
if (! isset($conf->global->THEME_ELDY_TEXTTITLENOTAB)) $conf->global->THEME_ELDY_TEXTTITLENOTAB=$colortexttitlenotab;
|
||||
if (! isset($conf->global->THEME_ELDY_TEXTLINK)) $conf->global->THEME_ELDY_TEXTLINK=$colortextlink;
|
||||
|
||||
// Case of option editable only if option THEME_ELDY_ENABLE_PERSONALIZED is on
|
||||
if (empty($conf->global->THEME_ELDY_ENABLE_PERSONALIZED))
|
||||
@ -138,6 +139,7 @@ $colorbacklinepair1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty(
|
||||
$colorbacklinepair2 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_LINEPAIR2) ?$colorbacklinepair2:$conf->global->THEME_ELDY_LINEPAIR2) :(empty($user->conf->THEME_ELDY_LINEPAIR2)?$colorbacklinepair2:$user->conf->THEME_ELDY_LINEPAIR2);
|
||||
$colorbacklinepairhover =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_LINEPAIRHOVER) ?$colorbacklinepairhover:$conf->global->THEME_ELDY_LINEPAIRHOVER) :(empty($user->conf->THEME_ELDY_LINEPAIRHOVER)?$colorbacklinepairhover:$user->conf->THEME_ELDY_LINEPAIRHOVER);
|
||||
$colorbackbody =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_BACKBODY) ?$colorbackbody:$conf->global->THEME_ELDY_BACKBODY) :(empty($user->conf->THEME_ELDY_BACKBODY)?$colorbackbody:$user->conf->THEME_ELDY_BACKBODY);
|
||||
$colortexttitlenotab =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTTITLENOTAB)?$colortexttitlenotab:$conf->global->THEME_ELDY_TEXTTITLENOTAB) :(empty($user->conf->THEME_ELDY_TEXTTITLENOTAB)?$colortexttitlenotab:$user->conf->THEME_ELDY_TEXTTITLENOTAB);
|
||||
$colortexttitle =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTTITLE) ?$colortext:$conf->global->THEME_ELDY_TEXTTITLE) :(empty($user->conf->THEME_ELDY_TEXTTITLE)?$colortexttitle:$user->conf->THEME_ELDY_TEXTTITLE);
|
||||
$colortext =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXT) ?$colortext:$conf->global->THEME_ELDY_TEXT) :(empty($user->conf->THEME_ELDY_TEXT)?$colortext:$user->conf->THEME_ELDY_TEXT);
|
||||
$colortextlink =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXTLINK) ?$colortext:$conf->global->THEME_ELDY_TEXTLINK) :(empty($user->conf->THEME_ELDY_TEXTLINK)?$colortextlink:$user->conf->THEME_ELDY_TEXTLINK);
|
||||
@ -181,6 +183,7 @@ $colorbacklinepair1=join(',',colorStringToArray($colorbacklinepair1));
|
||||
$colorbacklinepair2=join(',',colorStringToArray($colorbacklinepair2));
|
||||
if ($colorbacklinepairhover != '') $colorbacklinepairhover=join(',',colorStringToArray($colorbacklinepairhover));
|
||||
$colorbackbody=join(',',colorStringToArray($colorbackbody));
|
||||
$colortexttitlenotab=join(',',colorStringToArray($colortexttitlenotab));
|
||||
$colortexttitle=join(',',colorStringToArray($colortexttitle));
|
||||
$colortext=join(',',colorStringToArray($colortext));
|
||||
$colortextlink=join(',',colorStringToArray($colortextlink));
|
||||
@ -199,6 +202,7 @@ print 'colorbacklineimpair2='.$colorbacklineimpair2."\n";
|
||||
print 'colorbacklinepair1='.$colorbacklinepair1."\n";
|
||||
print 'colorbacklinepair2='.$colorbacklinepair2."\n";
|
||||
print 'colorbacklinepairhover='.$colorbacklinepairhover."\n";
|
||||
print '$colortexttitlenotab='.$colortexttitlenotab."\n";
|
||||
print '$colortexttitle='.$colortexttitle."\n";
|
||||
print '$colortext='.$colortext."\n";
|
||||
print '$colortextlink='.$colortextlink."\n";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user