From 599f6b467eb417001edccf7df3b86cdd6cbfd718 Mon Sep 17 00:00:00 2001 From: Joan Sanchez Date: Wed, 1 May 2019 19:23:05 +0200 Subject: [PATCH 1/2] fixed ticketConfig sql script --- db/changes/10002-lent/00-ticketConfig.sql | 3 +-- db/changes/10003-easter/00-ACL.sql | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/db/changes/10002-lent/00-ticketConfig.sql b/db/changes/10002-lent/00-ticketConfig.sql index f4f7d6e94..8c93d084f 100644 --- a/db/changes/10002-lent/00-ticketConfig.sql +++ b/db/changes/10002-lent/00-ticketConfig.sql @@ -1,5 +1,4 @@ DROP TABLE IF EXISTS `vn`.`ticketConfig`; CREATE TABLE `vn`.`ticketConfig` (`id` INT NOT NULL AUTO_INCREMENT, `scopeDays` TINYINT(3) NULL, PRIMARY KEY (`id`)); - -INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('TicketConfig', '*', 'READ', 'ALLOW', 'ROLE', 'employee'); +INSERT INTO `vn`.`ticketConfig` (`id`, `scopeDays`) VALUES ('1', '6'); diff --git a/db/changes/10003-easter/00-ACL.sql b/db/changes/10003-easter/00-ACL.sql index 8dd09ff32..7485b5a0e 100644 --- a/db/changes/10003-easter/00-ACL.sql +++ b/db/changes/10003-easter/00-ACL.sql @@ -1,3 +1,4 @@ +INSERT INTO `salix`.`ACL` (`id`, `model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES (161, 'TicketConfig', '*', 'READ', 'ALLOW', 'ROLE', 'employee'); INSERT INTO `salix`.`ACL` (`id`, `model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES (162, 'InvoiceOut', 'delete', 'WRITE', 'ALLOW', 'ROLE', 'invoicing'); INSERT INTO `salix`.`ACL` (`id`, `model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES (163, 'InvoiceOut', 'book', 'WRITE', 'ALLOW', 'ROLE', 'invoicing'); INSERT INTO `salix`.`ACL` (`id`, `model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES (164, 'InvoiceOut', 'regenerate', 'WRITE', 'ALLOW', 'ROLE', 'invoicing'); From bad3200b2158bb2721ea1910f4522a098d2bab2b Mon Sep 17 00:00:00 2001 From: Joan Sanchez Date: Wed, 1 May 2019 19:34:08 +0200 Subject: [PATCH 2/2] renamed dmsTicket to ticketDms --- print/report/rpt-delivery-note/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/print/report/rpt-delivery-note/index.js b/print/report/rpt-delivery-note/index.js index 410b149c9..b282898a5 100755 --- a/print/report/rpt-delivery-note/index.js +++ b/print/report/rpt-delivery-note/index.js @@ -188,7 +188,7 @@ module.exports = { d.id, d.created FROM ticket t - JOIN dmsTicket dt ON dt.ticketFk = t.id + JOIN ticketDms dt ON dt.ticketFk = t.id JOIN dms d ON d.id = dt.dmsFk AND d.file LIKE '%.png' WHERE t.id = ?`, [ticketFk]);