#7108 - exchange-rate #2295
|
@ -5,5 +5,4 @@ module.exports = Self => {
|
|||
require('../methods/collection/getTickets')(Self);
|
||||
require('../methods/collection/assign')(Self);
|
||||
require('../methods/collection/getSales')(Self);
|
||||
require('../methods/collection/exchangeRateUpdate')(Self);
|
||||
};
|
||||
|
|
|
@ -224,5 +224,6 @@
|
|||
"There are not picking tickets": "There are not picking tickets",
|
||||
"ticketCommercial": "The ticket {{ ticket }} for the salesperson {{ salesMan }} is in preparation. (automatically generated message)",
|
||||
"This password can only be changed by the user themselves": "This password can only be changed by the user themselves",
|
||||
"They're not your subordinate": "They're not your subordinate"
|
||||
"They're not your subordinate": "They're not your subordinate",
|
||||
"InvoiceIn is already booked": "InvoiceIn is already booked"
|
||||
}
|
|
@ -17,7 +17,7 @@ describe('exchangeRateUpdate functionality', function() {
|
|||
spyOn(models.ReferenceRate, 'findOne').and.returnValue(Promise.resolve(null));
|
||||
spyOn(models.ReferenceRate, 'create').and.returnValue(Promise.resolve());
|
||||
|
||||
await models.Collection.exchangeRateUpdate();
|
||||
await models.InvoiceIn.exchangeRateUpdate();
|
||||
|
||||
expect(models.ReferenceRate.create).toHaveBeenCalledTimes(2);
|
||||
});
|
||||
|
@ -28,7 +28,7 @@ describe('exchangeRateUpdate functionality', function() {
|
|||
|
||||
let thrownError = null;
|
||||
try {
|
||||
await models.Collection.exchangeRateUpdate();
|
||||
await models.InvoiceIn.exchangeRateUpdate();
|
||||
} catch (error) {
|
||||
thrownError = error;
|
||||
}
|
||||
|
@ -41,7 +41,7 @@ describe('exchangeRateUpdate functionality', function() {
|
|||
let error;
|
||||
|
||||
try {
|
||||
await models.Collection.exchangeRateUpdate();
|
||||
await models.InvoiceIn.exchangeRateUpdate();
|
||||
} catch (e) {
|
||||
error = e;
|
||||
}
|
|
@ -10,6 +10,7 @@ module.exports = Self => {
|
|||
require('../methods/invoice-in/invoiceInEmail')(Self);
|
||||
require('../methods/invoice-in/getSerial')(Self);
|
||||
require('../methods/invoice-in/corrective')(Self);
|
||||
require('../methods/invoice-in/exchangeRateUpdate')(Self);
|
||||
|
||||
Self.rewriteDbError(function(err) {
|
||||
if (err.code === 'ER_ROW_IS_REFERENCED_2' && err.sqlMessage.includes('vehicleInvoiceIn'))
|
||||
|
|
Loading…
Reference in New Issue