fix(style): 删除 console 打印

This commit is contained in:
ssongliu
2022-05-25 11:38:29 +08:00
parent 9b8938f575
commit ff9529644d
22 changed files with 9 additions and 60 deletions

View File

@@ -117,7 +117,6 @@ export class WebTTY {
break; break;
case msgSetReconnect: case msgSetReconnect:
const autoReconnect = JSON.parse(payload); const autoReconnect = JSON.parse(payload);
console.log("Enabling reconnect: " + autoReconnect + " seconds")
this.reconnect = autoReconnect; this.reconnect = autoReconnect;
break; break;
} }

View File

@@ -148,8 +148,6 @@ export default {
listNamespace(this.clusterName, true, this.searchConfig.keywords, this.paginationConfig.currentPage, this.paginationConfig.pageSize).then((res) => { listNamespace(this.clusterName, true, this.searchConfig.keywords, this.paginationConfig.currentPage, this.paginationConfig.pageSize).then((res) => {
this.data = res.items this.data = res.items
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}).catch(error => {
console.log(error)
}).finally(() => { }).finally(() => {
this.loading = false this.loading = false
}) })

View File

@@ -158,8 +158,7 @@ export default {
created () { created () {
this.cluster = this.$route.query.cluster this.cluster = this.$route.query.cluster
this.search() this.search()
listApis(this.cluster).then(res => { listApis(this.cluster).then(() => {
console.log(res)
}) })
} }
} }

View File

@@ -174,11 +174,7 @@ export default {
.then((res) => { .then((res) => {
this.data = res.items this.data = res.items
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}) }).finally(() => {
.catch((error) => {
console.log(error)
})
.finally(() => {
this.loading = false this.loading = false
}) })
}, },

View File

@@ -283,11 +283,7 @@ export default {
.then((res) => { .then((res) => {
this.data = res.items this.data = res.items
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}) }).finally(() => {
.catch((error) => {
console.log(error)
})
.finally(() => {
this.loading = false this.loading = false
}) })
}, },

View File

@@ -345,11 +345,7 @@ export default {
.then((res) => { .then((res) => {
this.data = res.items this.data = res.items
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}) }).finally(() => {
.catch((error) => {
console.log(error)
})
.finally(() => {
this.loading = false this.loading = false
}) })
}, },

View File

@@ -190,11 +190,7 @@ export default {
.then((res) => { .then((res) => {
this.data = res.items this.data = res.items
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}) }).finally(() => {
.catch((error) => {
console.log(error)
})
.finally(() => {
this.loading = false this.loading = false
}) })
}, },

View File

@@ -295,11 +295,7 @@ export default {
item.containers = container item.containers = container
} }
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}) }).finally(() => {
.catch(error => {
console.log(error.message)
})
.finally(() => {
this.loading = false this.loading = false
}) })
}, },

View File

@@ -101,10 +101,9 @@ export default {
}) })
this.loading = false this.loading = false
}) })
.catch((error) => { .catch(() => {
this.showText = true this.showText = true
this.loading = false this.loading = false
console.log(error.message)
}) })
}, },
sortBy(val) { sortBy(val) {

View File

@@ -341,11 +341,7 @@ export default {
.then((res) => { .then((res) => {
this.data = res.items this.data = res.items
this.paginationConfig.total = res.total this.paginationConfig.total = res.total
}) }).finally(() => {
.catch((error) => {
console.log(error)
})
.finally(() => {
this.loading = false this.loading = false
}) })
}, },

View File

@@ -44,8 +44,6 @@
}, },
methods: {}, methods: {},
created() { created() {
console.log(model.V1Pod.attributeTypeMap)
console.log(model.V1ObjectMeta.getAttributeTypeMap())
} }
} }
</script> </script>

View File

