1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-25 08:09:43 +02:00

Replace showNotificaiton() calls

This commit is contained in:
sauls8t 2018-04-23 12:46:34 +01:00
parent 9235c183c5
commit 74e9699e1e
4 changed files with 9 additions and 15 deletions

View file

@ -145,13 +145,13 @@ export default Component.extend({
if (data.authProvider === constants.AuthProvider.Keycloak) {
this.get('onSync')().then((response) => {
if (response.isError) {
this.showNotification(response.message);
console.log(response.message); // eslint-disable-line no-console
data.authProvider = constants.AuthProvider.Documize;
this.get('onSave')(data).then(() => {
});
} else {
if (data.authProvider === this.get('appMeta.authProvider')) {
this.showNotification(response.message);
console.log(response.message); // eslint-disable-line no-console
} else {
this.get('onChange')(data);
}

View file

@ -177,7 +177,6 @@ export default Component.extend(SectionMixin, NotifierMixin, {
}, function (error) {
self.set('busy', false);
self.set('authenticated', false);
self.showNotification("Unable to fetch repositories");
console.log(error); // eslint-disable-line no-console
});
},
@ -202,7 +201,7 @@ export default Component.extend(SectionMixin, NotifierMixin, {
}, function (error) {
self.set('busy', false);
self.set('authenticated', false);
self.showNotification("Unable to fetch owners");
console.log("Unable to fetch owners"); // eslint-disable-line no-console
console.log(error); // eslint-disable-line no-console
});

View file

@ -51,11 +51,7 @@ export default Component.extend(SectionMixin, NotifierMixin, {
},
displayError(reason) {
if (netUtil.isAjaxAccessError(reason)) {
// this.showNotification(`Unable to authenticate`);
} else {
// this.showNotification(`Something went wrong, try again!`);
}
console.log(reason); // eslint-disable-line no-console
},
actions: {
@ -181,7 +177,7 @@ export default Component.extend(SectionMixin, NotifierMixin, {
}, function (reason) { // eslint-disable-line no-unused-vars
self.set('authenticated', false);
self.set('waiting', false);
// self.showNotification(`Something went wrong, try again!`);
console.log(reason); // eslint-disable-line no-console
});
}
}

View file

@ -84,7 +84,7 @@ export default Component.extend(SectionMixin, NotifierMixin, TooltipMixin, {
Trello.deauthorize();
});
}
}, function (error) {
}, function (error) {
console.log(error); // eslint-disable-line no-console
});
},
@ -138,7 +138,7 @@ export default Component.extend(SectionMixin, NotifierMixin, TooltipMixin, {
}, function (error) { //jshint ignore: line
self.set('busy', false);
self.set('authenticated', false);
self.showNotification("Unable to fetch board lists");
console.log("Unable to fetch board lists"); // eslint-disable-line no-console
console.log(error); // eslint-disable-line no-console
});
},
@ -199,14 +199,13 @@ export default Component.extend(SectionMixin, NotifierMixin, TooltipMixin, {
}, function (error) { //jshint ignore: line
self.set('busy', false);
self.set('authenticated', false);
self.showNotification("Unable to fetch boards");
console.log("Unable to fetch boards"); // eslint-disable-line no-console
console.log(error); // eslint-disable-line no-console
});
},
error: function (error) {
self.set('busy', false);
self.set('authenticated', false);
self.showNotification("Unable to authenticate");
console.log(error); // eslint-disable-line no-console
}
});
@ -247,4 +246,4 @@ export default Component.extend(SectionMixin, NotifierMixin, TooltipMixin, {
});
}
}
});
});