Skip to content
Snippets Groups Projects
Commit c340745b authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

FIX Option "showstock" was not effective into warehouse list

parent 09810395
No related branches found
No related tags found
No related merge requests found
......@@ -907,7 +907,8 @@ if ($action == 'create')
$tmpentrepot_id = is_numeric(GETPOST($ent,'int'))?GETPOST($ent,'int'):$warehouse_id;
if ($line->fk_product > 0)
{
print $formproduct->selectWarehouses($tmpentrepot_id,'entl'.$indiceAsked,'',1,0,$line->fk_product);
print '<!-- Show warehouse selection -->';
print $formproduct->selectWarehouses($tmpentrepot_id, 'entl'.$indiceAsked, '', 1, 0, $line->fk_product, '', 1);
if ($tmpentrepot_id > 0 && $tmpentrepot_id == $warehouse_id)
{
//print $stock.' '.$quantityToBeDelivered;
......
......@@ -165,7 +165,7 @@ class FormProduct
if ($selected == $id || ($selected == 'ifone' && $nbofwarehouses == 1)) $out.=' selected';
$out.='>';
$out.=$arraytypes['label'];
if (($fk_product || ($showstock > 0)) && ($arraytypes['stock'] != 0)) $out.='('.$langs->trans("Stock").':'.$arraytypes['stock'].')';
if (($fk_product || ($showstock > 0)) && ($arraytypes['stock'] != 0 || ($showstock > 0))) $out.=' ('.$langs->trans("Stock").':'.$arraytypes['stock'].')';
$out.='</option>';
}
$out.='</select>';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment