diff --git a/htdocs/cashdesk/facturation.php b/htdocs/cashdesk/facturation.php index 47152524c4d..4d8f0264e5f 100644 --- a/htdocs/cashdesk/facturation.php +++ b/htdocs/cashdesk/facturation.php @@ -3,6 +3,7 @@ * Copyright (C) 2008-2011 Laurent Destailleur * Copyright (C) 2011 Juanjo Menent * Copyright (C) 2013 Marcos García + * Copyright (C) 2013 Adolfo Segura * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -45,7 +46,6 @@ if ( GETPOST('filtre') ) { //If the barcode looks like an EAN13 format and the last digit is included in it, //then whe look for the 12-digit too //As the twelve-digit string will also hit the 13-digit code, we only look for this one - //Some code written by "hipnosapo" forum user in http://www.dolibarr.es/index.php/foro/7-bugs-versiones-estables/3891-ean13-buscador-codigo-barras-13-digitos#3891 if (strlen($filtre) == 13) { $crit_12digit = substr($filtre, 0, 12); $sql .= " OR p.barcode LIKE '%".$db->escape($crit_12digit)."%')"; diff --git a/htdocs/product/liste.php b/htdocs/product/liste.php index 7fdbacea781..f602ec6509b 100644 --- a/htdocs/product/liste.php +++ b/htdocs/product/liste.php @@ -6,6 +6,7 @@ * Copyright (C) 2013 Juanjo Menent * Copyright (C) 2013 Raphaël Doursenaud * Copyright (C) 2013 Jean Heimburger + * Copyright (C) 2013 Adolfo segura * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -158,7 +159,6 @@ else //If the barcode looks like an EAN13 format and the last digit is included in it, //then whe look for the 12-digit too //As the twelve-digit string will also hit the 13-digit code, we only look for this one - //Some code written by "hipnosapo" forum user in http://www.dolibarr.es/index.php/foro/7-bugs-versiones-estables/3891-ean13-buscador-codigo-barras-13-digitos#3891 if (strlen($crit) == 13) { $crit_barcode = substr($crit, 0, 12); } else {