From da83d3589b66c338b4b41492aa1d9b8d3e71414a Mon Sep 17 00:00:00 2001 From: Zhimin Ruan Date: Sat, 20 Aug 2022 20:10:49 +0800 Subject: [PATCH] chore: cleanup unnecessary console log --- frontend/mock/mock-server.js | 4 +--- frontend/public/link.html | 2 -- frontend/src/views/chart/view/ChartEdit.vue | 2 +- frontend/src/views/login/index.vue | 1 - frontend/src/views/system/SysParam/index.vue | 1 - frontend/src/websocket/index.js | 2 +- mobile/src/components/amap-wx/js/util.js | 1 - mobile/src/components/uni-list/uni-refresh.wxs | 4 ---- mobile/src/pages/tabBar/home/detail.nvue | 3 --- mobile/src/pages/tabBar/home/index.nvue | 1 - 10 files changed, 3 insertions(+), 18 deletions(-) diff --git a/frontend/mock/mock-server.js b/frontend/mock/mock-server.js index 4c4cb2af83..653be04f2b 100644 --- a/frontend/mock/mock-server.js +++ b/frontend/mock/mock-server.js @@ -58,10 +58,8 @@ module.exports = app => { const mockRoutes = registerRoutes(app) mockRoutesLength = mockRoutes.mockRoutesLength mockStartIndex = mockRoutes.mockStartIndex - - console.log(chalk.magentaBright(`\n > Mock Server hot reload success! changed ${path}`)) } catch (error) { - console.log(chalk.redBright(error)) + console.error(chalk.redBright(error)) } } }) diff --git a/frontend/public/link.html b/frontend/public/link.html index c25c7c22fd..d7bae4999a 100644 --- a/frontend/public/link.html +++ b/frontend/public/link.html @@ -41,9 +41,7 @@ url += '&user=' + encodeURIComponent(user) } if (attachParams) { - console.log('attachParams-bf:'+attachParams+';-af:'+encodeURIComponent(attachParams)) url += '&attachParams=' + encodeURIComponent(attachParams) - } window.location.href = url diff --git a/frontend/src/views/chart/view/ChartEdit.vue b/frontend/src/views/chart/view/ChartEdit.vue index c4bb774561..a91efd5319 100644 --- a/frontend/src/views/chart/view/ChartEdit.vue +++ b/frontend/src/views/chart/view/ChartEdit.vue @@ -1513,7 +1513,7 @@ export default { } this.fieldShow = true }).catch(err => { - console.log(err) + console.error(err) this.resetView() this.httpRequest.status = err.response.data.success this.httpRequest.msg = err.response.data.message diff --git a/frontend/src/views/login/index.vue b/frontend/src/views/login/index.vue index e53381778b..a26f84aa25 100644 --- a/frontend/src/views/login/index.vue +++ b/frontend/src/views/login/index.vue @@ -146,7 +146,6 @@ export default { } }) defaultLoginType().then(res => { - console.log('default login type is :' + res.data) if (res && res.success) { this.defaultType = res.data } diff --git a/frontend/src/views/system/SysParam/index.vue b/frontend/src/views/system/SysParam/index.vue index 149f0ad217..955a68f654 100644 --- a/frontend/src/views/system/SysParam/index.vue +++ b/frontend/src/views/system/SysParam/index.vue @@ -142,7 +142,6 @@ export default { }, methods: { handlerBtn(btn) { - console.log(1, btn); }, }, }; diff --git a/frontend/src/websocket/index.js b/frontend/src/websocket/index.js index 25c3254b28..b623bb0e6a 100644 --- a/frontend/src/websocket/index.js +++ b/frontend/src/websocket/index.js @@ -25,7 +25,7 @@ class DeWebsocket { try { _this.client && _this.client.send('heart detection') } catch (error) { - console.log('Disconnection reconnection...') + console.error('Disconnection reconnection...') _this.connection() } }, 5000) diff --git a/mobile/src/components/amap-wx/js/util.js b/mobile/src/components/amap-wx/js/util.js index 765f04a51f..cceeee0552 100644 --- a/mobile/src/components/amap-wx/js/util.js +++ b/mobile/src/components/amap-wx/js/util.js @@ -169,7 +169,6 @@ const util = { uni.removeStorage({ key: 'search:history', success: function(res) { - console.log('success'); } }); return [] diff --git a/mobile/src/components/uni-list/uni-refresh.wxs b/mobile/src/components/uni-list/uni-refresh.wxs index 818a6b721b..c6f544a7b0 100644 --- a/mobile/src/components/uni-list/uni-refresh.wxs +++ b/mobile/src/components/uni-list/uni-refresh.wxs @@ -9,7 +9,6 @@ var pullDown = { function ready(newValue, oldValue, ownerInstance, instance) { var state = instance.getState() state.canPullDown = newValue; - // console.log(newValue); } function touchStart(e, instance) { @@ -19,9 +18,6 @@ function touchStart(e, instance) { if (!state.canPullDown) { return } - - // console.log("touchStart"); - state.height = 0; state.touchStartY = e.touches[0].pageY || e.changedTouches[0].pageY; state.refreshInstance.setStyle({ diff --git a/mobile/src/pages/tabBar/home/detail.nvue b/mobile/src/pages/tabBar/home/detail.nvue index 1fa70cdcd6..3c27d40dfc 100644 --- a/mobile/src/pages/tabBar/home/detail.nvue +++ b/mobile/src/pages/tabBar/home/detail.nvue @@ -223,13 +223,10 @@ uni.navigateBack(1) }, upper: function(e) { - console.log(e) }, lower: function(e) { - console.log(e) }, scroll: function(e) { - console.log(e) this.old.scrollTop = e.detail.scrollTop }, goTop: function(e) { diff --git a/mobile/src/pages/tabBar/home/index.nvue b/mobile/src/pages/tabBar/home/index.nvue index 79af1ea0d0..a1cd90c05e 100644 --- a/mobile/src/pages/tabBar/home/index.nvue +++ b/mobile/src/pages/tabBar/home/index.nvue @@ -216,7 +216,6 @@ let isExist = this.cacheTab.indexOf(this.tabIndex); if (isExist < 0) { this.cacheTab.push(this.tabIndex); - //console.log("cache index:: " + this.tabIndex); } }