diff --git a/htdocs/langs/en_US/productbatch.lang b/htdocs/langs/en_US/productbatch.lang index cdf1313509d..9b9fd13f5cb 100644 --- a/htdocs/langs/en_US/productbatch.lang +++ b/htdocs/langs/en_US/productbatch.lang @@ -20,3 +20,5 @@ AddDispatchBatchLine=Add a line for Shelf Life dispatching WhenProductBatchModuleOnOptionAreForced=When module Lot/Serial is on, increase/decrease stock mode is forced to last choice and can't be edited. Other options can be defined as you want. ProductDoesNotUseBatchSerial=This product does not use lot/serial number ProductLotSetup=Setup of module lot/serial +ShowCurrentStockOfLot=Show current stock for couple product/lot +ShowLogOfMovementIfLot=Show log of movements for couple product/lot diff --git a/htdocs/product/list.php b/htdocs/product/list.php index c95156b4393..ec55ad4f74c 100644 --- a/htdocs/product/list.php +++ b/htdocs/product/list.php @@ -177,7 +177,7 @@ if (is_array($extrafields->attribute_label) && count($extrafields->attribute_lab include DOL_DOCUMENT_ROOT.'/core/actions_changeselectedfields.inc.php'; -if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter.x") || GETPOST("button_removefilter")) // Both test are required to be compatible with all browsers +if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter.x") || GETPOST("button_removefilter")) // All test are required to be compatible with all browsers { $sall=""; $sref=""; diff --git a/htdocs/product/reassort.php b/htdocs/product/reassort.php index b4573bdc9e7..b193e553b61 100644 --- a/htdocs/product/reassort.php +++ b/htdocs/product/reassort.php @@ -73,18 +73,6 @@ if (! empty($canvas)) $objcanvas->getCanvas('product','list',$canvas); } -if (! empty($_POST["button_removefilter_x"])) -{ - $sref=""; - $snom=""; - $sall=""; - $search_sale=""; - $search_categ=""; - $type=""; - $catid=''; - $toolowstock=''; -} - // Define virtualdiffersfromphysical $virtualdiffersfromphysical=0; if (! empty($conf->global->STOCK_CALCULATE_ON_SHIPMENT) || ! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER)) @@ -98,7 +86,17 @@ if (! empty($conf->global->STOCK_CALCULATE_ON_SHIPMENT) || ! empty($conf->global * Actions */ -// None +if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter.x") || GETPOST("button_removefilter")) // All test are required to be compatible with all browsers +{ + $sref=""; + $snom=""; + $sall=""; + $search_sale=""; + $search_categ=""; + $type=""; + $catid=''; + $toolowstock=''; +} @@ -180,7 +178,7 @@ if ($resql) $i = 0; - if ($num == 1 && ($sall or $snom or $sref)) + if ($num == 1 && GETPOST('autojumpifoneonly') && ($sall || $snom || $sref)) { $objp = $db->fetch_object($resql); header("Location: card.php?id=$objp->rowid"); diff --git a/htdocs/product/reassortlot.php b/htdocs/product/reassortlot.php index 2e4438c416d..43f956b5eea 100644 --- a/htdocs/product/reassortlot.php +++ b/htdocs/product/reassortlot.php @@ -77,7 +77,13 @@ if (! empty($canvas)) $objcanvas->getCanvas('product','list',$canvas); } -if (! empty($_POST["button_removefilter_x"])) + + +/* + * Actions + */ + +if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter.x") || GETPOST("button_removefilter")) // All test are required to be compatible with all browsers { $sref=""; $snom=""; @@ -92,14 +98,6 @@ if (! empty($_POST["button_removefilter_x"])) } - -/* - * Actions - */ - -// None - - /* * View */ @@ -174,7 +172,7 @@ if ($resql) $i = 0; - if ($num == 1 && ($sall or $snom or $sref)) + if ($num == 1 && GETPOST('autojumpifoneonly') && ($sall or $snom or $sref)) { $objp = $db->fetch_object($resql); header("Location: card.php?id=$objp->rowid"); diff --git a/htdocs/product/stock/class/productlot.class.php b/htdocs/product/stock/class/productlot.class.php index 58adecd9651..c5f29df67c6 100644 --- a/htdocs/product/stock/class/productlot.class.php +++ b/htdocs/product/stock/class/productlot.class.php @@ -44,6 +44,8 @@ class Productlot extends CommonObject */ public $table_element = 'product_lot'; + public $picto='barcode'; + public $isnolinkedbythird = 1; public $ismultientitymanaged = 1; @@ -523,7 +525,7 @@ class Productlot extends CommonObject } /** - * Return a link to the user card (with optionaly the picto) + * Return a link to the a lot card (with optionaly the picto) * Use this->id,this->lastname, this->firstname * * @param int $withpicto Include picto in link (0=No picto, 1=Include picto into link, 2=Only picto) @@ -541,7 +543,6 @@ class Productlot extends CommonObject $result = ''; - $companylink = ''; $label = '' . $langs->trans("Batch") . ''; $label.= '