6745-2404_testToMaster #1950
|
@ -6,4 +6,7 @@ ADD COLUMN `countryFk` mediumint(8) unsigned DEFAULT NULL,
|
||||||
ADD CONSTRAINT `fk_supplierAccount_country`
|
ADD CONSTRAINT `fk_supplierAccount_country`
|
||||||
FOREIGN KEY (`countryFk`) REFERENCES `country` (`id`) ON UPDATE CASCADE;
|
FOREIGN KEY (`countryFk`) REFERENCES `country` (`id`) ON UPDATE CASCADE;
|
||||||
|
|
||||||
|
ALTER TABLE `vn`.`supplierAccount`
|
||||||
|
ADD UNIQUE KEY `uk_supplier_country` (`supplierFk`, `countryFk`);
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -7,27 +7,26 @@ module.exports = {
|
||||||
name: 'letter-debtor-nd',
|
name: 'letter-debtor-nd',
|
||||||
async serverPrefetch() {
|
async serverPrefetch() {
|
||||||
this.debtor = await db.findOne(`
|
this.debtor = await db.findOne(`
|
||||||
SELECT sa.iban,
|
SELECT sa.id,
|
||||||
|
sa.iban,
|
||||||
be.name bankName,
|
be.name bankName,
|
||||||
sa.countryFk,
|
sa.countryFk,
|
||||||
c.countryFk
|
c.countryFk
|
||||||
FROM supplierAccount sa
|
FROM supplierAccount sa
|
||||||
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
||||||
LEFT JOIN company co ON co.supplierAccountFk = sa.id
|
LEFT JOIN company co ON co.supplierAccountFk = sa.id
|
||||||
LEFT JOIN client c ON c.countryFk = sa.countryFk
|
JOIN client c ON c.countryFk = sa.countryFk
|
||||||
WHERE c.id = ?
|
WHERE c.id = ?;
|
||||||
ORDER BY co.id DESC
|
|
||||||
LIMIT 1;
|
|
||||||
`, [this.id]);
|
`, [this.id]);
|
||||||
if (!this.debtor.length) {
|
if (!this.debtor) {
|
||||||
this.debtor = await db.findOne(`
|
this.debtor = await db.findOne(`
|
||||||
SELECT sa.iban,
|
SELECT sa.iban,
|
||||||
be.name bankName
|
be.name bankName
|
||||||
FROM supplierAccount sa
|
FROM supplierAccount sa
|
||||||
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
||||||
JOIN company co ON co.supplierAccountFk = sa.id
|
JOIN company co ON co.supplierAccountFk = sa.id
|
||||||
WHERE co.code = ?;
|
WHERE co.id = ?;
|
||||||
`, [this.companyCode]);
|
`, [this.companyId]);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
|
@ -6,12 +6,12 @@ sections:
|
||||||
description: We are writing to you once again to inform you that your debt with our company remains unpaid, as you can verify in the attached statement.
|
description: We are writing to you once again to inform you that your debt with our company remains unpaid, as you can verify in the attached statement.
|
||||||
terms: Since the agreed payment deadlines have significantly passed, there should be no further delay in settling the outstanding amount.
|
terms: Since the agreed payment deadlines have significantly passed, there should be no further delay in settling the outstanding amount.
|
||||||
payMethod:
|
payMethod:
|
||||||
description: To do so, you have the following payment options:
|
description: To do so, you have the following payment options
|
||||||
options:
|
options:
|
||||||
- Online payment through our website.
|
- Online payment through our website.
|
||||||
- Deposit or transfer to the account number provided at the bottom of this letter, indicating your customer number.
|
- Deposit or transfer to the account number provided at the bottom of this letter, indicating your customer number.
|
||||||
legalAction:
|
legalAction:
|
||||||
description: If this payment reminder is not heeded, we will be compelled to initiate the necessary legal actions, which may include:
|
description: If this payment reminder is not heeded, we will be compelled to initiate the necessary legal actions, which may include
|
||||||
options:
|
options:
|
||||||
- Inclusion in negative credit and financial solvency records.
|
- Inclusion in negative credit and financial solvency records.
|
||||||
- Legal proceedings.
|
- Legal proceedings.
|
||||||
|
|
|
@ -1,10 +1,9 @@
|
||||||
SELECT
|
SELECT c.dueDay,
|
||||||
c.dueDay,
|
|
||||||
c.iban,
|
|
||||||
sa.iban,
|
sa.iban,
|
||||||
be.name AS bankName
|
be.name bankName
|
||||||
FROM client c
|
FROM client c
|
||||||
JOIN company AS cny
|
JOIN supplierAccount sa ON sa.id = cny.supplierAccountFk
|
||||||
JOIN supplierAccount AS sa ON sa.id = cny.supplierAccountFk
|
|
||||||
JOIN bankEntity be ON be.id = sa.bankEntityFk
|
JOIN bankEntity be ON be.id = sa.bankEntityFk
|
||||||
WHERE c.id = ? AND cny.id = ?
|
JOIN company cny
|
||||||
|
WHERE c.id = ?
|
||||||
|
AND cny.id = ?
|
||||||
|
|
|
@ -7,27 +7,26 @@ module.exports = {
|
||||||
name: 'letter-debtor-st',
|
name: 'letter-debtor-st',
|
||||||
async serverPrefetch() {
|
async serverPrefetch() {
|
||||||
this.debtor = await db.findOne(`
|
this.debtor = await db.findOne(`
|
||||||
SELECT sa.iban,
|
SELECT sa.id,
|
||||||
|
sa.iban,
|
||||||
be.name bankName,
|
be.name bankName,
|
||||||
sa.countryFk,
|
sa.countryFk,
|
||||||
c.countryFk
|
c.countryFk
|
||||||
FROM supplierAccount sa
|
FROM supplierAccount sa
|
||||||
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
||||||
LEFT JOIN company co ON co.supplierAccountFk = sa.id
|
LEFT JOIN company co ON co.supplierAccountFk = sa.id
|
||||||
LEFT JOIN client c ON c.countryFk = sa.countryFk
|
JOIN client c ON c.countryFk = sa.countryFk
|
||||||
WHERE c.id = ?
|
WHERE c.id = ?;
|
||||||
ORDER BY co.id DESC
|
|
||||||
LIMIT 1;
|
|
||||||
`, [this.id]);
|
`, [this.id]);
|
||||||
if (!this.debtor.length) {
|
if (!this.debtor) {
|
||||||
this.debtor = await db.findOne(`
|
this.debtor = await db.findOne(`
|
||||||
SELECT sa.iban,
|
SELECT sa.iban,
|
||||||
be.name bankName
|
be.name bankName
|
||||||
FROM supplierAccount sa
|
FROM supplierAccount sa
|
||||||
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
JOIN bankEntity be ON sa.bankEntityFk = be.id
|
||||||
JOIN company co ON co.supplierAccountFk = sa.id
|
JOIN company co ON co.supplierAccountFk = sa.id
|
||||||
WHERE co.code = ?;
|
WHERE co.id = ?;
|
||||||
`, [this.companyCode]);
|
`, [this.companyId]);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
|
@ -17,8 +17,6 @@ supplier:
|
||||||
toCompleteBySupplier: A cumplimentar por el acreedor
|
toCompleteBySupplier: A cumplimentar por el acreedor
|
||||||
orderReference: Referencia de la orden de domiciliación
|
orderReference: Referencia de la orden de domiciliación
|
||||||
identifier: Identificador del acreedor
|
identifier: Identificador del acreedor
|
||||||
iban: ES89000B97367486
|
|
||||||
cif: B97367486-000
|
|
||||||
name: Nombre del acreedor
|
name: Nombre del acreedor
|
||||||
street: Dirección
|
street: Dirección
|
||||||
location: CP - Población - Provincia
|
location: CP - Población - Provincia
|
||||||
|
|
|
@ -13,8 +13,6 @@ sendOrder: APRÈS SIGNATURA, RENVOYER AU CRÉANCIER ET AU VOTRE ÉTABLISSEMENT F
|
||||||
supplier:
|
supplier:
|
||||||
toCompleteBySupplier: Á compléter pour le créancier
|
toCompleteBySupplier: Á compléter pour le créancier
|
||||||
orderReference: Numéro de référence du mandat
|
orderReference: Numéro de référence du mandat
|
||||||
iban: FR7630003012690002801121597
|
|
||||||
cif: B97367486-000
|
|
||||||
identifier: Identifiant créancier
|
identifier: Identifiant créancier
|
||||||
name: Nom du céancier
|
name: Nom du céancier
|
||||||
street: Adresse
|
street: Adresse
|
||||||
|
|
Loading…
Reference in New Issue