forked from Wavyzz/dolibarr
Merge branch 'develop' of github.com:Dolibarr/dolibarr into theme_top_menu
This commit is contained in:
@@ -1065,7 +1065,7 @@ function dol_syslog($message, $level = LOG_INFO, $ident = 0, $suffixinfilename =
|
||||
* @param array $links Array of tabs. Currently initialized by calling a function xxx_admin_prepare_head
|
||||
* @param string $active Active tab name (document', 'info', 'ldap', ....)
|
||||
* @param string $title Title
|
||||
* @param int $notab -1 or 0=Add tab header, 1=no tab header. If you set this to 1, using dol_fiche_end() to close tab is not required.
|
||||
* @param int $notab -1 or 0=Add tab header, 1=no tab header (if you set this to 1, using dol_fiche_end() to close tab is not required), -2=Add tab header with no seaparation under tab (to start a tab just after)
|
||||
* @param string $picto Add a picto on tab title
|
||||
* @param int $pictoisfullpath If 1, image path is a full path. If you set this to 1, you can use url returned by dol_buildpath('/mymodyle/img/myimg.png',1) for $picto.
|
||||
* @param string $morehtmlright Add more html content on right of tabs title
|
||||
@@ -1083,7 +1083,7 @@ function dol_fiche_head($links = array(), $active = '0', $title = '', $notab = 0
|
||||
* @param array $links Array of tabs
|
||||
* @param string $active Active tab name
|
||||
* @param string $title Title
|
||||
* @param int $notab -1 or 0=Add tab header, 1=no tab header. If you set this to 1, using dol_fiche_end() to close tab is not required.
|
||||
* @param int $notab -1 or 0=Add tab header, 1=no tab header (if you set this to 1, using dol_fiche_end() to close tab is not required), -2=Add tab header with no seaparation under tab (to start a tab just after)
|
||||
* @param string $picto Add a picto on tab title
|
||||
* @param int $pictoisfullpath If 1, image path is a full path. If you set this to 1, you can use url returned by dol_buildpath('/mymodyle/img/myimg.png',1) for $picto.
|
||||
* @param string $morehtmlright Add more html content on right of tabs title
|
||||
@@ -1232,7 +1232,7 @@ function dol_get_fiche_head($links = array(), $active = '', $title = '', $notab
|
||||
|
||||
$out.="</div>\n";
|
||||
|
||||
if (! $notab || $notab == -1) $out.="\n".'<div class="tabBar'.($notab == -1 ? '' : ' tabBarWithBottom').'">'."\n";
|
||||
if (! $notab || $notab == -1 || $notab == -2) $out.="\n".'<div class="tabBar'.($notab == -1 ? '' : ($notab == -2 ? ' tabBarNoTop' : ' tabBarWithBottom')).'">'."\n";
|
||||
|
||||
$parameters=array('tabname' => $active, 'out' => $out);
|
||||
$reshook=$hookmanager->executeHooks('printTabsHead', $parameters); // This hook usage is called just before output the head of tabs. Take also a look at "completeTabsHead"
|
||||
@@ -2980,7 +2980,7 @@ function img_picto($titlealt, $picto, $moreatt = '', $pictoisfullpath = false, $
|
||||
//if (in_array($picto, array('switch_off', 'switch_on', 'off', 'on')))
|
||||
if (empty($srconly) && in_array($pictowithoutext, array(
|
||||
'bank', 'close_title', 'delete', 'edit', 'ellipsis-h', 'filter', 'grip', 'grip_title', 'list', 'listlight', 'off', 'on', 'play', 'playdisabled', 'printer', 'resize',
|
||||
'note', 'sign-out', 'split', 'switch_off', 'switch_on', 'unlink', 'uparrow', '1downarrow', '1uparrow',
|
||||
'note', 'sign-out', 'split', 'switch_off', 'switch_on', 'unlink', 'uparrow', '1downarrow', '1uparrow', '1leftarrow', '1rightarrow',
|
||||
'jabber','skype','twitter','facebook','linkedin'
|
||||
)
|
||||
)) {
|
||||
@@ -3053,12 +3053,10 @@ function img_picto($titlealt, $picto, $moreatt = '', $pictoisfullpath = false, $
|
||||
$fakey = 'fa-mail-forward';
|
||||
$facolor = '#555';
|
||||
}
|
||||
elseif ($pictowithoutext == '1uparrow') {
|
||||
$fakey = 'fa-caret-up';
|
||||
$marginleftonlyshort = 1;
|
||||
}
|
||||
elseif ($pictowithoutext == '1downarrow') {
|
||||
$fakey = 'fa-caret-down';
|
||||
elseif (in_array($pictowithoutext, array('1uparrow', '1downarrow', '1leftarrow', '1rightarrow', '1uparrow_selected', '1downarrow_selected', '1leftarrow_selected', '1rightarrow_selected'))) {
|
||||
$convertarray=array('1uparrow'=>'caret-up', '1downarrow'=>'caret-down', '1leftarrow'=>'caret-left', '1rightarrow'=>'caret-right', '1uparrow_selected'=>'caret-up', '1downarrow_selected'=>'caret-down', '1leftarrow_selected'=>'caret-left', '1rightarrow_selected'=>'caret-right');
|
||||
$fakey = 'fa-'.$convertarray[$pictowithoutext];
|
||||
if (preg_match('/selected/', $pictowithoutext)) $facolor = '#888';
|
||||
$marginleftonlyshort = 1;
|
||||
}
|
||||
elseif ($pictowithoutext == 'sign-out') {
|
||||
@@ -6833,7 +6831,8 @@ function picto_from_langcode($codelang, $moreatt = '')
|
||||
}
|
||||
|
||||
/**
|
||||
* Return default language from country code
|
||||
* Return default language from country code.
|
||||
* Return null if not found.
|
||||
*
|
||||
* @param string $countrycode Country code like 'US', 'FR', 'CA', ...
|
||||
* @return string Value of locale like 'en_US', 'fr_FR', ...
|
||||
@@ -6842,6 +6841,8 @@ function getLanguageCodeFromCountryCode($countrycode)
|
||||
{
|
||||
global $mysoc;
|
||||
|
||||
if (empty($countrycode)) return null;
|
||||
|
||||
if (strtoupper($countrycode) == 'MQ') return 'fr_CA';
|
||||
if (strtoupper($countrycode) == 'SE') return 'sv_SE'; // se_SE is Sami/Sweden, and we want in priority sv_SE for SE country
|
||||
if (strtoupper($countrycode) == 'CH')
|
||||
|
||||
Reference in New Issue
Block a user