diff --git a/db/dump/fixtures.sql b/db/dump/fixtures.sql index 1b2caad96..231bdf819 100644 --- a/db/dump/fixtures.sql +++ b/db/dump/fixtures.sql @@ -352,9 +352,9 @@ INSERT INTO `vn`.`creditInsurance`(`id`, `creditClassification`, `credit`, `crea INSERT INTO `vn`.`route`(`id`, `time`, `workerFk`, `created`, `vehicleFk`, `agencyModeFk`, `description`, `m3`, `cost`, `started`, `finished`) VALUES - (1, '1899-12-30 12:15:00', 56, CURDATE(), 1, 7, 'first route', 0.3, 10, CURDATE(), CURDATE()), - (2, '1899-12-30 13:20:00', 56, CURDATE(), 1, 7, 'second route', 0.1, 20, CURDATE(), CURDATE()), - (3, '1899-12-30 14:30:00', 56, CURDATE(), 2, 7, 'third route', 0.1, 30, CURDATE(), CURDATE()), + (1, '1899-12-30 12:15:00', 56, CURDATE(), 1, 7, 'first route', 2.7, 10, CURDATE(), CURDATE()), + (2, '1899-12-30 13:20:00', 56, CURDATE(), 1, 7, 'second route', 0.9, 20, CURDATE(), CURDATE()), + (3, '1899-12-30 14:30:00', 56, CURDATE(), 2, 7, 'third route', 1.1, 30, CURDATE(), CURDATE()), (4, '1899-12-30 15:45:00', 56, CURDATE(), 3, 7, 'fourth route', 0.1, 40, CURDATE(), CURDATE()), (5, '1899-12-30 16:00:00', 56, CURDATE(), 4, 8, 'fifth route', NULL, 50, CURDATE(), CURDATE()), (6, NULL, 57, CURDATE(), 5, 8, 'sixth route', NULL, 60, CURDATE(), CURDATE()), @@ -425,7 +425,7 @@ INSERT INTO `vn`.`ticket`(`id`, `priority`, `agencyModeFk`,`warehouseFk`,`routeF VALUES (1 , 3, 1, 1, 1, DATE_ADD(CURDATE(), INTERVAL -1 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -1 MONTH), INTERVAL +1 DAY), 101, 'Bat cave', 121, 'T1111111', 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), (2 , 1, 1, 1, 1, DATE_ADD(CURDATE(), INTERVAL -1 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -1 MONTH), INTERVAL +1 DAY), 104, 'Stark tower', 124, 'T1111111', 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (3 , 1, 2, 1, 1, DATE_ADD(CURDATE(), INTERVAL -2 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -2 MONTH), INTERVAL +1 DAY), 104, 'Stark tower', 124, 'T2222222', 0, DATE_ADD(CURDATE(), INTERVAL -2 MONTH)), + (3 , 1, 7, 1, 1, DATE_ADD(CURDATE(), INTERVAL -2 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -2 MONTH), INTERVAL +1 DAY), 104, 'Stark tower', 124, 'T2222222', 0, DATE_ADD(CURDATE(), INTERVAL -2 MONTH)), (4 , 3, 2, 1, 1, DATE_ADD(CURDATE(), INTERVAL -3 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -3 MONTH), INTERVAL +1 DAY), 104, 'Stark tower', 124, 'T3333333', 0, DATE_ADD(CURDATE(), INTERVAL -3 MONTH)), (5 , 3, 3, 3, 1, DATE_ADD(CURDATE(), INTERVAL -4 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -4 MONTH), INTERVAL +1 DAY), 104, 'Stark tower', 124, 'T4444444', 0, DATE_ADD(CURDATE(), INTERVAL -4 MONTH)), (6 , 1, 3, 3, 1, DATE_ADD(CURDATE(), INTERVAL -1 MONTH), DATE_ADD(DATE_ADD(CURDATE(),INTERVAL -1 MONTH), INTERVAL +1 DAY), 101, 'Mountain Drive Gotham', 1, 'A1111111', 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), @@ -617,9 +617,12 @@ INSERT INTO `vn`.`expedition`(`id`, `agencyModeFk`, `ticketFk`, `isBox`, `create INSERT INTO `vn`.`packaging`(`id`, `volume`, `width`, `height`, `depth`, `isPackageReturnable`, `created`, `itemFk`, `price`) VALUES - (1, 0.00, 10, 10, 0, 0, CURDATE(), 6, 1.50), - (2, 100.00, 20, 20, 0, 0, CURDATE(), 7, 1.00), - (94, 140875.00, 49.00, 115.00,25.00, 0, CURDATE(), 71, 0.00); + (1, 0.00, 10, 10, 0, 0, CURDATE(), 6, 1.50), + (2, 100.00, 20, 20, 0, 0, CURDATE(), 7, 1.00), + (3, 14000.00, 0, 0, 0, 0, CURDATE(), NULL, 0), + (4, 218000.00, 0, 0, 0, 0, CURDATE(), NULL, 0), + (5, 292000.00, 0, 0, 0, 0, CURDATE(), NULL, 0), + (94, 140875.00, 49.00, 115.00, 25.00, 0, CURDATE(), 71, 0.00); INSERT INTO `vn`.`ticketPackaging`(`id`, `ticketFk`, `packagingFk`, `quantity`, `created`, `pvp`) VALUES @@ -629,36 +632,36 @@ INSERT INTO `vn`.`ticketPackaging`(`id`, `ticketFk`, `packagingFk`, `quantity`, INSERT INTO `vn`.`sale`(`id`, `itemFk`, `ticketFk`, `concept`, `quantity`, `price`, `discount`, `reserved`, `isPicked`, `created`) VALUES - (1, 1, 1, 'Ranged weapon longbow 2m', 5, 9.10, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (2, 2, 1, 'Melee weapon combat fist 15cm', 10, 1.07, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (3, 1, 1, 'Ranged weapon longbow 2m', 2, 9.10, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (4, 4, 1, 'Melee weapon heavy shield 1x0.5m', 20, 3.06, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (5, 1, 2, 'Ranged weapon longbow 2m', 10, 9.10, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (6, 1, 3, 'Ranged weapon longbow 2m', 15, 6.50, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -2 MONTH)), - (7, 2, 11, 'Melee weapon combat fist 15cm', 15, 1.07, 0, 0, 0, CURDATE()), - (8, 4, 11, 'Melee weapon heavy shield 1x0.5m', 10, 3.06, 0, 0, 0, CURDATE()), - (9, 1, 16, 'Ranged weapon longbow 2m', 5, 9.10, 0, 0, 0, CURDATE()), - (10, 2, 16, 'Melee weapon combat fist 15cm', 10, 1.07, 0, 0, 0, CURDATE()), - (11, 1, 16, 'Ranged weapon longbow 2m', 2, 9.10, 0, 0, 0, CURDATE()), - (12, 4, 16, 'Melee weapon heavy shield 1x0.5m', 20, 3.06, 0, 0, 0, CURDATE()), - (13, 2, 8, 'Melee weapon combat fist 15cm', 15, 1.30, 0, 0, 0, CURDATE()), - (14, 1, 8, 'Ranged weapon longbow 2m', 10, 9.28, 0, 0, 0, CURDATE()), - (15, 1, 19, 'Ranged weapon longbow 2m', 10, 1.50, 0, 0, 0, CURDATE()), - (16, 2, 20, 'Melee weapon combat fist 15cm', 15, 1.30, 0, 0, 0, CURDATE()), - (17, 2, 22, 'Melee weapon combat fist 15cm', 30, 2.30, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL +1 MONTH)), - (18, 4, 22, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL +1 MONTH)), - (19, 1, 4, 'Ranged weapon longbow 2m', 1, 9.10, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -3 MONTH)), - (20, 1, 5, 'Ranged weapon longbow 2m', 1, 9.10, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -4 MONTH)), - (21, 1, 6, 'Ranged weapon longbow 2m', 1, 9.10, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (22, 1, 7, 'Ranged weapon longbow 2m', 1, 9.10, 0, 0, 0, CURDATE()), - (23, 1, 9, 'Ranged weapon longbow 2m', 1, 9.10, 0, 0, 0, CURDATE()), - (24, 1, 10, 'Ranged weapon longbow 2m', 1, 9.10, 0, 0, 0, CURDATE()), - (25, 4, 12, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, CURDATE()), - (26, 4, 13, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, CURDATE()), - (27, 4, 14, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, CURDATE()), - (28, 4, 15, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, CURDATE()), - (29, 4, 17, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, CURDATE()), - (30, 4, 18, 'Melee weapon heavy shield 1x0.5m', 20, 3.00, 0, 0, 0, CURDATE()); + (1, 1, 1, 'Ranged weapon longbow 2m', 5, 100.39, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (2, 2, 1, 'Melee weapon combat fist 15cm', 10, 7.07, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (3, 1, 1, 'Ranged weapon longbow 2m', 2, 100.39, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (4, 4, 1, 'Melee weapon heavy shield 1x0.5m', 20, 1.69, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (5, 1, 2, 'Ranged weapon longbow 2m', 1, 110.33, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (6, 1, 3, 'Ranged weapon longbow 2m', 1, 110.33, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -2 MONTH)), + (7, 2, 11, 'Melee weapon combat fist 15cm', 15, 7.43, 0, 0, 0, CURDATE()), + (8, 4, 11, 'Melee weapon heavy shield 1x0.5m', 10, 1.79, 0, 0, 0, CURDATE()), + (9, 1, 16, 'Ranged weapon longbow 2m', 1, 103.49, 0, 0, 0, CURDATE()), + (10, 2, 16, 'Melee weapon combat fist 15cm', 10, 7.08, 0, 0, 0, CURDATE()), + (11, 1, 16, 'Ranged weapon longbow 2m', 1, 103.49, 0, 0, 0, CURDATE()), + (12, 4, 16, 'Melee weapon heavy shield 1x0.5m', 20, 1.71, 0, 0, 0, CURDATE()), + (13, 2, 8, 'Melee weapon combat fist 15cm', 10, 7.08, 0, 0, 0, CURDATE()), + (14, 1, 8, 'Ranged weapon longbow 2m', 2, 103.49, 0, 0, 0, CURDATE()), + (15, 1, 19, 'Ranged weapon longbow 2m', 1, 103.49, 0, 0, 0, CURDATE()), + (16, 2, 20, 'Melee weapon combat fist 15cm', 20, 7.07, 0, 0, 0, CURDATE()), + (17, 2, 22, 'Melee weapon combat fist 15cm', 30, 7.07, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL +1 MONTH)), + (18, 4, 22, 'Melee weapon heavy shield 1x0.5m', 20, 1.69, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL +1 MONTH)), + (19, 1, 4, 'Ranged weapon longbow 2m', 1, 8.07, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -3 MONTH)), + (20, 1, 5, 'Ranged weapon longbow 2m', 1, 8.07, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -4 MONTH)), + (21, 1, 6, 'Ranged weapon longbow 2m', 1, 8.07, 0, 0, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (22, 1, 7, 'Ranged weapon longbow 2m', 1, 8.07, 0, 0, 0, CURDATE()), + (23, 1, 9, 'Ranged weapon longbow 2m', 1, 8.07, 0, 0, 0, CURDATE()), + (24, 1, 10, 'Ranged weapon longbow 2m', 1, 8.07, 0, 0, 0, CURDATE()), + (25, 4, 12, 'Melee weapon heavy shield 1x0.5m', 20, 1.72, 0, 0, 0, CURDATE()), + (26, 4, 13, 'Melee weapon heavy shield 1x0.5m', 20, 1.72, 0, 0, 0, CURDATE()), + (27, 4, 14, 'Melee weapon heavy shield 1x0.5m', 20, 1.72, 0, 0, 0, CURDATE()), + (28, 4, 15, 'Melee weapon heavy shield 1x0.5m', 20, 1.72, 0, 0, 0, CURDATE()), + (29, 4, 17, 'Melee weapon heavy shield 1x0.5m', 20, 1.72, 0, 0, 0, CURDATE()), + (30, 4, 18, 'Melee weapon heavy shield 1x0.5m', 20, 1.72, 0, 0, 0, CURDATE()); INSERT INTO `vn`.`saleChecked`(`saleFk`, `isChecked`) VALUES @@ -667,163 +670,131 @@ INSERT INTO `vn`.`saleChecked`(`saleFk`, `isChecked`) INSERT INTO `vn`.`saleComponent`(`saleFk`, `componentFk`, `value`) VALUES - (1, 15, 0.58), - (1, 23, 6.5), - (1, 28, 20.72), - (1, 29, -18.72), - (1, 39, 0.02), - (2, 15, 0.058), - (2, 21, 0.002), - (2, 28, 5.6), - (2, 29, -4.6), - (2, 39, 0.01), - (3, 15, 0.58), - (3, 23, 6.5), - (3, 28, 20.72), - (3, 29, -18.72), - (3, 39, 0.02), - (4, 15, 0.051), - (4, 21, -0.001), - (4, 28, 20.72), - (4, 29, -19.72), - (4, 37, 2), - (4, 39, 0.01), - (5, 15, 0.58), - (5, 23, 6.5), - (5, 28, 20.72), - (5, 29, -18.72), - (5, 39, 0.02), - (6, 23, 6.5), + (1, 28, 50), + (1, 29, 49.4), + (1, 39, 0.994), + (2, 28, 5), + (2, 29, 2), + (2, 39, 0.07), + (3, 28, 50), + (3, 29, 49.4), + (3, 39, 0.994), + (4, 28, 1.25), + (4, 29, 0.42), + (4, 39, 0.017), + (5, 17, 9.94), + (5, 28, 50), + (5, 29, 49.4), + (5, 39, 0.994), + (6, 17, 9.94), + (6, 28, 50), + (6, 29, 49.4), + (6, 39, 0.994), (7, 15, 0.0114), - (7, 17, 0.05), - (7, 28, 5.6), - (7, 29, -4.6), - (7, 39, 0.01), - (7, 21, -0.001), - (8, 15, 0.0016), - (8, 17, 0.05), - (8, 28, 20.72), - (8, 29, -19.72), - (8, 37, 2), - (8, 39, 0.01), - (8, 21, -0.002), - (9, 15, 0.58), - (9, 23, 6.5), - (9, 28, 20.72), - (9, 29, -18.72), - (9, 39, 0.02), - (10, 15, 0.058), - (10, 21, 0.002), - (10, 28, 5.6), - (10, 29, -4.6), - (10, 39, 0.01), - (11, 15, 0.58), - (11, 23, 6.5), - (11, 28, 20.72), - (11, 29, -18.72), - (11, 39, 0.02), - (12, 15, 0.051), - (12, 22, -0.001), - (12, 28, 20.72), - (12, 29, -19.72), - (12, 37, 2), - (12, 39, 0.01), - (13, 15, 0.2899), - (13, 28, 5.6), - (13, 29, -4.6), - (13, 39, 0.01), - (14, 15, 0.58), - (14, 23, 6.5), - (14, 28, 20.72), - (14, 29, -18.72), - (14, 39, 0.02), - (15, 15, 0.58), - (15, 23, 6.5), - (15, 28, 20.72), - (15, 29, -18.72), - (15, 39, 0.02), - (16, 15, 0.058), - (16, 21, 0.002), - (16, 28, 5.6), - (16, 29, -4.6), - (16, 39, 0.01), - (17, 15, 0.058), - (17, 21, 0.002), - (17, 28, 5.6), - (17, 29, -4.6), - (17, 39, 0.01), - (18, 15, 0.051), - (18, 22, -0.001), - (18, 28, 20.72), - (18, 29, -19.72), - (18, 37, 2), - (18, 39, 0.01), - (19, 15, 0.58), - (19, 23, 6.5), - (19, 28, 20.72), - (19, 29, -18.72), + (7, 17, 0.35), + (7, 28, 5), + (7, 29, 2), + (7, 39, 0.07), + (8, 15, 0.0199), + (8, 17, 0.084), + (8, 28, 1.25), + (8, 29, 0.42), + (8, 39, 0.017), + (9, 15, 3.0949), + (9, 21, 0.001), + (9, 28, 50), + (9, 29, 49.4), + (9, 39, 0.994), + (10, 15, 0.0111), + (10, 21, -0.001), + (10, 28, 5), + (10, 29, 2), + (10, 39, 0.07), + (11, 15, 3.0949), + (11, 21, 0.001), + (11, 28, 50), + (11, 29, 49.4), + (11, 39, 0.994), + (12, 15, 0.0199), + (12, 21, 0.003), + (12, 28, 1.25), + (12, 29, 0.42), + (12, 39, 0.017), + (13, 15, 0.114), + (13, 28, 5), + (13, 29, 2), + (13, 39, 0.07), + (14, 15, 3.0949), + (14, 28, 50), + (14, 29, 49.4), + (14, 39, 0.994), + (15, 15, 3.0949), + (15, 28, 50), + (15, 29, 49.4), + (15, 39, 0.994), + (16, 28, 5), + (16, 29, 2), + (16, 39, 0.07), + (17, 28, 5), + (17, 29, 2), + (17, 39, 0.07), + (18, 28, 1.25), + (18, 29, 0.42), + (18, 39, 0.017), + (19, 17, 0.7), + (19, 22, 0.3), + (19, 28, 5), + (19, 29, 2), (19, 39, 0.02), - (20, 15, 0.58), - (20, 23, 6.5), - (20, 28, 20.72), - (20, 29, -18.72), + (20, 17, 0.7), + (20, 22, 0.3), + (20, 28, 5), + (20, 29, 2), (20, 39, 0.02), - (21, 15, 0.58), - (21, 23, 6.5), - (21, 28, 20.72), - (21, 29, -18.72), + (21, 17, 0.7), + (21, 22, 0.3), + (21, 28, 5), + (21, 29, 2), (21, 39, 0.02), - (22, 15, 0.58), - (22, 23, 6.5), - (22, 28, 20.72), - (22, 29, -18.72), + (22, 17, 0.7), + (22, 22, 0.3), + (22, 28, 5), + (22, 29, 2), (22, 39, 0.02), - (23, 15, 0.58), - (23, 23, 6.5), - (23, 28, 20.72), - (23, 29, -18.72), + (23, 17, 0.7), + (23, 22, 0.3), + (23, 28, 5), + (23, 29, 2), (23, 39, 0.02), - (24, 15, 0.58), - (24, 23, 6.5), - (24, 28, 20.72), - (24, 29, -18.72), + (24, 17, 0.7), + (24, 22, 0.3), + (24, 28, 5), + (24, 29, 2), (24, 39, 0.02), - (25, 15, 0.051), - (25, 22, -0.001), - (25, 28, 20.72), - (25, 29, -19.72), - (25, 37, 2), - (25, 39, 0.01), - (26, 15, 0.051), - (26, 22, -0.001), - (26, 28, 20.72), - (26, 29, -19.72), - (26, 37, 2), - (26, 39, 0.01), - (27, 15, 0.051), - (27, 22, -0.001), - (27, 28, 20.72), - (27, 29, -19.72), - (27, 37, 2), - (27, 39, 0.01), - (28, 15, 0.051), - (28, 22, -0.001), - (28, 28, 20.72), - (28, 29, -19.72), - (28, 37, 2), - (28, 39, 0.01), - (29, 15, 0.051), - (29, 22, -0.001), - (29, 28, 20.72), - (29, 29, -19.72), - (29, 37, 2), - (29, 39, 0.01), - (30, 15, 0.051), - (30, 22, -0.001), - (30, 28, 20.72), - (30, 29, -19.72), - (30, 37, 2), - (30, 39, 0.01); + (25, 17, 0.033), + (25, 28, 1.25), + (25, 29, 0.42), + (25, 39, 0.017), + (26, 17, 0.033), + (26, 28, 1.25), + (26, 29, 0.42), + (26, 39, 0.017), + (27, 17, 0.033), + (27, 28, 1.25), + (27, 29, 0.42), + (27, 39, 0.017), + (28, 17, 0.033), + (28, 28, 1.25), + (28, 29, 0.42), + (28, 39, 0.017), + (29, 17, 0.033), + (29, 28, 1.25), + (29, 29, 0.42), + (29, 39, 0.017), + (30, 17, 0.033), + (30, 28, 1.25), + (30, 29, 0.42), + (30, 39, 0.017); INSERT INTO `vn`.`saleTracking`(`saleFk`, `isChecked`, `created`, `originalQuantity`, `workerFk`, `actionFk`, `id`, `stateFk`) VALUES @@ -987,12 +958,12 @@ INSERT INTO `vn`.`recovery`(`id`, `clientFk`, `started`, `finished`, `amount`, ` (3, 102, CURDATE(), DATE_ADD(CURDATE(),INTERVAL 1 MONTH), 50, 7), (4, 103, CURDATE(), NULL, 50, 7); -INSERT INTO `bi`.`rotacion`(`Id_Article`, `warehouse_id`, `total`, `rotacion`, `cm3`, `almacenaje`, `manipulacion`, `auxiliar`, `mermas`) - VALUES - (1, 1, 0, 0.0000, 1500, 0.0015, 0.0250, 0.0085, 0.0000), - (1, 2, 0, 0.0000, 100, 0.0060, 0.0200, 0.0080, 0.0000), - (2, 1, 10, 3.5000, 0, 0.0000, 0.0000, 0.0080, 0.0000), - (3, 1, 50, 5.5000, 100, 0.0000, 0.0000, 0.0080, 0.0000); +-- INSERT INTO `bi`.`rotacion`(`Id_Article`, `warehouse_id`, `total`, `rotacion`, `cm3`, `almacenaje`, `manipulacion`, `auxiliar`, `mermas`) +-- VALUES +-- (1, 1, 0, 0.0000, 1500, 0.0015, 0.0250, 0.0085, 0.0000), +-- (1, 2, 0, 0.0000, 100, 0.0060, 0.0200, 0.0080, 0.0000), +-- (2, 1, 10, 3.5000, 0, 0.0000, 0.0000, 0.0080, 0.0000), +-- (3, 1, 50, 5.5000, 100, 0.0000, 0.0000, 0.0080, 0.0000); INSERT INTO `vn`.`annualAverageInvoiced`(`clientFk`, `invoiced`) VALUES @@ -1051,21 +1022,21 @@ INSERT INTO `bi`.`claims_ratio`(`id_Cliente`, `Consumo`, `Reclamaciones`, `Ratio INSERT INTO `vn`.`buy`(`id`,`entryFk`,`itemFk`,`buyingValue`,`quantity`,`packageFk`,`stickers`,`freightValue`,`packageValue`,`comissionValue`,`packing`,`grouping`,`groupingMode`,`location`,`price1`,`price2`,`price3`,`minPrice`,`producer`,`printedStickers`,`isChecked`,`isIgnored`, `created`) VALUES - (1, 1, 1, 2.5, 5000, 1, 1, 0.350, 0.050, 0.000, 10, 10, 1, NULL, 0.00, 1.30, 1.25, 1.00, NULL, 0, 1, 0, DATE_ADD(CURDATE(), INTERVAL -2 MONTH)), - (2, 2, 1, 20, 100, 1, 1, 0.700, 0.020, 0.000, 5, 5, 1, NULL, 0.00, 2.50, 2.00, 0.50, NULL, 0, 1, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), - (3, 3, 1, 20, 100, 1, 1, 0.700, 0.020, 0.000, 1, 1, 0, NULL, 0.00, 2.50, 2.00, 0.50, NULL, 0, 1, 0, CURDATE()), - (4, 2, 2, 5, 450, 1, 1, 0.500, 0.100, 0.000, 10, 10, 0, NULL, 0.00, 1.30, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (5, 3, 3, 10, 500, 1, 1, 1.000, 0.050, 0.000, 10, 10, 0, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (6, 4, 8, 20, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (7, 4, 9, 20, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (8, 4, 4, 20, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (9, 4, 4, 20, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (10, 5, 1, 2, 10, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (11, 5, 4, 3, 10, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (12, 6, 4, 2, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (13, 7, 1, 2, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (14, 7, 2, 5, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()), - (15, 7, 4, 1, 1000, 1, 1, 0.700, 0.020, 0.000, 10, 10, 1, NULL, 0.00, 2.50, 1.00, 0.00, NULL, 0, 1, 0, CURDATE()); + (1, 1, 1, 50, 5000, 4, 1, 0.000, 0.000, 0.000, 1, 1, 1, NULL, 0.00, 99.6, 99.4, 0.00, NULL, 0, 1, 0, DATE_ADD(CURDATE(), INTERVAL -2 MONTH)), + (2, 2, 1, 50, 100, 4, 1, 0.000, 0.000, 0.000, 1, 1, 1, NULL, 0.00, 99.6, 99.4, 0.00, NULL, 0, 1, 0, DATE_ADD(CURDATE(), INTERVAL -1 MONTH)), + (3, 3, 1, 50, 100, 4, 1, 0.000, 0.000, 0.000, 1, 1, 0, NULL, 0.00, 99.6, 99.4, 0.00, NULL, 0, 1, 0, CURDATE()), + (4, 2, 2, 5, 450, 1, 1, 0.000, 0.000, 0.000, 10, 10, 0, NULL, 0.00, 7.30, 7.00, 0.00, NULL, 0, 1, 0, CURDATE()), + (5, 3, 3, 55, 500, 5, 1, 0.000, 0.000, 0.000, 1, 1, 0, NULL, 0.00, 78.3, 75.6, 0.00, NULL, 0, 1, 0, CURDATE()), + (6, 4, 8, 50, 1000, 4, 1, 0.000, 0.000, 0.000, 1, 1, 1, NULL, 0.00, 99.6, 99.4, 0.00, NULL, 0, 1, 0, CURDATE()), + (7, 4, 9, 20, 1000, 1, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 30.50, 29.00, 0.00, NULL, 0, 1, 0, CURDATE()), + (8, 4, 4, 1.25, 1000, 3, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 1.75, 1.67, 0.00, NULL, 0, 1, 0, CURDATE()), + (9, 4, 4, 1.25, 1000, 3, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 1.75, 1.67, 0.00, NULL, 0, 1, 0, CURDATE()), + (10, 5, 1, 50, 10, 4, 1, 0.000, 0.000, 0.000, 1, 1, 1, NULL, 0.00, 99.6, 99.4, 0.00, NULL, 0, 1, 0, CURDATE()), + (11, 5, 4, 1.25, 10, 3, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 1.75, 1.67, 0.00, NULL, 0, 1, 0, CURDATE()), + (12, 6, 4, 1.25, 1000, 3, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 1.75, 1.67, 0.00, NULL, 0, 1, 0, CURDATE()), + (13, 7, 1, 50, 1000, 4, 1, 0.000, 0.000, 0.000, 1, 1, 1, NULL, 0.00, 99.6, 99.4, 0.00, NULL, 0, 1, 0, CURDATE()), + (14, 7, 2, 5, 1000, 1, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 7.30, 7.00, 0.00, NULL, 0, 1, 0, CURDATE()), + (15, 7, 4, 1.25, 1000, 3, 1, 0.000, 0.000, 0.000, 10, 10, 1, NULL, 0.00, 1.75, 1.67, 0.00, NULL, 0, 1, 0, CURDATE()); INSERT INTO `vn2008`.`tblContadores`(`id`,`FechaInventario`) VALUES @@ -1528,14 +1499,14 @@ INSERT INTO `vn`.`sharingCart`(`id`, `workerFk`, `started`, `ended`, `workerSubs INSERT INTO `vn`.`zone` (`id`, `name`, `hour`, `warehouseFk`, `agencyModeFk`, `travelingDays`, `price`, `bonus`) VALUES - (1, 'Zone pickup A', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 1, 0, '0', '0'), - (2, 'Zone pickup B', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 2, 1, 0, '0', '0'), - (3, 'Zone 247 A', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 7, 1, '2', '0'), - (4, 'Zone 247 B', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 2, 7, 1, '2', '0'), - (5, 'Zone expensive A', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 8, 1, '5', '-1'), - (6, 'Zone expensive B', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 2, 8, 1, '5', '-1'), - (7, 'Zone refund', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 10, 0, 0, 0), - (8, 'Zone others', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 23, 0, 0, 0); + (1, 'Zone pickup A', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 1, 0, 0, 0), + (2, 'Zone pickup B', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 2, 1, 0, 0, 0), + (3, 'Zone 247 A', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 7, 1, 2, 0), + (4, 'Zone 247 B', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 2, 7, 1, 2, 0), + (5, 'Zone expensive A', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 8, 1, 1000, 0), + (6, 'Zone expensive B', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 2, 8, 1, 1000, 0), + (7, 'Zone refund', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 10, 0, 0, 0), + (8, 'Zone others', CONCAT(CURRENT_DATE(), ' ', TIME('22:00')), 1, 23, 0, 0, 0); INSERT INTO `vn`.`zoneIncluded` (`zoneFk`, `geoFk`, `isIncluded`) VALUES diff --git a/e2e/paths/05-ticket-module/03_sale.spec.js b/e2e/paths/05-ticket-module/03_sale.spec.js index 0bf1baad7..7334d29e1 100644 --- a/e2e/paths/05-ticket-module/03_sale.spec.js +++ b/e2e/paths/05-ticket-module/03_sale.spec.js @@ -29,7 +29,7 @@ describe('Ticket List sale path', () => { const value = await nightmare .waitToGetProperty(selectors.ticketSales.firstSalePrice, 'innerText'); - expect(value).toContain('3.00'); + expect(value).toContain('1.72'); }); it('should confirm the first ticket sale contains the discount', async() => { @@ -43,7 +43,7 @@ describe('Ticket List sale path', () => { const value = await nightmare .waitToGetProperty(selectors.ticketSales.firstSaleImport, 'innerText'); - expect(value).toContain('60.00'); + expect(value).toContain('34.40'); }); it('should navigate to the catalog by pressing the new item button', async() => { diff --git a/e2e/paths/05-ticket-module/06_basic_data_steps.spec.js b/e2e/paths/05-ticket-module/06_basic_data_steps.spec.js index d5e1a461b..8096935ad 100644 --- a/e2e/paths/05-ticket-module/06_basic_data_steps.spec.js +++ b/e2e/paths/05-ticket-module/06_basic_data_steps.spec.js @@ -26,7 +26,7 @@ describe('Ticket Edit basic data path', () => { .wait(1900) .waitToGetProperty(selectors.ticketBasicData.stepTwoTotalPriceDif, 'innerText'); - expect(result).toContain('-€13.95'); + expect(result).toContain('-€184.25'); }); it(`should then click next to move on to step three`, async() => { diff --git a/e2e/paths/06-claim-module/03_detail.spec.js b/e2e/paths/06-claim-module/03_detail.spec.js index 551701c78..6ea7c225e 100644 --- a/e2e/paths/06-claim-module/03_detail.spec.js +++ b/e2e/paths/06-claim-module/03_detail.spec.js @@ -30,7 +30,7 @@ describe('Claim detail', () => { it('should edit de second item claimed quantity', async() => { const result = await nightmare .clearInput(selectors.claimDetail.secondItemQuantityInput) - .write(selectors.claimDetail.secondItemQuantityInput, 10) + .write(selectors.claimDetail.secondItemQuantityInput, 1) .write('body', '\u000d') // simulates enter .waitForLastSnackbar(); @@ -44,8 +44,8 @@ describe('Claim detail', () => { const totalClaimed = await nightmare .waitToGetProperty(selectors.claimDetail.totalClaimed, 'innerText'); - expect(claimedQuantity).toEqual('10'); - expect(totalClaimed).toContain('99.30'); + expect(claimedQuantity).toEqual('1'); + expect(totalClaimed).toContain('138.89'); }); it('should delete the second item from the claim', async() => { diff --git a/modules/client/back/methods/client/specs/getCard.spec.js b/modules/client/back/methods/client/specs/getCard.spec.js index 30d963150..e6028caee 100644 --- a/modules/client/back/methods/client/specs/getCard.spec.js +++ b/modules/client/back/methods/client/specs/getCard.spec.js @@ -7,6 +7,6 @@ describe('Client get', () => { expect(result.id).toEqual(101); expect(result.name).toEqual('Bruce Wayne'); - expect(result.debt).toEqual(-101.85); + expect(result.debt).toEqual(79.05); }); }); diff --git a/modules/client/back/methods/client/specs/getDebt.spec.js b/modules/client/back/methods/client/specs/getDebt.spec.js index 84c6d2907..49b7fb501 100644 --- a/modules/client/back/methods/client/specs/getDebt.spec.js +++ b/modules/client/back/methods/client/specs/getDebt.spec.js @@ -4,7 +4,7 @@ describe('client getDebt()', () => { it('should return the client debt', async() => { let result = await app.models.Client.getDebt(101); - expect(result.debt).toEqual(-101.85); + expect(result.debt).toEqual(79.05); }); }); diff --git a/modules/client/back/methods/client/specs/getMana.spec.js b/modules/client/back/methods/client/specs/getMana.spec.js index c8ee77a68..e6fb09c90 100644 --- a/modules/client/back/methods/client/specs/getMana.spec.js +++ b/modules/client/back/methods/client/specs/getMana.spec.js @@ -4,6 +4,6 @@ describe('client getMana()', () => { it('should call the getMana method', async() => { let result = await app.models.Client.getMana(105); - expect(result.mana).toEqual(40.20); + expect(result.mana).toEqual(0.34); }); }); diff --git a/modules/client/back/methods/client/specs/summary.spec.js b/modules/client/back/methods/client/specs/summary.spec.js index be33594e2..bbd0c994e 100644 --- a/modules/client/back/methods/client/specs/summary.spec.js +++ b/modules/client/back/methods/client/specs/summary.spec.js @@ -11,13 +11,13 @@ describe('client summary()', () => { it('should return a summary object containing mana', async() => { let result = await app.models.Client.summary(105); - expect(result.mana.mana).toEqual(40.20); + expect(result.mana.mana).toEqual(0.34); }); it('should return a summary object containing debt', async() => { let result = await app.models.Client.summary(101); - expect(result.debt.debt).toEqual(-101.85); + expect(result.debt.debt).toEqual(79.05); }); it('should return a summary object containing averageInvoiced', async() => { diff --git a/modules/order/back/methods/order/specs/getTotalVolume.spec.js b/modules/order/back/methods/order/specs/getTotalVolume.spec.js index 58916d8a5..04eb8f911 100644 --- a/modules/order/back/methods/order/specs/getTotalVolume.spec.js +++ b/modules/order/back/methods/order/specs/getTotalVolume.spec.js @@ -4,7 +4,7 @@ describe('order getTotalVolume()', () => { it('should return the total', async() => { let result = await app.models.Order.getTotalVolume(1); - expect(result.totalVolume).toEqual(0.066); - expect(result.totalBoxes).toEqual(0.5); + expect(result.totalVolume).toEqual(1.562); + expect(result.totalBoxes).toEqual(11.1); }); }); diff --git a/modules/order/back/methods/order/specs/getVolumes.spec.js b/modules/order/back/methods/order/specs/getVolumes.spec.js index 881d17e93..4113a8e07 100644 --- a/modules/order/back/methods/order/specs/getVolumes.spec.js +++ b/modules/order/back/methods/order/specs/getVolumes.spec.js @@ -4,6 +4,6 @@ describe('order getVolumes()', () => { it('should return the volumes of a given order id', async() => { let [result] = await app.models.Order.getVolumes(1); - expect(result.volume).toEqual(0.04); + expect(result.volume).toEqual(1.09); }); }); diff --git a/modules/route/back/methods/route/specs/filter.spec.js b/modules/route/back/methods/route/specs/filter.spec.js index 820ecf291..ba32c956c 100644 --- a/modules/route/back/methods/route/specs/filter.spec.js +++ b/modules/route/back/methods/route/specs/filter.spec.js @@ -51,7 +51,7 @@ describe('Route filter()', () => { let result = await app.models.Route.filter(ctx); - expect(result.length).toEqual(3); + expect(result.length).toEqual(1); }); it('should return the routes matching "description"', async() => { diff --git a/modules/route/back/methods/route/specs/updateVolume.spec.js b/modules/route/back/methods/route/specs/updateVolume.spec.js index eea3ed773..75ee3c139 100644 --- a/modules/route/back/methods/route/specs/updateVolume.spec.js +++ b/modules/route/back/methods/route/specs/updateVolume.spec.js @@ -10,7 +10,7 @@ describe('route updateVolume()', () => { afterAll(async done => { - await originalRoute.updateAttributes({m3: 0.3}); + await originalRoute.updateAttributes({m3: 2.7}); await ticketToRestore.updateAttributes({routeFk: 2}); await app.models.RouteLog.destroyById(logIdToDestroy); done(); @@ -19,7 +19,7 @@ describe('route updateVolume()', () => { it('should confirm the original volume of the route is the expected', async() => { originalRoute = await app.models.Route.findById(routeId); - expect(originalRoute.m3).toEqual(0.3); + expect(originalRoute.m3).toEqual(2.7); }); it('should confirm the route volume is updated when a ticket is added', async() => { @@ -37,7 +37,7 @@ describe('route updateVolume()', () => { it('should confirm the change is logged', async() => { let logs = await app.models.RouteLog.find({fields: ['id', 'newInstance']}); let m3Log = logs.filter(log => { - return log.newInstance.m3 === 0.4; + return log.newInstance.m3 === 3.1; }); logIdToDestroy = m3Log[0].id; diff --git a/modules/ticket/back/methods/sale/specs/priceDifference.spec.js b/modules/ticket/back/methods/sale/specs/priceDifference.spec.js index 4ac7341ef..4c0cb1566 100644 --- a/modules/ticket/back/methods/sale/specs/priceDifference.spec.js +++ b/modules/ticket/back/methods/sale/specs/priceDifference.spec.js @@ -13,8 +13,8 @@ describe('sale priceDifference()', () => { }; let result = await app.models.Sale.priceDifference(16, data); - expect(result.totalUnitPrice).toEqual(22.33); - expect(result.totalNewPrice).toEqual(22.33); + expect(result.totalUnitPrice).toEqual(215.77); + expect(result.totalNewPrice).toEqual(215.77); expect(result.totalDifference).toEqual(0); }); diff --git a/modules/ticket/back/methods/sale/specs/updatePrice.spec.js b/modules/ticket/back/methods/sale/specs/updatePrice.spec.js index 4e4d70efc..b0c8b8017 100644 --- a/modules/ticket/back/methods/sale/specs/updatePrice.spec.js +++ b/modules/ticket/back/methods/sale/specs/updatePrice.spec.js @@ -57,14 +57,14 @@ describe('sale updatePrice()', () => { }); it('should set price as a decimal number and check the sale has the mana component', async() => { - let price = 5.5; + let price = 5.3; await app.models.Sale.updatePrice(saleId, price); let saleUpdated = await app.models.Sale.findById(saleId); createdSaleComponent = await app.models.SaleComponent.findOne({where: {saleFk: saleId, componentFk: manaComponentId}}); - expect(saleUpdated.price).toEqual(5.5); - expect(createdSaleComponent.value).toEqual(4.43); + expect(saleUpdated.price).toEqual(price); + expect(createdSaleComponent.value).toEqual(-2.13); }); it('should check that the mana of salesPerson changed', async() => { diff --git a/modules/ticket/back/methods/ticket/specs/getSalespersonMana.spec.js b/modules/ticket/back/methods/ticket/specs/getSalespersonMana.spec.js index b337248e8..15ae1ade6 100644 --- a/modules/ticket/back/methods/ticket/specs/getSalespersonMana.spec.js +++ b/modules/ticket/back/methods/ticket/specs/getSalespersonMana.spec.js @@ -4,7 +4,7 @@ describe('ticket getSalesPersonMana()', () => { it('should get the mana of a salesperson of a given ticket', async() => { let mana = await app.models.Ticket.getSalesPersonMana(1); - expect(mana).toEqual(301); + expect(mana).toEqual(125); }); it('should return 0 if the given ticket does not exist', async() => { diff --git a/modules/ticket/back/methods/ticket/specs/getTaxes.spec.js b/modules/ticket/back/methods/ticket/specs/getTaxes.spec.js index 2d8488cd3..74f336bbd 100644 --- a/modules/ticket/back/methods/ticket/specs/getTaxes.spec.js +++ b/modules/ticket/back/methods/ticket/specs/getTaxes.spec.js @@ -4,6 +4,6 @@ describe('ticket getTaxes()', () => { it('should return the tax of a given ticket', async() => { let result = await app.models.Ticket.getTaxes(1); - expect(result[0].tax).toEqual(7.64); + expect(result[0].tax).toEqual(77.54); }); }); diff --git a/modules/ticket/back/methods/ticket/specs/getTotal.spec.js b/modules/ticket/back/methods/ticket/specs/getTotal.spec.js index 9b0246740..c3494bba9 100644 --- a/modules/ticket/back/methods/ticket/specs/getTotal.spec.js +++ b/modules/ticket/back/methods/ticket/specs/getTotal.spec.js @@ -4,7 +4,7 @@ describe('ticket getTotal()', () => { it('should return the total of a ticket', async() => { let result = await app.models.Ticket.getTotal(1); - expect(result).toEqual(158.09); + expect(result).toEqual(893.87); }); it(`should return zero if the ticket doesn't have lines`, async() => { diff --git a/modules/ticket/back/methods/ticket/specs/getTotalVolume.spec.js b/modules/ticket/back/methods/ticket/specs/getTotalVolume.spec.js index d1ba56e84..a99dd6578 100644 --- a/modules/ticket/back/methods/ticket/specs/getTotalVolume.spec.js +++ b/modules/ticket/back/methods/ticket/specs/getTotalVolume.spec.js @@ -4,7 +4,7 @@ describe('ticket getTotalVolume()', () => { it('should return the total volume of a ticket', async() => { let ticketFk = 1; - let expectedResult = 0.066; + let expectedResult = 1.562; let result = await app.models.Ticket.getTotalVolume(ticketFk); diff --git a/modules/ticket/back/methods/ticket/specs/getVAT.spec.js b/modules/ticket/back/methods/ticket/specs/getVAT.spec.js index 27f0b0f3c..8ba2a3285 100644 --- a/modules/ticket/back/methods/ticket/specs/getVAT.spec.js +++ b/modules/ticket/back/methods/ticket/specs/getVAT.spec.js @@ -4,7 +4,7 @@ describe('ticket getVAT()', () => { it('should return the ticket VAT', async() => { await app.models.Ticket.getVAT(1) .then(response => { - expect(response).toEqual(20.49); + expect(response).toEqual(84.64); }); }); }); diff --git a/modules/ticket/back/methods/ticket/specs/getVolume.spec.js b/modules/ticket/back/methods/ticket/specs/getVolume.spec.js index b512a978b..8acf673af 100644 --- a/modules/ticket/back/methods/ticket/specs/getVolume.spec.js +++ b/modules/ticket/back/methods/ticket/specs/getVolume.spec.js @@ -5,7 +5,7 @@ describe('ticket getVolume()', () => { let ticketFk = 1; await app.models.Ticket.getVolume(ticketFk) .then(response => { - expect(response[0].m3).toEqual(0.04); + expect(response[0].m3).toEqual(1.09); }); }); }); diff --git a/modules/ticket/back/methods/ticket/specs/subtotal.spec.js b/modules/ticket/back/methods/ticket/specs/subtotal.spec.js index d94c2910d..bd706b6b5 100644 --- a/modules/ticket/back/methods/ticket/specs/subtotal.spec.js +++ b/modules/ticket/back/methods/ticket/specs/subtotal.spec.js @@ -4,7 +4,7 @@ describe('ticket subtotal()', () => { it('should return the subtotal of a ticket', async() => { let result = await app.models.Ticket.subtotal(1); - expect(result).toEqual(137.60); + expect(result).toEqual(809.23); }); it(`should return 0 if the ticket doesn't have lines`, async() => { diff --git a/modules/ticket/back/methods/ticket/specs/summary.spec.js b/modules/ticket/back/methods/ticket/specs/summary.spec.js index 69309a2c8..c67db0520 100644 --- a/modules/ticket/back/methods/ticket/specs/summary.spec.js +++ b/modules/ticket/back/methods/ticket/specs/summary.spec.js @@ -17,13 +17,13 @@ describe('ticket summary()', () => { it('should return a summary object containing subtotal for 1 ticket', async() => { let result = await app.models.Ticket.summary(1); - expect(Math.round(result.subtotal * 100) / 100).toEqual(137.60); + expect(Math.round(result.subtotal * 100) / 100).toEqual(809.23); }); it('should return a summary object containing VAT for 1 ticket', async() => { let result = await app.models.Ticket.summary(1); - expect(Math.round(result.vat * 100) / 100).toEqual(20.49); + expect(Math.round(result.vat * 100) / 100).toEqual(84.64); }); it('should return a summary object containing total for 1 ticket', async() => { diff --git a/modules/worker/back/methods/worker-mana/specs/getCurrentWorkerMana.spec.js b/modules/worker/back/methods/worker-mana/specs/getCurrentWorkerMana.spec.js index dfb96190b..ca8eb1460 100644 --- a/modules/worker/back/methods/worker-mana/specs/getCurrentWorkerMana.spec.js +++ b/modules/worker/back/methods/worker-mana/specs/getCurrentWorkerMana.spec.js @@ -4,7 +4,7 @@ describe('workerMana getCurrentWorkerMana()', () => { it('should get the mana of the logged worker', async() => { let mana = await app.models.WorkerMana.getCurrentWorkerMana({req: {accessToken: {userId: 18}}}); - expect(mana).toEqual(301); + expect(mana).toEqual(125); }); it('should return 0 if the user doesnt uses mana', async() => {