Ajout tooltip Ajax sur les lignes de produits des commandes et factures lorsque la description n'est pas visible
Modifications esthtiques mineures
This commit is contained in:
parent
03903fffc7
commit
94f4609053
@ -1147,7 +1147,7 @@ if ($_GET['propalid'] > 0)
|
||||
// Icone d'edition et suppression
|
||||
if ($propal->statut == 0 && $user->rights->propale->creer)
|
||||
{
|
||||
print '<td align="right">';
|
||||
print '<td align="center">';
|
||||
if (($objp->info_bits & 2) == 2)
|
||||
{
|
||||
// Ligne remise prédéfinie, on permet pas modif
|
||||
@ -1159,30 +1159,34 @@ if ($_GET['propalid'] > 0)
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
print '<td align="center">';
|
||||
if ($conf->global->PRODUIT_CONFIRM_DELETE_LINE)
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=delete_product_line&ligne='.$objp->rowid.'">';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=delete_product_line&ligne='.$objp->rowid.'">';
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=del_ligne&ligne='.$objp->rowid.'">';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=del_ligne&ligne='.$objp->rowid.'">';
|
||||
}
|
||||
print img_delete();
|
||||
print '</a></td>';
|
||||
print '<td align="right">';
|
||||
if ($i > 0)
|
||||
if ($num > 1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=up&rowid='.$objp->rowid.'">';
|
||||
print img_up();
|
||||
print '</a>';
|
||||
print '<td align="center">';
|
||||
if ($i > 0)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=up&rowid='.$objp->rowid.'">';
|
||||
print img_up();
|
||||
print '</a>';
|
||||
}
|
||||
if ($i < $num-1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=down&rowid='.$objp->rowid.'">';
|
||||
print img_down();
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
}
|
||||
if ($i < $num-1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?propalid='.$propal->id.'&action=down&rowid='.$objp->rowid.'">';
|
||||
print img_down();
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -1308,11 +1308,19 @@ else
|
||||
{
|
||||
print '<td>';
|
||||
print '<a name="'.$objp->rowid.'"></a>'; // ancre pour retourner sur la ligne
|
||||
print '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$objp->fk_product.'">';
|
||||
if ($objp->fk_product_type==1) print img_object($langs->trans('ShowService'),'service');
|
||||
else print img_object($langs->trans('ShowProduct'),'product');
|
||||
print ' '.$objp->ref.'</a>';
|
||||
print ' - '.nl2br(stripslashes($objp->product));
|
||||
$text = '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$objp->fk_product.'">';
|
||||
if ($objp->fk_product_type==1) $text.= img_object($langs->trans('ShowService'),'service');
|
||||
else $text.= img_object($langs->trans('ShowProduct'),'product');
|
||||
$text.= ' '.$objp->ref.'</a>';
|
||||
$text.= ' - '.nl2br(stripslashes($objp->product));
|
||||
if ($conf->global->PRODUIT_DESC_IN_FORM)
|
||||
{
|
||||
print $text;
|
||||
}
|
||||
else
|
||||
{
|
||||
print $html->textwithtooltip($text,$objp->description,4,'','',$i,$objp->ref.' - '.nl2br(stripslashes($objp->product)));
|
||||
}
|
||||
print_date_range($objp->date_start,$objp->date_end);
|
||||
|
||||
if ($conf->global->PRODUIT_DESC_IN_FORM)
|
||||
@ -1381,33 +1389,46 @@ else
|
||||
// Icone d'edition et suppression
|
||||
if ($commande->statut == 0 && $user->rights->commande->creer)
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&action=editline&rowid='.$objp->rowid.'#'.$objp->rowid.'">';
|
||||
print img_edit();
|
||||
print '</a></td>';
|
||||
if ($conf->global->PRODUIT_CONFIRM_DELETE_LINE)
|
||||
print '<td align="center">';
|
||||
if (($objp->info_bits & 2) == 2)
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&action=delete_product_line&lineid='.$objp->rowid.'">';
|
||||
// Ligne remise prédéfinie, on permet pas modif
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&action=deleteline&lineid='.$objp->rowid.'">';
|
||||
}
|
||||
print img_delete();
|
||||
print '</a></td>';
|
||||
print '<td align="right">';
|
||||
if ($i > 0)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$commande->id.'&action=up&rowid='.$objp->rowid.'">';
|
||||
print img_up();
|
||||
print '</a>';
|
||||
}
|
||||
if ($i < $num-1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$commande->id.'&action=down&rowid='.$objp->rowid.'">';
|
||||
print img_down();
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&action=editline&rowid='.$objp->rowid.'#'.$objp->rowid.'">';
|
||||
print img_edit();
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
print '<td align="center">';
|
||||
if ($conf->global->PRODUIT_CONFIRM_DELETE_LINE)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&action=delete_product_line&lineid='.$objp->rowid.'">';
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&action=deleteline&lineid='.$objp->rowid.'">';
|
||||
}
|
||||
print img_delete();
|
||||
print '</a></td>';
|
||||
if ($num > 1)
|
||||
{
|
||||
print '<td align="center">';
|
||||
if ($i > 0)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$commande->id.'&action=up&rowid='.$objp->rowid.'">';
|
||||
print img_up();
|
||||
print '</a>';
|
||||
}
|
||||
if ($i < $num-1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$commande->id.'&action=down&rowid='.$objp->rowid.'">';
|
||||
print img_down();
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -2226,11 +2226,19 @@ else
|
||||
{
|
||||
print '<td>';
|
||||
print '<a name="'.$objp->rowid.'"></a>'; // ancre pour retourner sur la ligne
|
||||
print '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$objp->fk_product.'">';
|
||||
if ($objp->fk_product_type==1) print img_object($langs->trans('ShowService'),'service');
|
||||
else print img_object($langs->trans('ShowProduct'),'product');
|
||||
print ' '.$objp->ref.'</a>';
|
||||
print ' - '.nl2br(stripslashes($objp->product));
|
||||
$text = '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$objp->fk_product.'">';
|
||||
if ($objp->fk_product_type==1) $text.= img_object($langs->trans('ShowService'),'service');
|
||||
else $text.= img_object($langs->trans('ShowProduct'),'product');
|
||||
$text.= ' '.$objp->ref.'</a>';
|
||||
$text.= ' - '.nl2br(stripslashes($objp->product));
|
||||
if ($conf->global->PRODUIT_DESC_IN_FORM)
|
||||
{
|
||||
print $text;
|
||||
}
|
||||
else
|
||||
{
|
||||
print $html->textwithtooltip($text,$objp->description,4,'','',$i,$objp->ref.' - '.nl2br(stripslashes($objp->product)));
|
||||
}
|
||||
print_date_range($objp->date_start,$objp->date_end);
|
||||
|
||||
if ($conf->global->PRODUIT_DESC_IN_FORM)
|
||||
@ -2299,7 +2307,7 @@ else
|
||||
// Icone d'edition et suppression
|
||||
if ($fac->statut == 0 && $user->rights->facture->creer)
|
||||
{
|
||||
print '<td align="right">';
|
||||
print '<td align="center">';
|
||||
if (($objp->info_bits & 2) == 2)
|
||||
{
|
||||
// Ligne remise prédéfinie, on permet pas modif
|
||||
@ -2311,30 +2319,34 @@ else
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
print '<td align="center">';
|
||||
if ($conf->global->PRODUIT_CONFIRM_DELETE_LINE)
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=delete_product_line&rowid='.$objp->rowid.'">';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=delete_product_line&rowid='.$objp->rowid.'">';
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=deleteline&rowid='.$objp->rowid.'">';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=deleteline&rowid='.$objp->rowid.'">';
|
||||
}
|
||||
print img_delete();
|
||||
print '</a></td>';
|
||||
print '<td align="right">';
|
||||
if ($i > 0)
|
||||
if ($num_lignes > 1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=up&rowid='.$objp->rowid.'">';
|
||||
print img_up();
|
||||
print '</a>';
|
||||
print '<td align="center">';
|
||||
if ($i > 0)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=up&rowid='.$objp->rowid.'">';
|
||||
print img_up();
|
||||
print '</a>';
|
||||
}
|
||||
if ($i < $num_lignes-1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=down&rowid='.$objp->rowid.'">';
|
||||
print img_down();
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
}
|
||||
if ($i < $num_lignes-1)
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?facid='.$fac->id.'&action=down&rowid='.$objp->rowid.'">';
|
||||
print img_down();
|
||||
print '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user