Look: Utilisation de la fonction info_admin pour afficher alerte securit admin
This commit is contained in:
parent
13a83c4657
commit
0798e730be
@ -662,18 +662,18 @@ class Form
|
||||
|
||||
dolibarr_syslog("html.form.class::select_projects sql=$sql");
|
||||
|
||||
$result=$this->db->query($sql);
|
||||
if ($result)
|
||||
$resql=$this->db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
print '<select class="flat" name="'.$htmlname.'">';
|
||||
print '<option value="0"> </option>';
|
||||
$num = $this->db->num_rows($result);
|
||||
$num = $this->db->num_rows($resql);
|
||||
$i = 0;
|
||||
if ($num)
|
||||
{
|
||||
while ($i < $num)
|
||||
{
|
||||
$obj = $this->db->fetch_object();
|
||||
$obj = $this->db->fetch_object($resql);
|
||||
if (!empty($selected) && $selected == $obj->rowid)
|
||||
{
|
||||
print '<option value="'.$obj->rowid.'" selected="true">'.$obj->title.'</option>';
|
||||
@ -704,7 +704,7 @@ class Form
|
||||
function select_produits($selected='',$htmlname='productid',$filtretype='',$limit=20,$price_level=0)
|
||||
{
|
||||
global $langs,$conf,$user;
|
||||
if($conf->use_ajax)
|
||||
if ($conf->use_ajax)
|
||||
{
|
||||
print $langs->trans("Ref").':<input type="text" size="8" name="ajkeyref'.$htmlname.'" id="ajkeyref'.$htmlname.'"> ';
|
||||
print $langs->trans("Label").':<input type="text" size="16" name="ajkeylabel'.$htmlname.'" id="ajkeylabel'.$htmlname.'">';
|
||||
|
||||
@ -54,10 +54,9 @@ if ($user->admin && ! defined("MAIN_REMOVE_INSTALL_WARNING"))
|
||||
if (is_dir(DOL_DOCUMENT_ROOT."/install") && is_readable(DOL_DOCUMENT_ROOT."/install"))
|
||||
{
|
||||
$langs->load("other");
|
||||
print '<table width="100%"><tr><td>';
|
||||
print '<div class="warning">'.$langs->trans("WarningInstallDirExists",DOL_DOCUMENT_ROOT."/install").' ';
|
||||
print $langs->trans("WarningUntilDirRemoved",DOL_DOCUMENT_ROOT."/install").'</div>';
|
||||
print '</td></tr></table>';
|
||||
$message=$langs->trans("WarningInstallDirExists",DOL_DOCUMENT_ROOT."/install");
|
||||
$message.=$langs->trans("WarningUntilDirRemoved",DOL_DOCUMENT_ROOT."/install");
|
||||
print info_admin($message);
|
||||
print "<br>\n";
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user