From e6c103733ed6242fd60127cd57606b7de06216fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Mon, 16 May 2022 11:06:21 +0200 Subject: [PATCH] dlc dluo are inverted --- htdocs/reception/card.php | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/htdocs/reception/card.php b/htdocs/reception/card.php index c4a3b108b34..9e4cb346398 100644 --- a/htdocs/reception/card.php +++ b/htdocs/reception/card.php @@ -352,8 +352,10 @@ if (empty($reshook)) { } $qty = "qtyl".$i; $comment = "comment".$i; - $eatby = "dlc".$i; - $sellby = "dluo".$i; + // EATBY <-> DLUO see productbatch.class.php + // SELLBY <-> DLC + $eatby = "dluo".$i; + $sellby = "dlc".$i; $batch = "batch".$i; $cost_price = "cost_price".$i; @@ -628,9 +630,11 @@ if (empty($reshook)) { $batch = "batch".$line_id; $dlc = "dlc".$line_id; $dluo = "dluo".$line_id; - $eatby = GETPOST($dlc, 'alpha'); + // EATBY <-> DLUO + $eatby = GETPOST($dluo, 'alpha'); $eatbydate = str_replace('/', '-', $eatby); - $sellby = GETPOST($dluo, 'alpha'); + // SELLBY <-> DLC + $sellby = GETPOST($dlc, 'alpha'); $sellbydate = str_replace('/', '-', $sellby); $line->batch = GETPOST($batch, 'alpha'); $line->eatby = strtotime($eatbydate); @@ -641,8 +645,7 @@ if (empty($reshook)) { setEventMessages($line->error, $line->errors, 'errors'); $error++; } - } else // Product no predefined - { + } else { // Product no predefined $qty = "qtyl".$line_id; $line->id = $line_id; $line->qty = GETPOST($qty, 'int');