This commit is contained in:
parent
ea71e980cc
commit
a665b6c060
|
@ -1,4 +1,4 @@
|
||||||
DROP PROCEDURE IF EXISTS vn.clientCreate;
|
DROP PROCEDURE IF EXISTS `vn`.`clientCreate`;
|
||||||
|
|
||||||
DELIMITER $$
|
DELIMITER $$
|
||||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`client_create`(
|
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`client_create`(
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
ALTER TABLE vn.clientConfig ADD defaultPayMethodFk tinyint(3) unsigned NULL;
|
ALTER TABLE `vn`.`clientConfig` ADD defaultPayMethodFk tinyint(3) unsigned NULL;
|
||||||
ALTER TABLE vn.clientConfig ADD defaultDueDay int unsigned NULL;
|
ALTER TABLE `vn`.`clientConfig` ADD defaultDueDay int unsigned NULL;
|
||||||
ALTER TABLE vn.clientConfig ADD defaultCredit decimal(10, 2) NULL;
|
ALTER TABLE `vn`.`clientConfig` ADD defaultCredit decimal(10, 2) NULL;
|
||||||
ALTER TABLE vn.clientConfig ADD defaultIsTaxDataChecked tinyint(1) NULL;
|
ALTER TABLE `vn`.`clientConfig` ADD defaultIsTaxDataChecked tinyint(1) NULL;
|
||||||
ALTER TABLE vn.clientConfig ADD defaultHasCoreVnl boolean NULL;
|
ALTER TABLE `vn`.`clientConfig` ADD defaultHasCoreVnl boolean NULL;
|
||||||
ALTER TABLE vn.clientConfig ADD defaultMandateTypeFk smallint(5) NULL;
|
ALTER TABLE `vn`.`clientConfig` ADD defaultMandateTypeFk smallint(5) NULL;
|
||||||
ALTER TABLE vn.clientConfig ADD CONSTRAINT clientNewConfigPayMethod_FK FOREIGN KEY (dafaultPayMethodFk) REFERENCES vn.payMethod(id);
|
ALTER TABLE `vn`.`clientConfig` ADD CONSTRAINT clientNewConfigPayMethod_FK FOREIGN KEY (defaultPayMethodFk) REFERENCES vn.payMethod(id);
|
||||||
ALTER TABLE vn.clientConfig ADD CONSTRAINT clientNewConfigMandateType_FK FOREIGN KEY (defaultMandateTypeFk) REFERENCES vn.mandateType(id);
|
ALTER TABLE `vn`.`clientConfig` ADD CONSTRAINT clientNewConfigMandateType_FK FOREIGN KEY (defaultMandateTypeFk) REFERENCES vn.mandateType(id);
|
||||||
|
|
||||||
UPDATE vn.clientConfig
|
UPDATE `vn`.`clientConfig`
|
||||||
SET defaultPayMethodFk = 4,
|
SET defaultPayMethodFk = 4,
|
||||||
defaultDueDay = 5,
|
defaultDueDay = 5,
|
||||||
defaultCredit = 300.0,
|
defaultCredit = 300.0,
|
||||||
|
|
|
@ -5,7 +5,7 @@ drop trigger `vn`.`department_afterUpdate`;
|
||||||
|
|
||||||
DELIMITER $$
|
DELIMITER $$
|
||||||
$$
|
$$
|
||||||
create definer = root@localhost trigger department_afterUpdate
|
create definer = root@localhost trigger `vn`.`department_afterUpdate`
|
||||||
after update
|
after update
|
||||||
on department
|
on department
|
||||||
for each row
|
for each row
|
||||||
|
|
|
@ -385,6 +385,12 @@ INSERT INTO `vn`.`clientManaCache`(`clientFk`, `mana`, `dated`)
|
||||||
(1103, 0, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH)),
|
(1103, 0, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH)),
|
||||||
(1104, -30, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH));
|
(1104, -30, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH));
|
||||||
|
|
||||||
|
INSERT INTO `vn`.`mandateType`(`id`, `name`)
|
||||||
|
VALUES
|
||||||
|
(1, 'B2B'),
|
||||||
|
(2, 'CORE'),
|
||||||
|
(3, 'LCR');
|
||||||
|
|
||||||
INSERT INTO `vn`.`clientConfig`(`id`, `riskTolerance`, `maxCreditRows`, `maxPriceIncreasingRatio`, `riskScope`, `defaultPayMethodFk`, `defaultDueDay`, `defaultCredit`, `defaultIsTaxDataChecked`, `defaultHasCoreVnl`, `defaultMandateTypeFk`)
|
INSERT INTO `vn`.`clientConfig`(`id`, `riskTolerance`, `maxCreditRows`, `maxPriceIncreasingRatio`, `riskScope`, `defaultPayMethodFk`, `defaultDueDay`, `defaultCredit`, `defaultIsTaxDataChecked`, `defaultHasCoreVnl`, `defaultMandateTypeFk`)
|
||||||
VALUES
|
VALUES
|
||||||
(1, 200, 10, 0.25, 2, 4, 5, 300.00, 1, 1, 2);
|
(1, 200, 10, 0.25, 2, 4, 5, 300.00, 1, 1, 2);
|
||||||
|
@ -828,12 +834,6 @@ INSERT INTO `vn`.`greuge`(`id`, `clientFk`, `description`, `amount`, `shipped`,
|
||||||
(11, 1101, 'some heritage charges', -15.99, DATE_ADD(util.VN_CURDATE(), INTERVAL 1 MONTH), util.VN_CURDATE(), 5, 1),
|
(11, 1101, 'some heritage charges', -15.99, DATE_ADD(util.VN_CURDATE(), INTERVAL 1 MONTH), util.VN_CURDATE(), 5, 1),
|
||||||
(12, 1101, 'some miscellaneous charges', 58.00, DATE_ADD(util.VN_CURDATE(), INTERVAL 1 MONTH), util.VN_CURDATE(), 6, 1);
|
(12, 1101, 'some miscellaneous charges', 58.00, DATE_ADD(util.VN_CURDATE(), INTERVAL 1 MONTH), util.VN_CURDATE(), 6, 1);
|
||||||
|
|
||||||
INSERT INTO `vn`.`mandateType`(`id`, `name`)
|
|
||||||
VALUES
|
|
||||||
(1, 'B2B'),
|
|
||||||
(2, 'CORE'),
|
|
||||||
(3, 'LCR');
|
|
||||||
|
|
||||||
INSERT INTO `vn`.`mandate`(`id`, `clientFk`, `companyFk`, `code`, `created`, `mandateTypeFk`)
|
INSERT INTO `vn`.`mandate`(`id`, `clientFk`, `companyFk`, `code`, `created`, `mandateTypeFk`)
|
||||||
VALUES
|
VALUES
|
||||||
(1, 1102, 442, '1-1', util.VN_CURDATE(), 2);
|
(1, 1102, 442, '1-1', util.VN_CURDATE(), 2);
|
||||||
|
|
Loading…
Reference in New Issue