[Update] i18n添加改密计划en翻译

This commit is contained in:
Bai
2020-06-01 15:35:10 +08:00
parent f24181b22a
commit 6be1ba8e69
6 changed files with 131 additions and 134 deletions

View File

@@ -671,74 +671,70 @@
"grantedRemoteApps": "Granted remote apps",
"remoteAppPermissionRules": "Remote app permission rules"
},
"Profile": "",
"ProfileSetting": "",
"LoginPasswordSetting": "",
"SSHKeySetting": "",
"SetMFA": "",
"UpdateMFA": "",
"ResetPublicKeyAndDownload": "",
"IsActive": "",
"MfaLevel": "",
"DateJoined": "",
"DateLastLogin": "",
"DatePasswordLastUpdated": "",
"DateExpired": "",
"Comment": "",
"OldSSHKey": "",
"UpdateSSHKey": "",
"FingerPrint": "",
"Profile": "Profile",
"ProfileSetting": "Profile setting",
"LoginPasswordSetting": "Login password setting",
"SSHKeySetting": "SSH Key setting",
"SetMFA": "Set MFA",
"UpdateMFA": "Update MFA",
"ResetPublicKeyAndDownload": "Reset public key and download",
"IsActive": "Is active",
"MfaLevel": "MFA level",
"DateJoined": "Date joined",
"DateLastLogin": "Date last login",
"DatePasswordLastUpdated": "Date password last updated",
"DateExpired": "Date expired",
"Comment": "Comment",
"OldSSHKey": "Old SSH key",
"UpdateSSHKey": "Update SSH Key",
"FingerPrint": "Fingerprint",
"HelpText": {
"SSHKeyOfProfileSSHUpdatePage": ""
"SSHKeyOfProfileSSHUpdatePage": "Copy your public key here"
},
"ResetAndDownloadSSHKey": ""
"ResetAndDownloadSSHKey": "Reset and download SSH Key"
},
"xpack": {
"Admin": "Admin",
"AssetCount": "Asset count",
"Auditor": "Auditor",
"ChangeAuthPlan": {
"PasswordStrategy": "",
"PasswordStrategy": "Password strategy",
"HelpText": {
"UsernameOfCreateUpdatePage": "",
"CrontabOfCreateUpdatePage": "",
"IntervalOfCreateUpdatePage": ""
"UsernameOfCreateUpdatePage": "The username of the user on the target host; If already existed, modify user password; If it doesn't exist, add the user and set the password.",
"CrontabOfCreateUpdatePage": "For example: every Sunday at 03:05 execute <5 3 * * 0> <br/> Using the 5-bit Linux crontab expression <minute hour day month week> (<a href=\"https://tool.lu/crontab/\" target=\"_blank\"> Online tool </a>) <br/> If both regularly perform and cycle perform execution are set, use regularly perform first",
"IntervalOfCreateUpdatePage": "Unit: hour"
},
"RegularlyPerform": "",
"CyclePerform": "",
"PasswordLength": "",
"addAsset": "",
"addNode": "",
"Username": "",
"AssetAmount": "",
"NodeAmount": "",
"TimeDelta": "",
"DateStart": "",
"Asset": "",
"Success": "",
"Retry": "",
"TaskList": "",
"Result": "",
"Log": "",
"Detail": "",
"ManualExecutePlan": "",
"Execute": "",
"Name": "",
"DateJoined": "",
"DateUpdated": "",
"AssetAndNode": "",
"ExecutionList": "",
"Timer": "",
"ExecutionTimes": "",
"ChangeAuthPlan": "",
"ChangeAuthPlanCreate": "",
"ChangeAuthPlanUpdate": "",
"ExecutionDetail": ""
"RegularlyPerform": "Regularly perform",
"CyclePerform": "Cycle perform",
"PasswordLength": "Password length",
"AddAsset": "Add asset",
"addNode": "Add node",
"Username": "Username",
"AssetAmount": "Asset",
"NodeAmount": "Node",
"TimeDelta": "Time delta",
"DateStart": "Date start",
"Asset": "Asset",
"Success": "Success",
"Retry": "Retry",
"TaskList": "Task list",
"Result": "Result",
"Log": "Log",
"Detail": "Detail",
"ManualExecutePlan": "Manual execute plan",
"Execute": "Execute",
"Name": "Name",
"DateJoined": "Date joined",
"DateUpdated": "Date updated",
"AssetAndNode": "Asset and Node",
"ExecutionList": "Execution list",
"Timer": "Timer",
"ExecutionTimes": "Execution times",
"ChangeAuthPlan": "Change auth plan",
"ChangeAuthPlanCreate": "Create change auth plan",
"ChangeAuthPlanUpdate": "Update change auth plan",
"ExecutionDetail": "Execution detail"
},
"ChangeAuthPlanCreate": "",
"ChangeAuthPlanDetail": "",
"ChangeAuthPlanExecutionTask": "",
"ChangeAuthPlanUpdate": "",
"Corporation": "Corporation",
"Edition": "Edition",
"Expired": "Expired",
@@ -786,11 +782,9 @@
"SyncInstanceTaskUpdate": "Update sync instance task",
"CoveredAlwaysHelpTips": "The asset information is always covered"
},
"Basic": "",
"Asset": "",
"Other": "",
"Node": "",
"Asset": "Asset",
"Node": "Node",
"import": ""
},
"": ""
}
}

View File

