Merge branch 'dev' into 4515-addBuyCheck
gitea/salix/pipeline/pr-dev This commit looks good
Details
gitea/salix/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
commit
58daf4754b
|
@ -2,7 +2,7 @@ DELIMITER $$
|
||||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `edi`.`ekt_scan`(vBarcode VARCHAR(512))
|
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `edi`.`ekt_scan`(vBarcode VARCHAR(512))
|
||||||
BEGIN
|
BEGIN
|
||||||
/**
|
/**
|
||||||
* Busca transaciones a partir de un código de barras, las marca como escaneadas
|
* Busca transaciones a partir de un codigo de barras, las marca como escaneadas
|
||||||
* y las devuelve.
|
* y las devuelve.
|
||||||
* Ver https://wiki.verdnatura.es/index.php/Ekt#Algoritmos_de_lectura
|
* Ver https://wiki.verdnatura.es/index.php/Ekt#Algoritmos_de_lectura
|
||||||
*
|
*
|
||||||
|
@ -73,7 +73,7 @@ BEGIN
|
||||||
INSERT INTO tmp.ekt
|
INSERT INTO tmp.ekt
|
||||||
SELECT id
|
SELECT id
|
||||||
FROM ekt
|
FROM ekt
|
||||||
WHERE fec = vFec
|
WHERE fec >= vFec - INTERVAL 1 DAY
|
||||||
AND ((
|
AND ((
|
||||||
vKlo = vDefaultKlo
|
vKlo = vDefaultKlo
|
||||||
AND (klo = vKlo OR klo IS NULL OR klo = 0)
|
AND (klo = vKlo OR klo IS NULL OR klo = 0)
|
||||||
|
@ -82,7 +82,7 @@ BEGIN
|
||||||
AND auction = vAuction
|
AND auction = vAuction
|
||||||
AND agj = vShortAgj)
|
AND agj = vShortAgj)
|
||||||
)
|
)
|
||||||
ORDER BY agj DESC
|
ORDER BY agj DESC, fec DESC
|
||||||
LIMIT 1;
|
LIMIT 1;
|
||||||
|
|
||||||
SELECT COUNT(*) FROM tmp.ekt INTO vIsFound;
|
SELECT COUNT(*) FROM tmp.ekt INTO vIsFound;
|
||||||
|
|
Loading…
Reference in New Issue