提交 b531108b 编写于 作者: Z zhaoke

* Fix sync from zentao notice error.

上级 6239fc36
......@@ -184,6 +184,7 @@ export default {
'extract_success': 'Extract comments to test steps and checkpoints successfully.',
'extract_none': 'Not found any test steps in script comments.',
'extract_fail': 'Extract comments to test steps and checkpoints failed.',
'sync_from_zentao_success': 'Success to sync {success} cases from Zentao',
'sync_success': 'Success to sync {success} cases to Zentao, ignore {ignore} cases.',
'sync_fail': 'Sync failed.',
'by_workspace': 'By WorkDir',
......
......@@ -191,6 +191,7 @@ export default {
'extract_success': '提取注释为测试步骤和验证点成功。',
'extract_none': '脚本中未发现测试步骤。',
'extract_fail': '提取注释为测试步骤和验证点失败。',
'sync_from_zentao_success': '成功从禅道同步{success}个用例。',
'sync_success': '成功同步{success}个用例到禅道,忽略{ignore}个。',
'sync_fail': '同步失败',
'by_workspace': '按目录',
......
......@@ -561,7 +561,9 @@ const checkoutCases = (workspaceId, node) => {
}
});
notification.success({
message: t('sync_success'),
message: t('sync_from_zentao_success', {
success: node.children.length,
}),
});
}
const checkoutFromModule = (workspaceId, node) => {
......@@ -573,7 +575,9 @@ const checkoutFromModule = (workspaceId, node) => {
store.dispatch('Script/syncFromZentao', data).then((resp => {
if (resp.code === 0) {
notification.success({
message: t('sync_success'),
message: t('sync_from_zentao_success', {
success: resp.data.length,
}),
});
} else {
notification.error({
......@@ -588,7 +592,9 @@ const checkout = (workspaceId, caseId, path, successNotice = true) => {
store.dispatch('Script/syncFromZentao', data).then((resp => {
if (resp.code === 0) {
successNotice && notification.success({
message: t('sync_success'),
message: t('sync_from_zentao_success', {
success: 1,
}),
});
} else {
notification.error({
......@@ -602,7 +608,7 @@ const syncFromZentaoSubmit = (model) => {
store.dispatch("Script/syncFromZentao", model).then((resp) => {
if (resp.code === 0) {
notification.success({
message: t("sync_success", {success: resp.data == undefined? 0 : resp.data.length, ignore:0}),
message: t("sync_from_zentao_success", {success: resp.data == undefined? 0 : resp.data.length, ignore:0}),
});
showSyncFromZentaoModal.value = false;
syncFromZentaoRef.value.clearFormData()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册