refactor: i18n

This commit is contained in:
shiziyuan9527 2020-08-10 17:58:05 +08:00
parent 1007479e20
commit 6e0f0bdd1a
6 changed files with 51 additions and 18 deletions

View File

@ -21,7 +21,7 @@
</el-menu-item>
<el-menu-item index="/setting/organizationworkspace" v-permission="['org_admin']">{{$t('commons.workspace')}}
</el-menu-item>
<el-menu-item index="/setting/serviceintegration" v-permission="['org_admin']">服务集成
<el-menu-item index="/setting/serviceintegration" v-permission="['org_admin']">{{$t('organization.service_integration')}}
</el-menu-item>
</el-submenu>

View File

@ -1,7 +1,7 @@
<template>
<el-card class="header-title">
<div>
<div>请选择要集成的缺陷管理平台</div>
<div>{{$t('organization.select_defect_platform')}}</div>
<el-radio-group v-model="platform" style="margin-top: 10px">
<el-radio v-for="(item, index) in platforms" :key="index" :label="item.value" size="small">
{{item.name}}
@ -10,30 +10,30 @@
</div>
<div style="width: 500px">
<div style="margin-top: 20px;margin-bottom: 10px">Basic Auth账号信息</div>
<div style="margin-top: 20px;margin-bottom: 10px">{{$t('organization.basic_auth_info')}}</div>
<el-form :model="form" ref="form" label-width="100px" size="small">
<el-form-item label="API 账号" prop="account">
<el-input v-model="form.account" placeholder="请输入账号"/>
<el-form-item :label="$t('organization.api_account')" prop="account">
<el-input v-model="form.account" :placeholder="$t('organization.input_api_account')"/>
</el-form-item>
<el-form-item label="API 口令" prop="password">
<el-input v-model="form.password" auto-complete="new-password" placeholder="请输入口令" show-password/>
<el-form-item :label="$t('organization.api_password')" prop="password">
<el-input v-model="form.password" auto-complete="new-password" :placeholder="$t('organization.input_api_password')" show-password/>
</el-form-item>
<el-form-item>
<el-button type="primary" size="small" @click="submit('form')" style="width: 400px">
保存
{{$t('commons.save')}}
</el-button>
</el-form-item>
</el-form>
</div>
<div class="defect-tip">
<div>使用指引</div>
<div>{{$t('organization.use_tip')}}</div>
<div>
1. Basic Auth 账号信息在"公司管理-安全与集成-开放平台"中查询
1. {{$t('organization.use_tip_one')}}
</div>
<div>
2. 保存 Basic Auth 账号信息后需要在 Metersphere 项目中手动关联 ID/key
<router-link to="/track/project/all" style="margin-left: 5px">马上关联项目</router-link>
2. {{$t('organization.use_tip_two')}}
<router-link to="/track/project/all" style="margin-left: 5px">{{$t('organization.link_the_project_now')}}</router-link>
</div>
</div>
</el-card>
@ -57,8 +57,8 @@
}
],
rules: {
account: {required: true, message: "请输入账号", trigger: ['change', 'blur']},
password: {required: true, message: "请输入密码", trigger: ['change', 'blur']}
account: {required: true, message: this.$t('organization.input_api_account'), trigger: ['change', 'blur']},
password: {required: true, message: this.$t('organization.input_api_password'), trigger: ['change', 'blur']}
},
}
},

View File

@ -1,7 +1,7 @@
<template>
<div>
<el-tabs class="system-setting" v-model="activeName">
<el-tab-pane label="缺陷管理平台" name="defect">
<el-tab-pane :label="$t('organization.defect_manage')" name="defect">
<defect-management/>
</el-tab-pane>
</el-tabs>

View File

@ -173,8 +173,18 @@ export default {
special_characters_are_not_supported: 'Incorrect format (special characters are not supported and cannot end with \'-\')',
none: 'None Organization',
select: 'Select Organization',
service_integration: 'Service integration',
defect_manage: 'Defect management platform',
select_defect_platform: 'Please select the defect management platform to be integrated:',
basic_auth_info: 'Basic Auth account information:',
api_account: 'API account',
api_password: 'API password',
input_api_account: 'please enter account',
input_api_password: 'Please enter password',
use_tip: 'Usage guidelines:',
use_tip_one: 'Basic Auth account information is queried in "Company Management-Security and Integration-Open Platform"',
use_tip_two: 'After saving the Basic Auth account information, you need to manually associate the ID/key in the Metersphere project',
link_the_project_now: 'Link the project now',
},
project: {
name: 'Project name',

View File

@ -174,6 +174,18 @@ export default {
none: '无组织',
select: '选择组织',
delete_warning: '删除该组织将同步删除该组织下所有相关工作空间和相关工作空间下的所有项目,以及项目中的所有用例、接口测试、性能测试等,确定要删除吗?',
service_integration: '服务集成',
defect_manage: '缺陷管理平台',
select_defect_platform: '请选择要集成的缺陷管理平台:',
basic_auth_info: 'Basic Auth 账号信息:',
api_account: 'API 账号',
api_password: 'API 口令',
input_api_account: '请输入账号',
input_api_password: '请输入口令',
use_tip: '使用指引:',
use_tip_one: 'Basic Auth 账号信息在"公司管理-安全与集成-开放平台"中查询',
use_tip_two: '保存 Basic Auth 账号信息后,需要在 Metersphere 项目中手动关联 ID/key',
link_the_project_now: '马上关联项目',
},
project: {
recent: '最近的项目',

View File

@ -172,7 +172,18 @@ export default {
none: '無組織',
select: '選擇組織',
delete_warning: '删除该组织将同步删除该组织下所有相关工作空间和相关工作空间下的所有项目,以及项目中的所有用例、接口测试、性能测试等,确定要删除吗?',
service_integration: '服務集成',
defect_manage: '缺陷管理平台',
select_defect_platform: '請選擇要集成的缺陷管理平台:',
basic_auth_info: 'Basic Auth 賬號信息:',
api_account: 'API 賬號',
api_password: 'API 口令',
input_api_account: '請輸入賬號',
input_api_password: '請輸入口令',
use_tip: '使用指引:',
use_tip_one: 'Basic Auth 賬號信息在"公司管理-安全與集成-開放平台"中查詢',
use_tip_two: '保存 Basic Auth 賬號信息後,需要在 Metersphere 項目中手動關聯 ID/key',
link_the_project_now: '馬上關聯項目',
},
project: {
recent: '最近的項目',