Commit bc32ca35 authored by 智勇's avatar 智勇

区分环境

parent 45eec53f
......@@ -86,7 +86,11 @@ export default {
},
fetchK8sList() {
fetchKubernetesList().then(res => {
this.tableData = res.data.namespaces
this.tableData = res.data.namespaces.filter(item => {
if (item.description !== 'dev') {
return item
}
})
})
},
getCluster() {
......
......@@ -159,6 +159,10 @@ export default {
}
}
if (!this.dateRange) {
this.dateRange = []
}
if (this.dateRange.length === 0) {
this.dateRange[1] = new Date(new Date().getTime())
this.dateRange[0] = new Date(this.dateRange[1].getTime() - 3 * 24 * 60 * 60 * 1000)
......
......@@ -148,7 +148,8 @@ export default {
window.open(`http://192.168.4.96:8080/job/${row.buildJob}/${row.buildId}/console`, '_blank')
},
handleSonar(row) {
window.open(`http://sonar.quantgroups.com/project/activity?id=${row.projectName}&selected_date=${row.analysisDate}`, '_blank')
const from = new Date(new Date().getTime() - 7 * 24 * 60 * 60 * 1000)
window.open(`http://sonar.quantgroups.com/project/activity?id=${row.projectName}&selected_date=${row.analysisDate}&from=${from}`, '_blank')
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment