mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Change in error handling.
This commit is contained in:
@@ -449,6 +449,7 @@
|
|||||||
}).catch(error => {
|
}).catch(error => {
|
||||||
// give user errors things back.
|
// give user errors things back.
|
||||||
// something something render errors.
|
// something something render errors.
|
||||||
|
|
||||||
console.error('Error in transaction submission.');
|
console.error('Error in transaction submission.');
|
||||||
console.error(error);
|
console.error(error);
|
||||||
this.parseErrors(error.response.data);
|
this.parseErrors(error.response.data);
|
||||||
@@ -651,10 +652,10 @@
|
|||||||
parseErrors: function (errors) {
|
parseErrors: function (errors) {
|
||||||
this.setDefaultErrors();
|
this.setDefaultErrors();
|
||||||
this.error_message = "";
|
this.error_message = "";
|
||||||
if (errors.message.length > 0) {
|
if (typeof errors.errors === 'undefined') {
|
||||||
this.error_message = this.$t('firefly.errors_submission');
|
this.error_message = errors.message;
|
||||||
} else {
|
} else {
|
||||||
this.error_message = '';
|
this.error_message = this.$t('firefly.errors_submission');
|
||||||
}
|
}
|
||||||
let transactionIndex;
|
let transactionIndex;
|
||||||
let fieldName;
|
let fieldName;
|
||||||
|
|||||||
Reference in New Issue
Block a user