Web: remove some debug logging, and convert one log into warning

This commit is contained in:
Sybren A. Stüvel 2022-05-17 14:52:27 +02:00
parent 530520b1c7
commit 42c81e9900
2 changed files with 8 additions and 13 deletions

View File

@ -24,7 +24,7 @@ export default {
},
mounted: function () {
if (!this.websocketURL) {
console.log("UpdateListener: no websocketURL given, cannot do anything");
console.warn("UpdateListener: no websocketURL given, cannot do anything");
return;
}
this.connectToWebsocket();

View File

@ -47,16 +47,11 @@ export default {
mounted() {
window.jobsView = this;
this.jobs.$subscribe((mutation, state) => {
console.log("Pinia mutation:", mutation)
console.log("Pinia state :", state)
// // import { MutationType } from 'pinia'
// mutation.type // 'direct' | 'patch object' | 'patch function'
// // same as cartStore.$id
// mutation.storeId // 'cart'
// // only available with mutation.type === 'patch object'
// mutation.payload // patch object passed to cartStore.$patch()
})
// Useful for debugging:
// this.jobs.$subscribe((mutation, state) => {
// console.log("Pinia mutation:", mutation)
// console.log("Pinia state :", state)
// })
this._fetchJob(this.jobID);
this._fetchTask(this.taskID);
@ -82,7 +77,7 @@ export default {
this.tasks.deselectAllTasks();
return;
}
console.log("selected task changed:", taskSummary);
const jobsAPI = new API.JobsApi(apiClient);
jobsAPI.fetchTask(taskSummary.id)
.then((task) => {
@ -95,7 +90,7 @@ export default {
// SocketIO data event handlers:
onSioJobUpdate(jobUpdate) {
console.log("job update", jobUpdate);
if (this.$refs.jobsTable) {
if (jobUpdate.previous_status)
this.$refs.jobsTable.processJobUpdate(jobUpdate);