Skip to content

Commit

Permalink
Merge pull request #11387 from lockiechen/issue_11386
Browse files Browse the repository at this point in the history
bug: 新增错误类型枚举导致前端解析异常 #11386
  • Loading branch information
mingshewhe authored Jan 9, 2025
2 parents 38177f9 + 9dd58da commit cbd6302
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 290 deletions.
4 changes: 2 additions & 2 deletions src/frontend/devops-pipeline/src/components/ExecPipeline.vue
Original file line number Diff line number Diff line change
Expand Up @@ -358,8 +358,8 @@
errorList () {
return this.execDetail?.errorInfoList?.map((error, index) => ({
...error,
errorTypeAlias: this.$t(errorTypeMap[error.errorType].title),
errorTypeConf: errorTypeMap[error.errorType]
errorTypeAlias: this.$t(errorTypeMap[error.errorType]?.title ?? errorTypeMap[0]?.title),
errorTypeConf: errorTypeMap[error.errorType] ?? errorTypeMap[0]
}))
},
showErrorPopup () {
Expand Down
4 changes: 4 additions & 0 deletions src/frontend/devops-pipeline/src/utils/pipelineConst.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,10 @@ export const errorTypeMap = [
{
title: 'pluginError',
icon: 'error-plugin'
},
{
title: 'containerError',
icon: 'error-node'
}
]

Expand Down
1 change: 1 addition & 0 deletions src/frontend/locale/pipeline/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"systemError": "SYSTEM",
"thirdPartyError": "THIRD_PARTY",
"pluginError": "PLUGIN",
"containerError": "AGENT",
"createTime": "Create time",
"retry": "Retry",
"resume": "Continue",
Expand Down
1 change: 1 addition & 0 deletions src/frontend/locale/pipeline/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
"systemError": "系统运行错误",
"thirdPartyError": "第三方系统错误",
"pluginError": "插件执行错误",
"containerError": "构建机执行错误",
"create": "创建",
"createTime": "创建时间",
"add": "新建",
Expand Down
Loading

0 comments on commit cbd6302

Please sign in to comment.