@@ -75,9 +75,6 @@ export default {
readFile (file) { readFile (file) {
const reader = new FileReader() const reader = new FileReader()
reader.readAsText(file) reader.readAsText(file)
reader.onerror = e => {
console.log("error" + e)
}
reader.onload = () => { reader.onload = () => {
const item = { const item = {
index: Math.random(), index: Math.random(),

View File

@@ -152,8 +152,8 @@ export default {
metadata.annotations["operation"] = this.checked ? "update" : "check" metadata.annotations["operation"] = this.checked ? "update" : "check"
}, },
changeRepo (repo) { changeRepo (repo) {
this.repo.images = []
if (repo === "") { if (repo === "") {
this.repo.images = []
this.repo.repo = {} this.repo.repo = {}
this.repo.name = "" this.repo.name = ""
return return

View File

@@ -68,9 +68,6 @@ export default {
readFile(file) { readFile(file) {
const reader = new FileReader() const reader = new FileReader()
reader.readAsText(file) reader.readAsText(file)
reader.onerror = (e) => {
console.log("error" + e)
}
reader.onload = () => { reader.onload = () => {
const item = { const item = {
index: Math.random(), index: Math.random(),

View File

@@ -107,9 +107,6 @@ export default {
readFile (file) { readFile (file) {
const reader = new FileReader() const reader = new FileReader()
reader.readAsText(file) reader.readAsText(file)
reader.onerror = e => {
console.log("error" + e)
}
reader.onload = () => { reader.onload = () => {
this.$refs.editor.codemirror.setValue(reader.result) this.$refs.editor.codemirror.setValue(reader.result)
} }

View File

@@ -40,7 +40,6 @@ instance.interceptors.request.use(
return config return config
}, },
error => { error => {
console.log(error) // for debug
return Promise.reject(error) return Promise.reject(error)
} }
) )
@@ -75,7 +74,6 @@ instance.interceptors.response.use(response => {
checkPermission(error.response) checkPermission(error.response)
msg = error.response.data.message || error.response.data msg = error.response.data.message || error.response.data
} else { } else {
console.log("error: " + error)
msg = error.message msg = error.message
} }
if (error.config.url.indexOf("metrics.k8s.io") < 0 ) { if (error.config.url.indexOf("metrics.k8s.io") < 0 ) {

View File

@@ -20,5 +20,4 @@ export function isJSON(str) {
return false; return false;
} }
} }
console.log('It is not a string!')
} }

View File

@@ -14,8 +14,6 @@ export function get(obj, path) {
wrap: false, wrap: false,
}); });
} catch (e) { } catch (e) {
console.log('JSON Path error', e, path, obj); // eslint-disable-line no-console
return '(JSON Path err)'; return '(JSON Path err)';
} }
} }

View File

@@ -125,9 +125,6 @@ export default {
readFile(file) { readFile(file) {
const reader = new FileReader() const reader = new FileReader()
reader.readAsText(file) reader.readAsText(file)
reader.onerror = (e) => {
console.log("error" + e)
}
reader.onload = () => { reader.onload = () => {
this.form.configContent = reader.result this.form.configContent = reader.result
} }

View File

@@ -244,7 +244,6 @@ export default {
} }
for (const rule of this.detailForm.rules) { for (const rule of this.detailForm.rules) {
for (let i = 0; i < rule.apiGroups.length; i++) { for (let i = 0; i < rule.apiGroups.length; i++) {
console.log(rule)
if (rule.apiGroups[i] === "") { if (rule.apiGroups[i] === "") {
rule.apiGroups[i] = "core" rule.apiGroups[i] = "core"
} }

View File

@@ -236,7 +236,6 @@ export default {
} }
for (const rule of this.detailForm.rules) { for (const rule of this.detailForm.rules) {
for (let i = 0; i < rule.apiGroups.length; i++) { for (let i = 0; i < rule.apiGroups.length; i++) {
console.log(rule)
if (rule.apiGroups[i] === "") { if (rule.apiGroups[i] === "") {
rule.apiGroups[i] = "core" rule.apiGroups[i] = "core"
} }

View File

@@ -16,7 +16,6 @@ instance.interceptors.request.use(
return config return config
}, },
error => { error => {
console.log(error) // for debug
return Promise.reject(error) return Promise.reject(error)
} }
) )