Updated material qr pattern0 to allow space before KG #614
@@ -2455,7 +2455,7 @@ class CreateInvoiceValidation extends CreateRecord
|
||||
$this->dispatch('refreshMaterialInvoiceData', invoiceNumber: $invoiceNumber, plantId: $plantId);
|
||||
}
|
||||
|
||||
$pattern0 = '/^(?<item_code>[^|]+)\|(?<batch_id>[^|]+)\|(?<batch_count>[^|]+)\|(?<batch_quantity>[0-9]+(?:\.[0-9]+)?)kg$/i';
|
||||
$pattern0 = '/^(?<item_code>[^|]+)\|(?<batch_id>[^|]+)\|(?<batch_count>[^|]+)\|(?<batch_quantity>[0-9]+(?:\.[0-9]+)?)\s?kg$/i';
|
||||
$pattern1 = '/^(?<item_code>[^|]+)\|(?<batch_number>[^|]+)\|(?<batch_id>[^|]+)\|(?<batch_count>[^|]+)\/(?<batch_quantity>.+)$/i';
|
||||
$pattern2 = '/^(?<item_code>[^|]+)\|(?<batch_number>[^|]+)\|(?<batch_id>[^|]+)\|(?<batch_count>.+)$/i';
|
||||
$pattern3 = '/^(?<item_code>[^|]+)\|(?<batch_id>[^|]+)-(?<batch_count>.+)$/i';
|
||||
@@ -2470,7 +2470,7 @@ class CreateInvoiceValidation extends CreateRecord
|
||||
if (preg_match($pattern0, $serNo, $matches)) {
|
||||
$itemCode = $matches['item_code'];
|
||||
$this->currentItemCode = $itemCode;
|
||||
$curScanQty = $matches['batch_quantity'];
|
||||
$curScanQty = trim($matches['batch_quantity']);
|
||||
$serialNumber = $matches['batch_id'].'-'.$matches['batch_count'];
|
||||
$serNo = null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user