Fix batch required for lot product error message.
This commit is contained in:
parent
44405e5415
commit
681c2a67bd
@ -156,7 +156,7 @@ ErrorPriceExpression22=Negative result '%s'
|
|||||||
ErrorPriceExpressionInternal=Internal error '%s'
|
ErrorPriceExpressionInternal=Internal error '%s'
|
||||||
ErrorPriceExpressionUnknown=Unknown error '%s'
|
ErrorPriceExpressionUnknown=Unknown error '%s'
|
||||||
ErrorSrcAndTargetWarehouseMustDiffers=Source and target warehouses must differs
|
ErrorSrcAndTargetWarehouseMustDiffers=Source and target warehouses must differs
|
||||||
ErrorTryToMakeMoveOnProductRequiringBatchData=Error, trying to make a stock movement without lot/serial information, on a product requiring lot/serial information
|
ErrorTryToMakeMoveOnProductRequiringBatchData=Error, trying to make a stock movement without lot/serial information, on product '%s' requiring lot/serial information
|
||||||
ErrorCantSetReceptionToTotalDoneWithReceptionToApprove=All recorded receptions must first be verified (approved or denied) before being allowed to do this action
|
ErrorCantSetReceptionToTotalDoneWithReceptionToApprove=All recorded receptions must first be verified (approved or denied) before being allowed to do this action
|
||||||
ErrorCantSetReceptionToTotalDoneWithReceptionDenied=All recorded receptions must first be verified (approved) before being allowed to do this action
|
ErrorCantSetReceptionToTotalDoneWithReceptionDenied=All recorded receptions must first be verified (approved) before being allowed to do this action
|
||||||
ErrorGlobalVariableUpdater0=HTTP request failed with error '%s'
|
ErrorGlobalVariableUpdater0=HTTP request failed with error '%s'
|
||||||
|
|||||||
@ -96,6 +96,7 @@ class MouvementStock extends CommonObject
|
|||||||
|
|
||||||
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/product/stock/class/productlot.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/product/stock/class/productlot.class.php';
|
||||||
|
$langs->load("errors");
|
||||||
$error = 0;
|
$error = 0;
|
||||||
dol_syslog(get_class($this)."::_create start userid=$user->id, fk_product=$fk_product, warehouse_id=$entrepot_id, qty=$qty, type=$type, price=$price, label=$label, inventorycode=$inventorycode, datem=".$datem.", eatby=".$eatby.", sellby=".$sellby.", batch=".$batch.", skip_batch=".$skip_batch);
|
dol_syslog(get_class($this)."::_create start userid=$user->id, fk_product=$fk_product, warehouse_id=$entrepot_id, qty=$qty, type=$type, price=$price, label=$label, inventorycode=$inventorycode, datem=".$datem.", eatby=".$eatby.", sellby=".$sellby.", batch=".$batch.", skip_batch=".$skip_batch);
|
||||||
|
|
||||||
@ -141,7 +142,7 @@ class MouvementStock extends CommonObject
|
|||||||
{
|
{
|
||||||
if (empty($batch))
|
if (empty($batch))
|
||||||
{
|
{
|
||||||
$this->errors[]=$langs->trans("ErrorTryToMakeMoveOnProductRequiringBatchData", $product->name);
|
$this->errors[]=$langs->trans("ErrorTryToMakeMoveOnProductRequiringBatchData", $product->ref);
|
||||||
dol_syslog("Try to make a movement of a product with status_batch on without any batch data");
|
dol_syslog("Try to make a movement of a product with status_batch on without any batch data");
|
||||||
|
|
||||||
$this->db->rollback();
|
$this->db->rollback();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user