Fix: hide edit in place icon if MAIN_EDIT_ALSO_INLINE is not defined

This commit is contained in:
Regis Houssin 2011-11-06 00:14:08 +01:00
parent 995e07041a
commit 029c405b7d

View File

@ -84,13 +84,20 @@ class Form
$ret=''; $ret='';
if (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE)) if (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE))
{
if ($perm)
{ {
$tmp=explode(':',$typeofdata); $tmp=explode(':',$typeofdata);
$ret.= "\n".'<div class="editkey_'.$tmp[0].'" id="'.$htmlname.'">'; $ret.= '<div class="editkey_'.$tmp[0].'" id="'.$htmlname.'">';
$ret.= $langs->trans($text); $ret.= $langs->trans($text);
$ret.= '</div>'."\n"; $ret.= '</div>'."\n";
} }
else else
{
$ret.= $langs->trans($text);
}
}
else
{ {
$ret.='<table class="nobordernopadding" width="100%"><tr><td nowrap="nowrap">'; $ret.='<table class="nobordernopadding" width="100%"><tr><td nowrap="nowrap">';
$ret.=$langs->trans($text); $ret.=$langs->trans($text);
@ -230,7 +237,7 @@ class Form
} }
} }
$out.= "\n".'<div class="editval_'.$inputType.'" id="val_'.$htmlname.'">'; $out.= '<div class="editval_'.$inputType.'" id="val_'.$htmlname.'">';
$out.= $value; $out.= $value;
$out.= '</div>'."\n"; $out.= '</div>'."\n";
} }