Skip to content

Commit

Permalink
bugfix:上传generic文件失败,未显示具体错误原因 #2209
Browse files Browse the repository at this point in the history
  • Loading branch information
lannoy0523 committed May 31, 2024
1 parent 51f6d69 commit 8e18aae
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
:row-border="false"
:virtual-render="fileList.length > 3000"
size="small">
<bk-table-column :label="$t('fileName')" min-width="300" show-overflow-tooltip>
<bk-table-column :label="$t('fileName')" min-width="230" show-overflow-tooltip>
<template #default="{ row }">
<bk-popover placement="top">
{{row.file.name}}
Expand All @@ -45,12 +45,16 @@
</span>
<span>{{ row.progressPercent }}</span>
</span>
<span v-else class="repo-tag" :class="row.status"
v-bk-tooltips="{ disabled: row.status !== 'FAILED' || !row.errMsg, content: row.errMsg, placements: ['bottom'] }">
<span v-else class="repo-tag" :class="row.status">
{{ uploadStatus[row.status].label }}
</span>
</template>
</bk-table-column>
<bk-table-column :label="$t('errMsg')" width="140" show-overflow-tooltip>
<template #default="{ row }">
{{ row.errMsg }}
</template>
</bk-table-column>
<bk-table-column :label="$t('operation')" width="90">
<template #default="{ row }">
<bk-button v-if="row.status === 'INIT' || row.status === 'UPLOADING'"
Expand Down Expand Up @@ -217,7 +221,7 @@
}
})
}
e && this.$set(wait, 'errMsg', e.message || e)
e && this.$set(wait, 'errMsg', e.response.message || e)
this.$set(wait, 'status', 'FAILED')
}).finally(() => {
this.upLoadTaskQueue = this.upLoadTaskQueue.filter(task => task !== wait)
Expand Down Expand Up @@ -250,7 +254,7 @@
position: fixed;
right: 40px;
bottom: 60px;
width: 520px;
width: 600px;
z-index: 1999;
border-radius: 3px;
box-shadow: 0px 0px 20px 0px rgba(8, 30, 64, 0.2);
Expand Down
3 changes: 2 additions & 1 deletion src/frontend/locale/repository/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -872,5 +872,6 @@
"userSource":"User Source",
"bkci": "BKCI",
"rootDirectoryPermission": "Access Control:",
"rootDirectoryPermissionTip": "After Open, Member access path in the repo need auth."
"rootDirectoryPermissionTip": "After Open, Member access path in the repo need auth.",
"errMsg": "Error Message"
}
3 changes: 2 additions & 1 deletion src/frontend/locale/repository/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -873,5 +873,6 @@
"userSource":"用户来源",
"bkci": "蓝盾",
"rootDirectoryPermission": "访问控制:",
"rootDirectoryPermissionTip": "开启之后项目成员访问此仓库下路径需要授权"
"rootDirectoryPermissionTip": "开启之后项目成员访问此仓库下路径需要授权",
"errMsg": "错误信息"
}

0 comments on commit 8e18aae

Please sign in to comment.