Skip to content

Commit

Permalink
feat: 版本状态增加撤销人文案;操作列表部分情况样式异常问题--sgory=115998324
Browse files Browse the repository at this point in the history
  • Loading branch information
q15971095971 committed Sep 30, 2024
1 parent 06251ee commit 2e06aeb
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 15 deletions.
3 changes: 2 additions & 1 deletion bcs-services/bcs-bscp/ui/src/constants/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ export const GET_UNNAMED_VERSION_DATA = (): IConfigVersion => ({
export enum APPROVE_TYPE {
PendApproval, // 0 待审批
PendPublish, // 1 审批通过
Rejected, // 2 驳回/撤销
Rejected, // 2 驳回
Revoke, // 3 撤销
}

// 版本上线方式
Expand Down
1 change: 1 addition & 0 deletions bcs-services/bcs-bscp/ui/src/i18n/en-us.ts
Original file line number Diff line number Diff line change
Expand Up @@ -524,6 +524,7 @@ export default {
去审批: 'Go to approval',
审批: 'Approval',
审批人: 'Approver',
撤销人: 'Revoker',
再次提交: 'Submit again',
确认驳回该上线任务: 'Confirm rejection of this publish task',
'资源类型/操作行为/资源实例/状态/操作人/操作途径': 'Resource type/Operation behavior/Resource instance/Status/Operator/Operation method',
Expand Down
1 change: 1 addition & 0 deletions bcs-services/bcs-bscp/ui/src/i18n/zh-cn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,7 @@ export default {
去审批: '去审批',
审批: '审批',
审批人: '审批人',
撤销人: '撤销人',
再次提交: '再次提交',
确认驳回该上线任务: '确认驳回该上线任务',
确认上线该版本: '确认上线该版本',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
<style lang="scss" scoped>
.more-actions {
box-sizing: content-box;
position: relative;
top: 2px;
margin-left: -12px;
position: absolute;
right: 0;
top: -5px;
display: inline-block;
vertical-align: middle;
width: 32px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@
@click="retrySubmission(row)">
{{ t('再次提交') }}
</bk-button>
<template v-else>--</template>
<span v-else class="empty-action">--</span>
<!-- 待上线/去审批状态 才显示更多操作;目前仅创建者有撤销权限 -->
<MoreActions
v-if="
Expand All @@ -171,7 +171,7 @@
"
@handle-undo="handleConfirm(row, $event)" />
</div>
<template v-else>--</template>
<template v-else>--2</template>
</template>
</bk-table-column>
<template #empty>
Expand Down Expand Up @@ -591,15 +591,14 @@
transform: scale(1.1);
}
}
// .action-btns {
// display: flex;
// align-items: center;
// }
.action-btns {
position: relative;
}
.action-btn {
vertical-align: sub;
& + .more-actions {
margin-left: 8px;
}
// & + .more-actions {
// margin-left: 8px;
// }
}
.table-list-pagination {
padding: 12px;
Expand Down Expand Up @@ -644,4 +643,8 @@
word-break: break-all;
line-height: 21px;
}
.empty-action {
margin-right: 50px;
vertical-align: sub;
}
</style>
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<text-file
v-show="approveStatus > -1"
v-bk-tooltips="{
content: `${t('审批人')}${approverList}`,
content: `${approveStatus === 3 ? t('撤销人') : t('审批人')}${approverList}`,
placement: 'bottom',
}"
class="text-file" />
Expand Down Expand Up @@ -69,7 +69,7 @@
approveStatus.value = APPROVE_TYPE.Rejected;
return t('审批驳回');
case 'RevokedPublish':
approveStatus.value = APPROVE_TYPE.Rejected;
approveStatus.value = APPROVE_TYPE.Revoke;
return t('撤销上线');
case 'PendPublish':
approveStatus.value = APPROVE_TYPE.PendPublish;
Expand Down

0 comments on commit 2e06aeb

Please sign in to comment.