7983-testToMaster_2438 #2977
|
@ -15,9 +15,7 @@ describe('ticket assignCollection()', () => {
|
|||
args: {}
|
||||
};
|
||||
|
||||
spyOn(LoopBackContext, 'getCurrentContext').and.returnValue({
|
||||
active: ctx.req
|
||||
});
|
||||
spyOn(LoopBackContext, 'getCurrentContext').and.returnValue({active: ctx.req});
|
||||
|
||||
options = {transaction: tx};
|
||||
tx = await models.Sale.beginTransaction({});
|
||||
|
@ -25,7 +23,7 @@ describe('ticket assignCollection()', () => {
|
|||
});
|
||||
|
||||
afterEach(async() => {
|
||||
await tx.rollback();
|
||||
if (tx) await tx.rollback();
|
||||
});
|
||||
|
||||
it('should throw an error when there is not picking tickets', async() => {
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
module.exports = Self => {
|
||||
Self.remoteMethodCtx('killSession', {
|
||||
description: 'Kill session',
|
||||
accepts: [{
|
||||
arg: 'userId',
|
||||
type: 'integer',
|
||||
description: 'The user id',
|
||||
required: true,
|
||||
}, {
|
||||
arg: 'created',
|
||||
type: 'date',
|
||||
description: 'The created time',
|
||||
required: true,
|
||||
}],
|
||||
accessType: 'WRITE',
|
||||
http: {
|
||||
path: `/killSession`,
|
||||
verb: 'POST'
|
||||
}
|
||||
});
|
||||
|
||||
Self.killSession = async function(ctx, userId, created) {
|
||||
await Self.app.models.VnUser.userSecurity(ctx, ctx.req.accessToken.userId);
|
||||
const tokens = await Self.app.models.AccessToken.find({where: {userId, created}});
|
||||
if (!tokens?.length) return;
|
||||
for (const token of tokens)
|
||||
await Self.app.models.AccessToken.deleteById(token.id);
|
||||
};
|
||||
};
|
|
@ -175,6 +175,9 @@
|
|||
"ViaexpressConfig": {
|
||||
"dataSource": "vn"
|
||||
},
|
||||
"VnToken": {
|
||||
"dataSource": "vn"
|
||||
},
|
||||
"VnUser": {
|
||||
"dataSource": "vn"
|
||||
},
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
const vnModel = require('vn-loopback/common/models/vn-model');
|
||||
module.exports = function(Self) {
|
||||
vnModel(Self);
|
||||
require('../methods/vn-token/killSession')(Self);
|
||||
};
|
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
"name": "VnToken",
|
||||
"base": "AccessToken",
|
||||
"options": {
|
||||
"mysql": {
|
||||
"table": "salix.AccessToken"
|
||||
}
|
||||
},
|
||||
"properties": {
|
||||
"created": {
|
||||
"type": "date"
|
||||
}
|
||||
},
|
||||
"relations": {
|
||||
"user": {
|
||||
"type": "belongsTo",
|
||||
"model": "VnUser",
|
||||
"foreignKey": "userId"
|
||||
}
|
||||
},
|
||||
"hidden": ["id"]
|
||||
}
|
|
@ -25,6 +25,9 @@
|
|||
"isManaged": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"isDestiny": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"countryFk": {
|
||||
"type": "number"
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
},
|
||||
"vn": {
|
||||
"view": {
|
||||
"expeditionPallet_Print": "ced2b84a114fcb99fce05f0c34f4fc03f3fa387bef92621be1bc306608a84345"
|
||||
"expeditionPallet_Print": "99f75145ac2e7b612a6d71e74b6e55f194a465780fd9875a15eb01e6596b447e"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1959,7 +1959,7 @@ INSERT INTO `ACL` VALUES (746,'Claim','getSummary','READ','ALLOW','ROLE','claimV
|
|||
INSERT INTO `ACL` VALUES (747,'CplusRectificationType','*','READ','ALLOW','ROLE','administrative',NULL);
|
||||
INSERT INTO `ACL` VALUES (748,'SiiTypeInvoiceOut','*','READ','ALLOW','ROLE','salesPerson',NULL);
|
||||
INSERT INTO `ACL` VALUES (749,'InvoiceCorrectionType','*','READ','ALLOW','ROLE','salesPerson',NULL);
|
||||
INSERT INTO `ACL` VALUES (750,'InvoiceOut','transferInvoice','WRITE','ALLOW','ROLE','administrative',NULL);
|
||||
INSERT INTO `ACL` VALUES (750,'InvoiceOut','transfer','WRITE','ALLOW','ROLE','administrative',NULL);
|
||||
INSERT INTO `ACL` VALUES (751,'Application','executeProc','*','ALLOW','ROLE','employee',NULL);
|
||||
INSERT INTO `ACL` VALUES (752,'Application','executeFunc','*','ALLOW','ROLE','employee',NULL);
|
||||
INSERT INTO `ACL` VALUES (753,'NotificationSubscription','getList','READ','ALLOW','ROLE','employee',NULL);
|
||||
|
|
|
@ -1 +1,10 @@
|
|||
-- Executed after dump
|
||||
CREATE USER 'vn'@'localhost';
|
||||
|
||||
GRANT SELECT,
|
||||
INSERT,
|
||||
UPDATE,
|
||||
DELETE,
|
||||
CREATE TEMPORARY TABLES,
|
||||
EXECUTE,
|
||||
TRIGGER
|
||||
ON *.* TO 'vn'@'localhost';
|
||||
|
|
|
@ -108,6 +108,7 @@ INSERT INTO `vn`.`worker`(`id`,`code`, `firstName`, `lastName`, `bossFk`)
|
|||
UPDATE `vn`.`worker` SET bossFk = NULL WHERE id = 20;
|
||||
UPDATE `vn`.`worker` SET bossFk = 20 WHERE id = 1 OR id = 9;
|
||||
UPDATE `vn`.`worker` SET bossFk = 19 WHERE id = 18;
|
||||
UPDATE `vn`.`worker` SET bossFk = 50 WHERE id = 49;
|
||||
|
||||
DELETE FROM `vn`.`worker` WHERE firstName ='customer';
|
||||
|
||||
|
@ -582,6 +583,7 @@ INSERT INTO `vn`.`supplier`(`id`, `name`, `nickname`,`account`,`countryFk`,`nif`
|
|||
VALUES
|
||||
(1, 'PLANTS SL', 'Plants nick', 4100000001, 1, '06089160W', 0, util.VN_CURDATE(), 1, 'supplier address 1', 'GOTHAM', 1, 46000, 1, 1, 15, 4, 1, 1, 18, 'flowerPlants', 1, '400664487V'),
|
||||
(2, 'FARMER KING', 'The farmer', 4000020002, 1, '87945234L', 0, util.VN_CURDATE(), 1, 'supplier address 2', 'GOTHAM', 2, 46000, 1, 2, 10, 93, 2, 8, 18, 'animals', 1, '400664487V'),
|
||||
(4, 'INVENTARIO', 'INVENTARIO', 4000000004, NULL, NULL, 0, util.VN_CURDATE(), 1, NULL, NULL, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL, NULL, NULL),
|
||||
(69, 'PACKAGING', 'Packaging nick', 4100000069, 1, '94935005K', 0, util.VN_CURDATE(), 1, 'supplier address 5', 'ASGARD', 3, 46600, 1, 1, 15, 4, 1, 1, 18, 'flowerPlants', 1, '400664487V'),
|
||||
(442, 'VERDNATURA LEVANTE SL', 'Verdnatura', 5115000442, 1, '06815934E', 0, util.VN_CURDATE(), 1, 'supplier address 3', 'GOTHAM', 1, 46000, 1, 2, 15, 6, 9, 3, 18, 'complements', 1, '400664487V'),
|
||||
(567, 'HOLLAND', 'Holland nick', 4000020567, 1, '14364089Z', 0, util.VN_CURDATE(), 1, 'supplier address 6', 'ASGARD', 3, 46600, 1, 2, 10, 93, 2, 8, 18, 'animals', 1, '400664487V'),
|
||||
|
@ -1516,6 +1518,9 @@ INSERT INTO `vn`.`entry`(`id`, `supplierFk`, `created`, `travelFk`, `isConfirmed
|
|||
(9, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL +2 DAY), 10, 0, 442, 'IN2009', 'Movement 9', 1, 1, ''),
|
||||
(10, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL +2 DAY), 10, 0, 442, 'IN2009', 'Movement 9', 1, 1, '');
|
||||
|
||||
INSERT INTO `vn`.`entryConfig` (`defaultEntry`, `inventorySupplierFk`, `defaultSupplierFk`)
|
||||
VALUES (2, 4, 1);
|
||||
|
||||
INSERT INTO `bs`.`waste`(`buyerFk`, `year`, `week`, `itemFk`, `itemTypeFk`, `saleTotal`, `saleWasteQuantity`, `saleInternalWaste`, `saleExternalWaste`)
|
||||
VALUES
|
||||
('35', YEAR(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 WEEK)), WEEK(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 WEEK), 1), 1, 1, '1062', '51', '56.20', '56.20'),
|
||||
|
@ -3916,6 +3921,16 @@ INSERT INTO `vn`.`calendarHolidays` (calendarHolidaysTypeFk, dated, calendarHoli
|
|||
(1, '2001-05-17', 1, 5),
|
||||
(1, '2001-05-18', 1, 5);
|
||||
|
||||
INSERT INTO vn.medicalReview
|
||||
(id, workerFk, centerFk, `date`, `time`, isFit, amount, invoice, remark)
|
||||
VALUES(1, 1106, 1, '2000-01-01', '08:10', 1, 200.0, NULL, '');
|
||||
INSERT INTO vn.medicalReview
|
||||
(id, workerFk, centerFk, `date`, `time`, isFit, amount, invoice, remark)
|
||||
VALUES(2, 1106, 2, '2001-01-01', '09:10', 0, 10.0, NULL, NULL);
|
||||
INSERT INTO vn.medicalReview
|
||||
(id, workerFk, centerFk, `date`, `time`, isFit, amount, invoice, remark)
|
||||
VALUES(3, 9, 2, '2000-01-01', '8:00', 1, 150.0, NULL, NULL);
|
||||
|
||||
INSERT INTO vn.payrollComponent
|
||||
(id, name, isSalaryAgreed, isVariable, isException)
|
||||
VALUES
|
||||
|
@ -3954,6 +3969,6 @@ VALUES
|
|||
(5, 'Referencia Nominas', 'payRef'),
|
||||
(6, 'ABA', 'aba');
|
||||
|
||||
INSERT INTO vn.ormConfig SET
|
||||
id = 1,
|
||||
selectLimit = 1000;
|
||||
INSERT IGNORE INTO ormConfig
|
||||
SET id =1,
|
||||
selectLimit = 1000;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bi`.`clean`()
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bi`.`clean`()
|
||||
BEGIN
|
||||
DECLARE vDateShort DATETIME;
|
||||
DECLARE vDateLong DATETIME;
|
||||
|
@ -15,5 +15,5 @@ BEGIN
|
|||
|
||||
DELETE FROM bi.defaulters WHERE `date` < vDateLong;
|
||||
DELETE FROM bi.defaulting WHERE `date` < vDateLong;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bi`.`facturacion_media_anual_update`()
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bi`.`facturacion_media_anual_update`()
|
||||
BEGIN
|
||||
TRUNCATE TABLE bs.clientAnnualConsumption;
|
||||
|
||||
|
@ -12,5 +12,5 @@ BEGIN
|
|||
GROUP BY clientFk, year, month
|
||||
) vol
|
||||
GROUP BY clientFk;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bs`.`carteras_add`()
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bs`.`carteras_add`()
|
||||
BEGIN
|
||||
/**
|
||||
* Inserta en la tabla @bs.carteras las ventas desde el año pasado
|
||||
|
@ -23,5 +23,5 @@ BEGIN
|
|||
GROUP BY w.code, t.`year`, t.`month`;
|
||||
|
||||
DROP TEMPORARY TABLE tmp.time;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bs`.`nightTask_launchAll`()
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bs`.`nightTask_launchAll`()
|
||||
BEGIN
|
||||
/**
|
||||
* Runs all nightly tasks.
|
||||
|
@ -76,5 +76,5 @@ BEGIN
|
|||
END IF;
|
||||
END LOOP;
|
||||
CLOSE vQueue;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `bs`.`salesByItemTypeDay_addLauncher`()
|
||||
BEGIN
|
||||
CALL bs.salesByItemTypeDay_add(util.VN_CURDATE() - INTERVAL 30 DAY, util.VN_CURDATE());
|
||||
BEGIN
|
||||
CALL bs.salesByItemTypeDay_add(util.VN_CURDATE() - INTERVAL 30 DAY, util.VN_CURDATE());
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `cache`.`cache_calc_end`(IN `v_calc` INT)
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `cache`.`cache_calc_end`(IN `v_calc` INT)
|
||||
BEGIN
|
||||
DECLARE v_cache_name VARCHAR(255);
|
||||
DECLARE v_params VARCHAR(255);
|
||||
|
@ -21,5 +21,5 @@ BEGIN
|
|||
IF v_cache_name IS NOT NULL THEN
|
||||
DO RELEASE_LOCK(CONCAT_WS('/', v_cache_name, IFNULL(v_params, '')));
|
||||
END IF;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `cache`.`cache_calc_start`(OUT `v_calc` INT, INOUT `v_refresh` INT, IN `v_cache_name` VARCHAR(50), IN `v_params` VARCHAR(100))
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `cache`.`cache_calc_start`(OUT `v_calc` INT, INOUT `v_refresh` INT, IN `v_cache_name` VARCHAR(50), IN `v_params` VARCHAR(100))
|
||||
proc: BEGIN
|
||||
DECLARE v_valid BOOL;
|
||||
DECLARE v_lock_id VARCHAR(100);
|
||||
|
@ -83,5 +83,5 @@ proc: BEGIN
|
|||
-- Si se debe recalcular mantiene el bloqueo y devuelve su identificador.
|
||||
|
||||
SET v_refresh = TRUE;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -4,7 +4,7 @@ proc: BEGIN
|
|||
/**
|
||||
* Crea o actualiza la cache con la última compra y fecha de cada
|
||||
* artículo hasta ayer. Para obtener la última compra hasta una fecha
|
||||
* determinada utilizar el procedimiento vn.buyUltimate().
|
||||
* determinada utilizar el procedimiento vn.buy_getUltimate().
|
||||
*
|
||||
* @param vRefresh %TRUE para forzar el recálculo de la cache
|
||||
*/
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`claim_changeState`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`claim_changeState`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2024-06-06 07:52:46.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`client_unassignSalesPerson`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`client_unassignSalesPerson`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2023-06-01 03:30:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`client_userDisable`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`client_userDisable`
|
||||
ON SCHEDULE EVERY 1 MONTH
|
||||
STARTS '2023-06-01 00:00:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`collection_make`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`collection_make`
|
||||
ON SCHEDULE EVERY 5 MINUTE
|
||||
STARTS '2022-09-15 00:00:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`department_doCalc`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`department_doCalc`
|
||||
ON SCHEDULE EVERY 15 SECOND
|
||||
STARTS '2019-11-15 00:00:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`envialiaThreHoldChecker`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`envialiaThreHoldChecker`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2022-01-28 09:52:46.000'
|
||||
ON COMPLETION NOT PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`greuge_notify`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`greuge_notify`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2023-01-01 00:07:00.000'
|
||||
ON COMPLETION NOT PRESERVE
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`itemImageQueue_check`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`itemImageQueue_check`
|
||||
ON SCHEDULE EVERY 1 HOUR
|
||||
STARTS '2023-07-28 00:00:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
ENABLE
|
||||
DO BEGIN
|
||||
DELETE FROM itemImageQueue
|
||||
WHERE attempts >= (SELECT downloadMaxAttempts FROM itemConfig);
|
||||
DO BEGIN
|
||||
DELETE FROM itemImageQueue
|
||||
WHERE attempts >= (SELECT downloadMaxAttempts FROM itemConfig);
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`itemShelvingSale_doReserve`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`itemShelvingSale_doReserve`
|
||||
ON SCHEDULE EVERY 15 SECOND
|
||||
STARTS '2023-10-16 00:00:00'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`mysqlConnectionsSorter_kill`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`mysqlConnectionsSorter_kill`
|
||||
ON SCHEDULE EVERY 1 MINUTE
|
||||
STARTS '2021-10-28 09:56:27.000'
|
||||
ON COMPLETION NOT PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`printQueue_check`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`printQueue_check`
|
||||
ON SCHEDULE EVERY 10 MINUTE
|
||||
STARTS '2022-01-28 09:52:46.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`raidUpdate`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`raidUpdate`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2017-12-29 00:05:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`route_doRecalc`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`route_doRecalc`
|
||||
ON SCHEDULE EVERY 10 SECOND
|
||||
STARTS '2021-07-08 07:32:23.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`vehicle_notify`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`vehicle_notify`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2022-01-01 00:07:00.000'
|
||||
ON COMPLETION NOT PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`workerJourney_doRecalc`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`workerJourney_doRecalc`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2023-07-22 04:00:00.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`worker_updateChangedBusiness`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`worker_updateChangedBusiness`
|
||||
ON SCHEDULE EVERY 1 DAY
|
||||
STARTS '2000-01-01 00:00:05.000'
|
||||
ON COMPLETION NOT PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`zoneGeo_doCalc`
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` EVENT `vn`.`zoneGeo_doCalc`
|
||||
ON SCHEDULE EVERY 15 SECOND
|
||||
STARTS '2019-09-13 15:30:47.000'
|
||||
ON COMPLETION PRESERVE
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`MIDNIGHT`(vDate DATE)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`MIDNIGHT`(vDate DATE)
|
||||
RETURNS datetime
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`addressTaxArea`(vAddresId INT, vCompanyId INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`addressTaxArea`(vAddresId INT, vCompanyId INT)
|
||||
RETURNS varchar(25) CHARSET utf8mb3 COLLATE utf8mb3_general_ci
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`address_getGeo`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`address_getGeo`(vSelf INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`barcodeToItem`(vBarcode VARCHAR(22))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`barcodeToItem`(vBarcode VARCHAR(22))
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`buy_getUnitVolume`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`buy_getUnitVolume`(vSelf INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`buy_getVolume`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`buy_getVolume`(vSelf INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`catalog_componentReverse`(vWarehouse INT,
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`catalog_componentReverse`(vWarehouse INT,
|
||||
vCost DECIMAL(10,3),
|
||||
vM3 DECIMAL(10,3),
|
||||
vAddressFk INT,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`clientGetMana`(vClient INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`clientGetMana`(vClient INT)
|
||||
RETURNS decimal(10,2)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`clientGetSalesPerson`(vClientFk INT, vDated DATE)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`clientGetSalesPerson`(vClientFk INT, vDated DATE)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`clientTaxArea`(vClientId INT, vCompanyId INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`clientTaxArea`(vClientId INT, vCompanyId INT)
|
||||
RETURNS varchar(25) CHARSET utf8mb3 COLLATE utf8mb3_general_ci
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_getDebt`(`vClient` INT, `vDate` DATE)
|
||||
RETURNS decimal(10,2)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_getDebt`(`vClient` INT, `vDate` DATE)
|
||||
RETURNS decimal(10,2)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
BEGIN
|
||||
/**
|
||||
* Returns the risk of a customer.
|
||||
|
@ -34,5 +34,5 @@ BEGIN
|
|||
tmp.risk;
|
||||
|
||||
RETURN vDebt;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_getFromPhone`(vPhone VARCHAR(255))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_getFromPhone`(vPhone VARCHAR(255))
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_getSalesPerson`(vClientFk INT, vDated DATE)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_getSalesPerson`(vClientFk INT, vDated DATE)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_getSalesPersonByTicket`(vTicketFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_getSalesPersonByTicket`(vTicketFk INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_getSalesPersonCode`(vClientFk INT, vDated DATE)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_getSalesPersonCode`(vClientFk INT, vDated DATE)
|
||||
RETURNS varchar(3) CHARSET utf8mb3 COLLATE utf8mb3_general_ci
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_getSalesPersonCodeByTicket`(vTicketFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_getSalesPersonCodeByTicket`(vTicketFk INT)
|
||||
RETURNS varchar(3) CHARSET utf8mb3 COLLATE utf8mb3_general_ci
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`client_hasDifferentCountries`(vClientFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`client_hasDifferentCountries`(vClientFk INT)
|
||||
RETURNS tinyint(1)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`collection_isPacked`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`collection_isPacked`(vSelf INT)
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`currency_getCommission`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`currency_getCommission`(vSelf INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`currentRate`(vCurrencyFk INT, vDated DATE)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`currentRate`(vCurrencyFk INT, vDated DATE)
|
||||
RETURNS decimal(10,4)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`deviceProductionUser_accessGranted`(vUserFK INT(10) , android_id VARCHAR(50))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`deviceProductionUser_accessGranted`(vUserFK INT(10) , android_id VARCHAR(50))
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`duaTax_getRate`(vDuaFk INT, vTaxClassFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`duaTax_getRate`(vDuaFk INT, vTaxClassFk INT)
|
||||
RETURNS decimal(5,2)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`ekt_getEntry`(vEktFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`ekt_getEntry`(vEktFk INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`ekt_getTravel`(vEntryAssignFk INT, vEktFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`ekt_getTravel`(vEntryAssignFk INT, vEktFk INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`entry_getCommission`(vTravelFk INT,
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`entry_getCommission`(vTravelFk INT,
|
||||
vCurrencyFk INT,
|
||||
vSupplierFk INT
|
||||
)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`entry_getCurrency`(vCurrency INT,
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`entry_getCurrency`(vCurrency INT,
|
||||
vSupplierFk INT
|
||||
)
|
||||
RETURNS int(11)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`entry_getForLogiflora`(vLanded DATE, vWarehouseFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`entry_getForLogiflora`(vLanded DATE, vWarehouseFk INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`entry_isIntrastat`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`entry_isIntrastat`(vSelf INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`entry_isInventoryOrPrevious`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`entry_isInventoryOrPrevious`(vSelf INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`expedition_checkRoute`(vPalletFk INT,vExpeditionFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`expedition_checkRoute`(vPalletFk INT,vExpeditionFk INT)
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`firstDayOfWeek`(vYear INT, vWeek INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`firstDayOfWeek`(vYear INT, vWeek INT)
|
||||
RETURNS date
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getAlert3State`(vTicket INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getAlert3State`(vTicket INT)
|
||||
RETURNS varchar(45) CHARSET utf8mb3 COLLATE utf8mb3_unicode_ci
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getDueDate`(vDated DATE, vDayToPay INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getDueDate`(vDated DATE, vDayToPay INT)
|
||||
RETURNS date
|
||||
NOT DETERMINISTIC
|
||||
NO SQL
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getInventoryDate`()
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getInventoryDate`()
|
||||
RETURNS date
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
RETURN (SELECT inventoried FROM config LIMIT 1);
|
||||
BEGIN
|
||||
RETURN (SELECT inventoried FROM config LIMIT 1);
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getNewItemId`()
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getNewItemId`()
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getNextDueDate`(vDated DATE, vGapDays INT, vPayDay INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getNextDueDate`(vDated DATE, vGapDays INT, vPayDay INT)
|
||||
RETURNS date
|
||||
NOT DETERMINISTIC
|
||||
NO SQL
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getShipmentHour`(vTicket INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getShipmentHour`(vTicket INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getSpecialPrice`(vItemFk int(11),vClientFk int(11))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getSpecialPrice`(vItemFk int(11),vClientFk int(11))
|
||||
RETURNS decimal(10,2)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getTicketTrolleyLabelCount`(vTicket INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getTicketTrolleyLabelCount`(vTicket INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getUser`()
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getUser`()
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`getUserId`(userName varchar(30))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`getUserId`(userName varchar(30))
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`hasAnyNegativeBase`()
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`hasAnyNegativeBase`()
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`hasAnyPositiveBase`()
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`hasAnyPositiveBase`()
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`hasItemsInSector`(vTicketFk INT, vSectorFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`hasItemsInSector`(vTicketFk INT, vSectorFk INT)
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`hasSomeNegativeBase`(vTicket INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`hasSomeNegativeBase`(vTicket INT)
|
||||
RETURNS tinyint(1)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`intrastat_estimateNet`(
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`intrastat_estimateNet`(
|
||||
vSelf INT,
|
||||
vStems INT
|
||||
)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`invoiceOutAmount`(vInvoiceRef VARCHAR(15))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`invoiceOutAmount`(vInvoiceRef VARCHAR(15))
|
||||
RETURNS decimal(10,2)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`invoiceOut_getMaxIssued`(vSerial VARCHAR(2),
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`invoiceOut_getMaxIssued`(vSerial VARCHAR(2),
|
||||
vCompanyFk INT,
|
||||
vYear INT
|
||||
)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`invoiceOut_getPath`(vSelf INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`invoiceOut_getPath`(vSelf INT)
|
||||
RETURNS varchar(255) CHARSET utf8mb3 COLLATE utf8mb3_general_ci
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`invoiceOut_getWeight`(vInvoiceRef VARCHAR(15)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`invoiceOut_getWeight`(vInvoiceRef VARCHAR(15)
|
||||
)
|
||||
RETURNS decimal(10,2)
|
||||
NOT DETERMINISTIC
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`invoiceSerial`(
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`invoiceSerial`(
|
||||
vClientFk INT,
|
||||
vCompanyFk INT,
|
||||
vType CHAR(15)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`isLogifloraDay`(vShipped DATE, vWarehouse INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`isLogifloraDay`(vShipped DATE, vWarehouse INT)
|
||||
RETURNS tinyint(1)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`itemPacking`(vBarcode VARCHAR(22), vWarehouseFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`itemPacking`(vBarcode VARCHAR(22), vWarehouseFk INT)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`itemShelvingPlacementSupply_ClosestGet`(vParkingFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`itemShelvingPlacementSupply_ClosestGet`(vParkingFk INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`itemTag_getIntValue`(vValue VARCHAR(255))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`itemTag_getIntValue`(vValue VARCHAR(255))
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`item_getFhImage`(itemFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`item_getFhImage`(itemFk INT)
|
||||
RETURNS varchar(255) CHARSET utf8mb3 COLLATE utf8mb3_unicode_ci
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`item_getPackage`(vItemFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`item_getPackage`(vItemFk INT)
|
||||
RETURNS varchar(50) CHARSET utf8mb3 COLLATE utf8mb3_unicode_ci
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`item_getVolume`(vSelf INT, vPackaging VARCHAR(10))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`item_getVolume`(vSelf INT, vPackaging VARCHAR(10))
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`itemsInSector_get`(vTicketFk INT, vSectorFk INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`itemsInSector_get`(vTicketFk INT, vSectorFk INT)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`lastDayOfWeek`(vYear INT, vWeek INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`lastDayOfWeek`(vYear INT, vWeek INT)
|
||||
RETURNS date
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`machine_checkPlate`(vPlate VARCHAR(10))
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`machine_checkPlate`(vPlate VARCHAR(10))
|
||||
RETURNS tinyint(1)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`messageSend`(vRecipient VARCHAR(255) CHARSET utf8, vMessage TEXT CHARSET utf8)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`messageSend`(vRecipient VARCHAR(255) CHARSET utf8, vMessage TEXT CHARSET utf8)
|
||||
RETURNS int(11)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`messageSendWithUser`(vSenderFK INT, vRecipient VARCHAR(255) CHARSET utf8, vMessage TEXT CHARSET utf8)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`messageSendWithUser`(vSenderFK INT, vRecipient VARCHAR(255) CHARSET utf8, vMessage TEXT CHARSET utf8)
|
||||
RETURNS int(11)
|
||||
DETERMINISTIC
|
||||
BEGIN
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`orderTotalVolume`(vOrderId INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`orderTotalVolume`(vOrderId INT)
|
||||
RETURNS decimal(10,3)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` FUNCTION `vn`.`orderTotalVolumeBoxes`(vOrderId INT)
|
||||
CREATE OR REPLACE DEFINER=`vn`@`localhost` FUNCTION `vn`.`orderTotalVolumeBoxes`(vOrderId INT)
|
||||
RETURNS decimal(10,3)
|
||||
NOT DETERMINISTIC
|
||||
READS SQL DATA
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue