New: Links on composition page reach to composition page

This commit is contained in:
Laurent Destailleur 2011-09-07 19:18:28 +00:00
parent d562b9a0b3
commit 2721c9fda2
2 changed files with 10 additions and 5 deletions

View File

@ -2238,7 +2238,12 @@ class Product extends CommonObject
$lien = '<a href="'.DOL_URL_ROOT.'/product/stock/product.php?id='.$this->id.'">';
$lienfin='</a>';
}
else
else if ($option == 'composition')
{
$lien = '<a href="'.DOL_URL_ROOT.'/product/composition/fiche.php?id='.$this->id.'">';
$lienfin='</a>';
}
else
{
$lien = '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$this->id.'">';
$lienfin='</a>';

View File

@ -225,7 +225,7 @@ if ($id || $ref)
//print $productstatic->getNomUrl(1).'<br>';
//print $value[0]; // This contains a tr line.
print '<tr>';
print '<td>'.$productstatic->getNomUrl(1).' ('.$value['nb'].') &nbsp &nbsp</td>';
print '<td>'.$productstatic->getNomUrl(1,'composition').' ('.$value['nb'].') &nbsp &nbsp</td>';
if ($conf->stock->enabled) print '<td>'.$langs->trans("Stock").' : <b>'.$productstatic->stock_reel.'</b></td>';
print '</tr>';
}
@ -248,7 +248,7 @@ if ($id || $ref)
$productstatic->type=$value["fk_product_type"];
$productstatic->ref=$value['label'];
print '<tr>';
print '<td>'.$productstatic->getNomUrl(1).'</td>';;
print '<td>'.$productstatic->getNomUrl(1,'composition').'</td>';;
print '</tr>';
}
print '</table>';
@ -310,7 +310,7 @@ if ($id || $ref)
//print $productstatic->getNomUrl(1).'<br>';
//print $value[0]; // This contains a tr line.
print '<tr>';
print '<td>'.$productstatic->getNomUrl(1).' ('.$value['nb'].') &nbsp &nbsp</td>';
print '<td>'.$productstatic->getNomUrl(1,'composition').' ('.$value['nb'].') &nbsp &nbsp</td>';
if ($conf->stock->enabled) print '<td>'.$langs->trans("Stock").' : <b>'.$productstatic->stock_reel.'</b></td>';
print '</tr>';
}
@ -333,7 +333,7 @@ if ($id || $ref)
$productstatic->type=$value["fk_product_type"];
$productstatic->ref=$value['label'];
print '<tr>';
print '<td>'.$productstatic->getNomUrl(1).'</td>';;
print '<td>'.$productstatic->getNomUrl(1,'composition').'</td>';;
print '</tr>';
}
print '</table>';