fix(测试跟踪): 新建用例保存不退出无提示
--bug=1022819 --user=宋昌昌 【测试跟踪】功能用例,新建用例不保存退出,没有提示信息 https://www.tapd.cn/55049933/s/1338803
This commit is contained in:
parent
7de31289ee
commit
3ccac98942
|
@ -243,6 +243,19 @@
|
|||
<!-- 底部操作按钮 -->
|
||||
<div class="edit-footer-container" v-if="editable">
|
||||
<template>
|
||||
<!-- 保存 -->
|
||||
<div
|
||||
class="save-btn-row"
|
||||
v-if="showAddBtn">
|
||||
<el-button
|
||||
v-prevent-re-click
|
||||
size="small"
|
||||
type="primary"
|
||||
:disabled="readOnly || loading"
|
||||
@click="handleCommand(1)">
|
||||
{{ $t("commons.save") }}
|
||||
</el-button>
|
||||
</div>
|
||||
<!-- 保存并新建 -->
|
||||
<div class="save-create-row">
|
||||
<el-button
|
||||
|
@ -265,19 +278,6 @@
|
|||
{{ $t("test_track.case.save_add_public") }}
|
||||
</el-button>
|
||||
</div>
|
||||
<!-- 保存 -->
|
||||
<div
|
||||
class="save-btn-row"
|
||||
v-if="showAddBtn">
|
||||
<el-button
|
||||
v-prevent-re-click
|
||||
size="small"
|
||||
type="primary"
|
||||
:disabled="readOnly || loading"
|
||||
@click="handleCommand(1)">
|
||||
{{ $t("commons.save") }}
|
||||
</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -824,7 +824,17 @@ export default {
|
|||
}
|
||||
},
|
||||
back() {
|
||||
if (this.editable) {
|
||||
this.$confirm(this.$t('case.back_tips'), this.$t('commons.prompt'), {
|
||||
confirmButtonText: this.$t('commons.confirm'),
|
||||
cancelButtonText: this.$t('commons.cancel'),
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.$router.push('/track/case/all');
|
||||
});
|
||||
} else {
|
||||
this.$router.push('/track/case/all');
|
||||
}
|
||||
},
|
||||
openNewTab() {
|
||||
if (this.editable || !this.form.id || this.isPublicShow) {
|
||||
|
@ -2126,7 +2136,7 @@ export default {
|
|||
font-size: 14px;
|
||||
line-height: 22px;
|
||||
text-align: center;
|
||||
justify-content: flex-end;
|
||||
justify-content: flex-start;
|
||||
// 底部按钮激活样式
|
||||
.opt-active-primary {
|
||||
background: #783887;
|
||||
|
@ -2146,13 +2156,7 @@ export default {
|
|||
}
|
||||
|
||||
.save-btn-row {
|
||||
margin: 0 24px 0 12px;
|
||||
el-button {
|
||||
}
|
||||
}
|
||||
|
||||
.save-add-pub-row {
|
||||
margin-left: px2rem(12);
|
||||
margin: 0 0 0 px2rem(24);
|
||||
el-button {
|
||||
}
|
||||
}
|
||||
|
@ -2162,6 +2166,12 @@ export default {
|
|||
el-button {
|
||||
}
|
||||
}
|
||||
|
||||
.save-add-pub-row {
|
||||
margin-left: px2rem(12);
|
||||
el-button {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -164,14 +164,14 @@
|
|||
<div class="side-content">
|
||||
<base-edit-item-component
|
||||
:editable="editable"
|
||||
:auto-save="!readOnly"
|
||||
:auto-save="editable"
|
||||
trigger="hover"
|
||||
:contentObject="{
|
||||
content: form.customNum,
|
||||
contentType: 'INPUT',
|
||||
}"
|
||||
:readonlyHoverEvent="!readOnly"
|
||||
:content-click-event="!readOnly"
|
||||
:readonlyHoverEvent="editable"
|
||||
:content-click-event="editable"
|
||||
:model="form"
|
||||
:rules="rules"
|
||||
>
|
||||
|
|
|
@ -131,7 +131,7 @@ const message = {
|
|||
please_enter_expected_results: "Please enter expected results",
|
||||
please_enter_comments: "Please enter comments",
|
||||
disassociate: "Disassociate",
|
||||
saveAndCreate: "Save and New",
|
||||
saveAndCreate: "Save and Add",
|
||||
last_version: "Last version",
|
||||
set_new: "Set new",
|
||||
version_comparison: "Version comparison",
|
||||
|
@ -145,7 +145,8 @@ const message = {
|
|||
version_id_cannot_be_empty: "Version id cannot be empty",
|
||||
enter_comments_and_click_send: "Enter comments and click Send",
|
||||
cancel_relate_case_tips_title: "Confirm cancel?",
|
||||
cancel_relate_case_tips_content: "Cancel it will affect the test plan statistics. Sure?"
|
||||
cancel_relate_case_tips_content: "Cancel it will affect the test plan statistics. Sure?",
|
||||
back_tips: "TestCase is not saved, Are you sure to quit?"
|
||||
},
|
||||
attachment: {
|
||||
preview: "Preview",
|
||||
|
|
|
@ -131,7 +131,7 @@ const message = {
|
|||
please_enter_expected_results: "请输入预期结果",
|
||||
please_enter_comments: "请输入备注",
|
||||
disassociate: "取消关联",
|
||||
saveAndCreate: "保存并新建",
|
||||
saveAndCreate: "保存并添加",
|
||||
last_version: "最新版本",
|
||||
set_new: "置新",
|
||||
version_comparison: "版本对比",
|
||||
|
@ -145,7 +145,8 @@ const message = {
|
|||
version_id_cannot_be_empty: "版本号不能为空",
|
||||
enter_comments_and_click_send: "输入评论,点击发送",
|
||||
cancel_relate_case_tips_title: "确定取消关联关系吗?",
|
||||
cancel_relate_case_tips_content: "取消关联会影响测试计划相关统计, 确定取消吗?"
|
||||
cancel_relate_case_tips_content: "取消关联会影响测试计划相关统计, 确定取消吗?",
|
||||
back_tips: "你填写的信息未保存, 确定退出吗?"
|
||||
},
|
||||
attachment: {
|
||||
preview: "预览",
|
||||
|
|
|
@ -131,7 +131,7 @@ const message = {
|
|||
please_enter_expected_results: "請輸入預期結果",
|
||||
please_enter_comments: "請輸入備注",
|
||||
disassociate: "取消關联",
|
||||
saveAndCreate: "保存並新建",
|
||||
saveAndCreate: "保存並添加",
|
||||
last_version: "最新版本",
|
||||
set_new: "置新",
|
||||
version_comparison: "版本對比",
|
||||
|
@ -145,7 +145,8 @@ const message = {
|
|||
version_id_cannot_be_empty: "版本號不能為空",
|
||||
enter_comments_and_click_send: "輸入評論,點擊發送",
|
||||
cancel_relate_case_tips_title: "確定取消關聯關係嗎?",
|
||||
cancel_relate_case_tips_content: "取消關聯會影響測試計劃相關統計, 確定取消嗎?"
|
||||
cancel_relate_case_tips_content: "取消關聯會影響測試計劃相關統計, 確定取消嗎?",
|
||||
back_tips: "你填寫的信息未保存, 確定退出嗎?"
|
||||
},
|
||||
attachment: {
|
||||
preview: "預覽",
|
||||
|
|
Loading…
Reference in New Issue