refactor: 通知配置页面国际化

This commit is contained in:
Captain.B 2021-09-06 15:00:23 +08:00 committed by 刘瑞斌
parent ce04184774
commit dc457c754c
17 changed files with 70 additions and 46 deletions

View File

@ -11,9 +11,11 @@
<el-collapse-item name="2">
<template v-slot:title>
<span style="width: 200px">
测试跟踪任务通知
{{ $t('organization.message.track') }}
</span>
<span>
{{ $t('organization.message.notice_count') }}: <span class="primary-text">{{ trackNoticeSize }}</span>
</span>
<span>通知数: <span style="color: #783887;">{{ trackNoticeSize }}</span></span>
</template>
<track-home-notification @noticeSize="getNoticeSize" :receiver-options="reviewReceiverOptions"
:receive-type-options="receiveTypeOptions"/>
@ -31,9 +33,11 @@
<el-collapse-item name="3">
<template v-slot:title>
<span style="width: 200px">
接口测试任务通知
{{ $t('organization.message.api') }}
</span>
<span>
{{ $t('organization.message.notice_count') }}: <span class="primary-text">{{ apiNoticeSize }}</span>
</span>
<span>通知数: <span style="color: #783887;">{{ apiNoticeSize }}</span></span>
</template>
<api-home-notification @noticeSize="getNoticeSize" :receiver-options="reviewReceiverOptions"
:receive-type-options="receiveTypeOptions"/>
@ -47,9 +51,11 @@
<el-collapse-item name="4">
<template v-slot:title>
<span style="width: 200px">
性能测试任务通知
{{ $t('organization.message.performance') }}
</span>
<span>
{{ $t('organization.message.notice_count') }}: <span class="primary-text">{{ performanceNoticeSize }}</span>
</span>
<span>通知数: <span style="color: #783887;">{{ performanceNoticeSize }}</span></span>
</template>
<performance-test-notification @noticeSize="getNoticeSize" :receiver-options="reviewReceiverOptions"
:receive-type-options="receiveTypeOptions"/>
@ -59,7 +65,9 @@
<el-collapse-item name="1">
<template v-slot:title>
<span style="width: 200px">{{ $t('organization.message.jenkins_task_notification') }}</span>
<span>通知数: <span style="color: #783887;">{{ jenkinsNoticeSize }}</span></span>
<span>
{{ $t('organization.message.notice_count') }}: <span class="primary-text">{{ jenkinsNoticeSize }}</span>
</span>
</template>
<jenkins-notification @noticeSize="getNoticeSize" :jenkins-receiver-options="jenkinsReceiverOptions"
:receive-type-options="receiveTypeOptions"/>
@ -205,4 +213,8 @@ export default {
height: calc(100vh - 200px);
overflow: auto;
}
.primary-text {
color: #783887;
}
</style>

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>接口自动化</h5>
<el-col :span="24">
<h5>{{ $t('i18n.automation') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>接口定义</h5>
<el-col :span="24">
<h5>{{ $t('i18n.definition') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>首页</h5>
<el-col :span="24">
<h5>{{ $t('i18n.home') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>测试报告</h5>
<el-col :span="24">
<h5>{{ $t('i18n.report') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,7 +1,7 @@
<template>
<div>
<el-row>
<el-col :span="10">
<el-col :span="24">
<h3>{{ $t('organization.message.jenkins_task_notification') }}</h3>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>报告</h5>
<el-col :span="24">
<h5>{{ $t('i18n.report') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>测试</h5>
<el-col :span="24">
<h5>{{ $t('commons.performance') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,7 +1,7 @@
<template>
<div>
<el-row>
<el-col :span="10">
<el-col :span="24">
<h5>{{ $t('test_track.issue.issue') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>测试用例</h5>
<el-col :span="24">
<h5>{{$t('test_track.case.test_case')}}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,7 +1,7 @@
<template>
<div>
<el-row>
<el-col :span="10">
<el-col :span="24">
<h5>{{ $t('test_track.plan.test_plan') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">

View File

@ -1,7 +1,7 @@
<template>
<div>
<el-row>
<el-col :span="10">
<el-col :span="24">
<h5>{{ $t('test_track.review.test_review') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>首页</h5>
<el-col :span="24">
<h5>{{ $t('i18n.home') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -1,8 +1,8 @@
<template>
<div>
<el-row>
<el-col :span="10">
<h5>报告</h5>
<el-col :span="24">
<h5>{{ $t('i18n.report') }}</h5>
<el-button icon="el-icon-circle-plus-outline" plain size="mini" @click="handleAddTaskModel"
v-permission="['ORGANIZATION_MESSAGE:READ+EDIT']">
{{ $t('organization.message.create_new_notification') }}

View File

@ -393,7 +393,11 @@ export default {
'3. When selecting the receiver, it must be the person included in the group you created. The mobile phone number of the receiver is required and it is the mobile phone number used by the nailing enterprise',
message: 'Event, receiver and receiving method are required\n',
message_webhook: 'Webhook is required when the receiving mode is nail or enterprise robot or lark',
template: "Template"
template: "Template",
track: 'Track notification',
api: 'Api notification',
performance: 'Performance notification',
notice_count: 'Number',
},
integration: {
select_defect_platform: 'Please select the defect management platform to be integrated:',

View File

@ -396,7 +396,11 @@ export default {
' 3.选择接收人时必须是你所建的群里包含的人,接收人手机号为必填项且为钉钉企业所使用的手机号',
message: '事件,接收人,接收方式为必填项',
message_webhook: '接收方式为钉钉和企业机器人,飞书时webhook为必填项',
template: "模版"
template: "模版",
track: '测试跟踪任务通知',
api: '接口测试任务通知',
performance: '性能测试任务通知',
notice_count: '通知数',
},
integration: {
select_defect_platform: '请选择要集成的缺陷管理平台:',

View File

@ -395,7 +395,11 @@ export default {
' 3.選擇接收人時必須是你所建的群裏包含的人,接收人手機號為必填項且為釘釘企業所使用的手機號',
message: '事件,接收人,接收方式為必填項',
message_webhook: '接收方式為釘釘和企業機器人,飛書時webhook為必填項',
template: "模版"
template: "模版",
track: '測試跟踪任務通知',
api: '接口測試任務通知',
performance: '性能測試任務通知',
notice_count: '通知數',
},
integration: {
select_defect_platform: '請選擇要集成的缺陷管理平臺:',