@@ -15,11 +15,11 @@ export default {
return {
url: '/api/v1/xpack/change-auth-plan/plan/',
fields: [
[this.$t('xpack.Basic'), ['name']],
[this.$t('common.Basic'), ['name']],
[this.$t('xpack.Asset'), ['username', 'assets', 'nodes']],
[this.$t('xpack.ChangeAuthPlan.PasswordStrategy'), ['password_strategy', 'password', 'password_rules']],
[this.$t('xpack.Timer'), ['is_periodic', 'crontab', 'interval']],
[this.$t('xpack.Other'), ['comment']]
[this.$t('common.Other'), ['comment']]
],
initial: {
password_strategy: 'custom',

View File

@@ -51,7 +51,7 @@ export default {
},
assetRelationConfig: {
icon: 'fa-edit',
title: this.$t('xpack.ChangeAuthPlan.addAsset'),
title: this.$t('xpack.ChangeAuthPlan.AddAsset'),
performAdd: (items, vm) => {
const relationUrl = `/api/v1/xpack/change-auth-plan/plan/${this.object.id}/asset/add/`
const data = {
@@ -62,7 +62,7 @@ export default {
},
nodeRelationConfig: {
icon: 'fa-edit',
title: this.$t('xpack.ChangeAuthPlan.addNode'),
title: this.$t('xpack.ChangeAuthPlan.AddNode'),
objectsAjax: {
url: `/api/v1/assets/nodes/`,
processResults(data) {

View File

@@ -37,29 +37,30 @@ export default {
},
timedelta: {
label: this.$t('xpack.ChangeAuthPlan.TimeDelta'),
width: '90px',
formatter: function(row) {
return row.timedelta.toFixed(2) + 's'
}
}
},
actions: {
formatterArgs: {
hasDelete: false,
hasUpdate: false,
extraActions: [
{
name: 'retry',
type: 'info',
title: this.$t('xpack.ChangeAuthPlan.Retry'),
callback: function({ cellValue, tableData }) {
this.$axios.put(
`/api/v1/xpack/change-auth-plan/plan-execution-subtask/${cellValue}/`,
).then(res => {
window.open(`/core/ops/celery/task/${res.task}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
})
}.bind(this)
}
]
},
actions: {
formatterArgs: {
hasDelete: false,
hasUpdate: false,
extraActions: [
{
name: 'retry',
type: 'info',
title: this.$t('xpack.ChangeAuthPlan.Retry'),
callback: function({ cellValue, tableData }) {
this.$axios.put(
`/api/v1/xpack/change-auth-plan/plan-execution-subtask/${cellValue}/`,
).then(res => {
window.open(`/core/ops/celery/task/${res.task}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
})
}.bind(this)
}
]
}
}
}
},

View File

@@ -57,37 +57,37 @@ export default {
},
timedelta: {
label: this.$t('xpack.ChangeAuthPlan.TimeDelta'),
width: '80px',
width: '90px',
formatter: function(row) {
return row.timedelta.toFixed(2) + 's'
}
},
date_start: {
showOverflowTooltip: true
}
},
actions: {
formatterArgs: {
hasDelete: false,
hasUpdate: false,
extraActions: [
{
name: 'log',
type: 'primary',
title: this.$t('xpack.ChangeAuthPlan.Log'),
callback: function({ cellValue, tableData }) {
window.open(`/core/ops/celery/task/${cellValue}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
},
actions: {
formatterArgs: {
hasDelete: false,
hasUpdate: false,
extraActions: [
{
name: 'log',
type: 'primary',
title: this.$t('xpack.ChangeAuthPlan.Log'),
callback: function({ cellValue, tableData }) {
window.open(`/core/ops/celery/task/${cellValue}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
}
},
{
name: 'detail',
title: this.$t('xpack.ChangeAuthPlan.Detail'),
type: 'info',
callback: function({ cellValue, tableData }) {
return this.$router.push({ name: 'ChangeAuthPlanExecutionDetail', params: { id: cellValue }})
}
}
},
{
name: 'detail',
title: this.$t('xpack.ChangeAuthPlan.Detail'),
type: 'info',
callback: function({ cellValue, tableData }) {
return this.$router.push({ name: 'ChangeAuthPlanExecutionDetail', params: { id: cellValue }})
}
}
]
]
}
}
}
},

View File

@@ -21,12 +21,10 @@ export default {
],
columnsMeta: {
assets_amount: {
label: vm.$t('xpack.ChangeAuthPlan.AssetAmount'),
width: '80px'
label: vm.$t('xpack.ChangeAuthPlan.AssetAmount')
},
nodes_amount: {
label: vm.$t('xpack.ChangeAuthPlan.NodeAmount'),
width: '80px'
label: vm.$t('xpack.ChangeAuthPlan.NodeAmount')
},
password_strategy_display: {
label: vm.$t('xpack.ChangeAuthPlan.PasswordStrategy'),
@@ -40,26 +38,30 @@ export default {
},
run_times: {
label: vm.$t('xpack.ChangeAuthPlan.ExecutionTimes'),
width: '80px'
}
},
actions: {
formatterArgs: {
extraActions: [
{
title: vm.$t('xpack.ChangeAuthPlan.Execute'),
name: 'execute',
type: 'info',
callback: function(data) {
this.$axios.post(
`/api/v1/xpack/change-auth-plan/plan-execution/`,
{ plan: data.cellValue }
).then(res => {
window.open(`/core/ops/celery/task/${res.task}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
})
}.bind(this)
}
]
width: '87px'
},
comment: {
width: '90px'
},
actions: {
width: '164px',
formatterArgs: {
extraActions: [
{
title: vm.$t('xpack.ChangeAuthPlan.Execute'),
name: 'execute',
type: 'info',
callback: function(data) {
this.$axios.post(
`/api/v1/xpack/change-auth-plan/plan-execution/`,
{ plan: data.cellValue }
).then(res => {
window.open(`/core/ops/celery/task/${res.task}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
})
}.bind(this)
}
]
}
}
}
},