Ajout warning sur modif champ mot de passe si mode authentification externe à Dolibarr.
This commit is contained in:
parent
401a7428d7
commit
9796a9f088
@ -67,7 +67,7 @@ class Form
|
|||||||
/**
|
/**
|
||||||
\brief Affiche un texte+picto avec tooltip sur texte ou sur picto
|
\brief Affiche un texte+picto avec tooltip sur texte ou sur picto
|
||||||
\param text Texte à afficher
|
\param text Texte à afficher
|
||||||
\param htmltext Contenu html du tooltip
|
\param htmltext Contenu html du tooltip, codé en html
|
||||||
\param tooltipon 1=tooltip sur texte, 2=tooltip sur picto, 3=tooltip sur les 2
|
\param tooltipon 1=tooltip sur texte, 2=tooltip sur picto, 3=tooltip sur les 2
|
||||||
\param direction -1=Le picto est avant, 0=pas de picto, 1=le picto est après
|
\param direction -1=Le picto est avant, 0=pas de picto, 1=le picto est après
|
||||||
\param img Code img du picto
|
\param img Code img du picto
|
||||||
@ -85,6 +85,7 @@ class Form
|
|||||||
{
|
{
|
||||||
// Sanitize tooltip
|
// Sanitize tooltip
|
||||||
$htmltext=ereg_replace("'","\'",$htmltext);
|
$htmltext=ereg_replace("'","\'",$htmltext);
|
||||||
|
$htmltext=ereg_replace("'","\'",$htmltext);
|
||||||
if ($tooltipon==1 || $tooltipon==3)
|
if ($tooltipon==1 || $tooltipon==3)
|
||||||
{
|
{
|
||||||
$paramfortooltiptext.=' onmouseover="showtip(\''.$htmltext.'\')"';
|
$paramfortooltiptext.=' onmouseover="showtip(\''.$htmltext.'\')"';
|
||||||
@ -145,7 +146,7 @@ class Form
|
|||||||
*/
|
*/
|
||||||
function textwithwarning($text,$htmltext,$direction=1)
|
function textwithwarning($text,$htmltext,$direction=1)
|
||||||
{
|
{
|
||||||
return $this->textwithtooltip($text,$htmltext,2,$direction,img_warning("default"));
|
return $this->textwithtooltip($text,$htmltext,2,$direction,img_warning(""));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -31,6 +31,7 @@ ErrorDuplicateField=Duplicate value in a unique field
|
|||||||
ErrorSomeErrorWereFoundRollbackIsDone=Some errors were found. We rollback changes.
|
ErrorSomeErrorWereFoundRollbackIsDone=Some errors were found. We rollback changes.
|
||||||
ErrorConfigParameterNotDefined=Parameter <b>%s</b> is not defined inside Dolibarr config file <b>conf.php</b>.
|
ErrorConfigParameterNotDefined=Parameter <b>%s</b> is not defined inside Dolibarr config file <b>conf.php</b>.
|
||||||
ErrorCantLoadUserFromDolibarrDatabase=Failed to find user <b>%s</b> in Dolibarr database.
|
ErrorCantLoadUserFromDolibarrDatabase=Failed to find user <b>%s</b> in Dolibarr database.
|
||||||
|
DolibarrInHttpAuthenticationSoPasswordUseless=Dolibarr authentication mode is setup to <b>%s</b> in configuration file <b>conf.php</b>.<br>This means that password database is extern to Dolibarr, so changing this field may have no effects.
|
||||||
SeeAbove=See above
|
SeeAbove=See above
|
||||||
HomeArea=Home area
|
HomeArea=Home area
|
||||||
LastConnexion=Last connection
|
LastConnexion=Last connection
|
||||||
|
|||||||
@ -31,6 +31,7 @@ ErrorDuplicateField=Doublon dans un champ unique
|
|||||||
ErrorSomeErrorWereFoundRollbackIsDone=Des erreurs ont été trouvés. On rollback les modifications.
|
ErrorSomeErrorWereFoundRollbackIsDone=Des erreurs ont été trouvés. On rollback les modifications.
|
||||||
ErrorConfigParameterNotDefined=Le parametre <b>%s</b> n'est pas défini dans le fichier de configuration Dolibarr <b>conf.php</b>.
|
ErrorConfigParameterNotDefined=Le parametre <b>%s</b> n'est pas défini dans le fichier de configuration Dolibarr <b>conf.php</b>.
|
||||||
ErrorCantLoadUserFromDolibarrDatabase=Impossible de trouver l'utilisateur <b>%s</b> dans la base Dolibarr.
|
ErrorCantLoadUserFromDolibarrDatabase=Impossible de trouver l'utilisateur <b>%s</b> dans la base Dolibarr.
|
||||||
|
DolibarrInHttpAuthenticationSoPasswordUseless=Dolibarr est configuré en mode authentification <b>%s</b> dans son fichier de configuration <b>conf.php</b>.<br>Cela signifie que la base des mots de passe est externe à Dolibarr, aussi toute modification de ce champ peut s'avérer sans effet.
|
||||||
SeeAbove=Voir ci-dessus
|
SeeAbove=Voir ci-dessus
|
||||||
HomeArea=Espace accueil
|
HomeArea=Espace accueil
|
||||||
LastConnexion=Dernière connexion
|
LastConnexion=Dernière connexion
|
||||||
|
|||||||
@ -655,7 +655,7 @@ function top_menu($head, $title="", $target="")
|
|||||||
{
|
{
|
||||||
$title=$langs->trans("Logout");
|
$title=$langs->trans("Logout");
|
||||||
$title.='<br><b>'.$langs->trans("ConnectedSince").'</b>: '.dolibarr_print_date($user->datelastlogin,"%d/%m/%Y %H:%M:%S");
|
$title.='<br><b>'.$langs->trans("ConnectedSince").'</b>: '.dolibarr_print_date($user->datelastlogin,"%d/%m/%Y %H:%M:%S");
|
||||||
$title.='<br><b>'.$langs->trans("AuthenticationMode").'</b>: '.$dolibarr_main_authentication;
|
if ($dolibarr_main_authentication) $title.='<br><b>'.$langs->trans("AuthenticationMode").'</b>: '.$dolibarr_main_authentication;
|
||||||
|
|
||||||
$text.='<a href="'.DOL_URL_ROOT.'/user/logout.php"';
|
$text.='<a href="'.DOL_URL_ROOT.'/user/logout.php"';
|
||||||
$text.=$menutop->atarget?(' target="'.$menutop->atarget.'"'):'';
|
$text.=$menutop->atarget?(' target="'.$menutop->atarget.'"'):'';
|
||||||
|
|||||||
@ -94,7 +94,6 @@ $pos = strstr ($uri, '/'); // $pos contient alors url sans nom domaine
|
|||||||
if ($pos == '/') $pos = ''; // si $pos vaut /, on le met a ''
|
if ($pos == '/') $pos = ''; // si $pos vaut /, on le met a ''
|
||||||
define('DOL_URL_ROOT', $pos); // URL racine relative
|
define('DOL_URL_ROOT', $pos); // URL racine relative
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Creation objet $conf
|
* Creation objet $conf
|
||||||
*/
|
*/
|
||||||
|
|||||||
@ -1167,18 +1167,24 @@ else
|
|||||||
|
|
||||||
// Pass
|
// Pass
|
||||||
print '<tr><td valign="top">'.$langs->trans("Password").'</td>';
|
print '<tr><td valign="top">'.$langs->trans("Password").'</td>';
|
||||||
if ($fuser->ldap_sid)
|
print '<td>';
|
||||||
|
if ($fuser->ldap_sid)
|
||||||
{
|
{
|
||||||
print '<td>Mot de passe du domaine</td>';
|
$text='Mot de passe du domaine';
|
||||||
}
|
}
|
||||||
else if ($caneditpassword)
|
else if ($caneditpassword)
|
||||||
{
|
{
|
||||||
print '<td><input size="12" maxlength="32" type="password" class="flat" name="pass" value="'.$fuser->pass.'"></td>';
|
$text='<input size="12" maxlength="32" type="password" class="flat" name="pass" value="'.$fuser->pass.'">';
|
||||||
|
if ($dolibarr_main_authentication && $dolibarr_main_authentication == 'http')
|
||||||
|
{
|
||||||
|
$text=$html->textwithwarning($text,$langs->trans("DolibarrInHttpAuthenticationSoPasswordUseless",$dolibarr_main_authentication));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print '<td width="50%">'.eregi_replace('.','*',$fuser->pass);
|
$text=eregi_replace('.','*',$fuser->pass);
|
||||||
}
|
}
|
||||||
|
print $text;
|
||||||
print "</td></tr>\n";
|
print "</td></tr>\n";
|
||||||
|
|
||||||
// Administrateur
|
// Administrateur
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user