mirror of
https://github.com/jumpserver/lina.git
synced 2025-11-08 19:02:40 +00:00
Compare commits
48 Commits
pr@dev@fix
...
v3.3
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5a8111d5aa | ||
|
|
bb84a9189c | ||
|
|
8c11dd9aa4 | ||
|
|
c13307b26b | ||
|
|
e74a611060 | ||
|
|
b09f54c356 | ||
|
|
320de2c3e4 | ||
|
|
09f734e6fc | ||
|
|
3117046342 | ||
|
|
b68aecb5cc | ||
|
|
1c9b155d97 | ||
|
|
75b1be9864 | ||
|
|
615c3c1cf4 | ||
|
|
4d82231af4 | ||
|
|
c6cf6571b6 | ||
|
|
8ea990d070 | ||
|
|
f4a32170d5 | ||
|
|
073508675e | ||
|
|
1d6ca0a93a | ||
|
|
36aea652d6 | ||
|
|
1a42ce90ab | ||
|
|
31a401b55d | ||
|
|
582a84178d | ||
|
|
9b9f7c936c | ||
|
|
2a6100957f | ||
|
|
16606d6a27 | ||
|
|
0a612f50e6 | ||
|
|
fe36fa9390 | ||
|
|
ba109900ec | ||
|
|
ec7768267f | ||
|
|
cc58b374ab | ||
|
|
04ffbb8fd6 | ||
|
|
49880f6739 | ||
|
|
e6f98d58c4 | ||
|
|
fd1f16d43c | ||
|
|
968b2415b1 | ||
|
|
776090d6ba | ||
|
|
3a37952288 | ||
|
|
62b8fc0e3b | ||
|
|
b2028869cb | ||
|
|
5277a725f8 | ||
|
|
f137788c1a | ||
|
|
f7d17c8de7 | ||
|
|
feea70b0be | ||
|
|
04696ef3d6 | ||
|
|
1731f4f788 | ||
|
|
6f25d93909 | ||
|
|
46461ec324 |
@@ -2,13 +2,13 @@
|
||||
<DataZTree ref="dataztree" :setting="treeSetting" class="data-z-tree" v-on="$listeners">
|
||||
<slot v-if="treeSetting.hasRightMenu" slot="rMenu">
|
||||
<li v-if="treeSetting.showCreate" id="m_create" class="rmenu" tabindex="-1" @click="createTreeNode">
|
||||
<i class="fa fa-plus-square-o" /> {{ this.$t('tree.CreateNode') }}
|
||||
<i class="fa fa-plus-square-o" /> {{ this.$t('tree.CreateNode') }}
|
||||
</li>
|
||||
<li v-if="treeSetting.showUpdate" id="m_edit" class="rmenu" tabindex="-1" @click="editTreeNode">
|
||||
<i class="fa fa-pencil-square-o" /> {{ this.$t('tree.RenameNode') }}
|
||||
<i class="fa fa-pencil-square-o" /> {{ this.$t('tree.RenameNode') }}
|
||||
</li>
|
||||
<li v-if="treeSetting.showDelete" id="m_del" class="rmenu" tabindex="-1" @click="removeTreeNode">
|
||||
<i class="fa fa-minus-square" /> {{ this.$t('tree.DeleteNode') }}
|
||||
<i class="fa fa-minus-square" /> {{ this.$t('tree.DeleteNode') }}
|
||||
</li>
|
||||
<slot name="rMenu" />
|
||||
</slot>
|
||||
@@ -42,7 +42,9 @@ export default {
|
||||
customTreeHeaderName: this.$t('assets.AssetTree'),
|
||||
async: {
|
||||
enable: true,
|
||||
url: (process.env.VUE_APP_ENV === 'production') ? (`${this.setting.treeUrl}`) : (`${process.env.VUE_APP_BASE_API}${this.setting.treeUrl}`),
|
||||
url: (process.env.VUE_APP_ENV === 'production')
|
||||
? (`${this.setting.treeUrl}`)
|
||||
: (`${process.env.VUE_APP_BASE_API}${this.setting.treeUrl}`),
|
||||
autoParam: ['id=key', 'name=n', 'level=lv'],
|
||||
type: 'get',
|
||||
headers: {
|
||||
@@ -206,7 +208,9 @@ export default {
|
||||
this.showRMenu('root', event.clientX, event.clientY)
|
||||
} else if (treeNode && !treeNode.noR) {
|
||||
this.zTree.selectNode(treeNode)
|
||||
this.currentNodeId = treeNode.meta.data.id
|
||||
if (treeNode.meta?.data?.id) {
|
||||
this.currentNodeId = treeNode.meta.data.id
|
||||
}
|
||||
this.showRMenu('node', event.clientX, event.clientY)
|
||||
}
|
||||
},
|
||||
@@ -284,32 +288,32 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.rmenu {
|
||||
font-size: 12px;
|
||||
padding: 0 16px;
|
||||
position: relative;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
color: #606266;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
box-sizing: border-box;
|
||||
cursor: pointer;
|
||||
}
|
||||
.rmenu {
|
||||
font-size: 12px;
|
||||
padding: 0 16px;
|
||||
position: relative;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
color: #606266;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
box-sizing: border-box;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.rmenu > a:hover, .dropdown-menu > a:focus {
|
||||
color: #262626;
|
||||
text-decoration: none;
|
||||
background-color: #f5f5f5;
|
||||
}
|
||||
.rmenu > a:hover, .dropdown-menu > a:focus {
|
||||
color: #262626;
|
||||
text-decoration: none;
|
||||
background-color: #f5f5f5;
|
||||
}
|
||||
|
||||
.rmenu:hover {
|
||||
background-color: #f5f7fa;
|
||||
}
|
||||
.rmenu:hover {
|
||||
background-color: #f5f7fa;
|
||||
}
|
||||
|
||||
.data-z-tree >>> .fa {
|
||||
width: 10px;
|
||||
margin-right: 3px;
|
||||
}
|
||||
.data-z-tree >>> .fa {
|
||||
width: 10px;
|
||||
margin-right: 3px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -57,7 +57,7 @@ export default {
|
||||
if (!this.rawValue.phone) {
|
||||
return ''
|
||||
}
|
||||
return `${this.rawValue.code} ${this.rawValue.phone}`
|
||||
return `${this.rawValue.code}${this.rawValue.phone}`
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
width="70%"
|
||||
v-on="$listeners"
|
||||
>
|
||||
<el-alert v-if="disabled && platformDetail" type="success">
|
||||
<el-alert v-if="disabled && platformDetail" type="success" style="margin-bottom: 10px">
|
||||
{{ $t('assets.InheritPlatformConfig') }}
|
||||
<el-link :href="platformDetail" class="link-more" target="_blank">
|
||||
{{ $t('common.View') }}
|
||||
@@ -214,7 +214,6 @@ export default {
|
||||
|
||||
.link-more {
|
||||
font-size: 10px;
|
||||
margin-left: 10px;
|
||||
border-bottom: solid 1px;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
@@ -3,6 +3,9 @@
|
||||
"accounts": {
|
||||
"GenerateSuccessMsg": "Accounts generated successfully",
|
||||
"GenerateAccounts": "Regenerate accounts",
|
||||
"AccountTemplateUpdateSecretHelpText": "The account list displays accounts created through templates. When updating ciphertext, the ciphertext of the account created through the template will be updated.",
|
||||
"Accounts": "Accounts",
|
||||
"SelectAccount": "Select account",
|
||||
"UpdateSecret": "Update secret",
|
||||
"AccountPolicy": "Account policy",
|
||||
"BulkCreateStrategy": "When creating accounts that do not meet the requirements, such as key type non-compliance and unique key constraints, the above policies can be selected.",
|
||||
@@ -354,7 +357,7 @@
|
||||
"PasswordSelector": "Password Input Box Selector",
|
||||
"SubmitSelector": "Submit Button Selector",
|
||||
"PlatformProtocolConfig": "Platform protocol config",
|
||||
"InheritPlatformConfig": "The account list displays accounts created through templates. When updating ciphertext, the ciphertext of the account created through the template will be updated.",
|
||||
"InheritPlatformConfig": "Inherited from the platform configuration. If you need to change, please change the configuration in the platform.",
|
||||
"CollectHardwareInfo": "Enable collection of hardware information",
|
||||
"DomainEnabled": "Enable domain",
|
||||
"ProtocolsEnabled": "Enable protocol",
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
{
|
||||
"": "",
|
||||
"accounts": {
|
||||
"Accounts": "アカウント",
|
||||
"AccountTemplateUpdateSecretHelpText": "アカウントリストには、テンプレートで作成されたアカウントが表示されます。暗号文を更新すると、テンプレートで作成されたアカウントの暗号文が更新されます。",
|
||||
"SelectAccount": "アカウントを選択",
|
||||
"GenerateSuccessMsg": "アカウントの生成に成功しました",
|
||||
"GenerateAccounts": "アカウントを再生成する",
|
||||
"UpdateSecret": "機密の更新",
|
||||
@@ -347,7 +350,7 @@
|
||||
"PasswordSelector": "パスワード入力ボックスセレクタ",
|
||||
"SubmitSelector": "コミットボタンセレクタ",
|
||||
"PlatformProtocolConfig": "プラットフォームプロトコルの構成",
|
||||
"InheritPlatformConfig": "アカウントリストには、テンプレートで作成されたアカウントが表示されます。暗号文を更新すると、テンプレートで作成されたアカウントの暗号文が更新されます。",
|
||||
"InheritPlatformConfig": "プラットフォーム構成から継承します。変更する場合は、プラットフォームの構成を変更してください。",
|
||||
"CollectHardwareInfo": "ハードウェア情報の収集を有効にする",
|
||||
"DomainEnabled": "ドメインを有効化",
|
||||
"ProtocolsEnabled": "プロトコルの有効化",
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
{
|
||||
"": "",
|
||||
"accounts": {
|
||||
"Accounts": "账号",
|
||||
"SelectAccount": "选择账号",
|
||||
"AccountTemplateUpdateSecretHelpText": "账号列表展示通过模版创建的账号。更新密文时,会更新通过模版所创建账号的密文。",
|
||||
"GenerateSuccessMsg": "账号生成成功",
|
||||
"GenerateAccounts": "重新生成账号",
|
||||
"UpdateSecret": "更新密文",
|
||||
@@ -365,7 +368,7 @@
|
||||
"PasswordSelector": "密码输入框选择器",
|
||||
"SubmitSelector": "提交按钮选择器",
|
||||
"PlatformProtocolConfig": "平台协议配置",
|
||||
"InheritPlatformConfig": "账号列表展示通过模版创建的账号。更新密文时,会更新通过模版所创建账号的密文。",
|
||||
"InheritPlatformConfig": "继承自平台配置,如需更改,请更改平台中的配置。",
|
||||
"CollectHardwareInfo": "启用收集硬件信息",
|
||||
"DomainEnabled": "启用网域",
|
||||
"ProtocolsEnabled": "启用协议",
|
||||
|
||||
@@ -43,6 +43,7 @@ const mutations = {
|
||||
state.profile = profile
|
||||
state.username = profile.username
|
||||
state.perms = profile.perms
|
||||
state.isSuperAdmin = profile['is_superuser']
|
||||
state.consoleOrgs = profile['console_orgs']
|
||||
state.workbenchOrgs = profile['workbench_orgs']
|
||||
state.noRootWorkbenchOrgs = profile['workbench_orgs'].filter(item => {
|
||||
|
||||
@@ -14,7 +14,7 @@ import { DEFAULT_ORG_ID, SYSTEM_ORG_ID } from '@/utils/org'
|
||||
const service = axios.create({
|
||||
baseURL: process.env.VUE_APP_BASE_API, // url = base url + request url
|
||||
// withCredentials: true, // send cookies when cross-domain requests
|
||||
timeout: 60 * 1000 // request timeout
|
||||
timeout: 2 * 60 * 1000 // request timeout
|
||||
})
|
||||
|
||||
function beforeRequestAddToken(config) {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<el-row :gutter="20">
|
||||
<el-col :md="24" :sm="24">
|
||||
<el-alert type="success">
|
||||
{{ $t('assets.InheritPlatformConfig') }}
|
||||
{{ $t('accounts.AccountTemplateUpdateSecretHelpText') }}
|
||||
</el-alert>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
@@ -10,24 +10,7 @@ export default {
|
||||
components: { BaseAssetCreateUpdate },
|
||||
data() {
|
||||
return {
|
||||
url: '/api/v1/assets/clouds/',
|
||||
addFieldsMeta: {
|
||||
protocols: {
|
||||
hidden: (formValue) => {
|
||||
const address = formValue['address']
|
||||
if (!address) return
|
||||
let port = address.startsWith('https://') ? 443 : 80
|
||||
try {
|
||||
const url = new URL(address)
|
||||
if (url.port) { port = url.port }
|
||||
} catch (e) {
|
||||
// pass
|
||||
}
|
||||
const protocols = formValue['protocols']?.[0] || {}
|
||||
protocols.port = port
|
||||
}
|
||||
}
|
||||
}
|
||||
url: '/api/v1/assets/clouds/'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -61,14 +61,14 @@ export default {
|
||||
quickActions: [],
|
||||
url: `/api/v1/assets/platforms/${this.object.id}`,
|
||||
detailFields: [
|
||||
'name', 'charset', 'internal',
|
||||
'id', 'name', 'charset', 'internal',
|
||||
{
|
||||
key: this.$t('assets.Type'),
|
||||
value: `${this.object.category?.label}/${this.object.type?.label}`
|
||||
},
|
||||
'su_method',
|
||||
'comment'
|
||||
'su_method', 'comment'
|
||||
],
|
||||
|
||||
protocolChoices: null,
|
||||
constraints: {}
|
||||
}
|
||||
|
||||
@@ -93,7 +93,8 @@ export default {
|
||||
core: 'Core',
|
||||
celery: 'Celery',
|
||||
magnus: 'Magnus',
|
||||
tinker: 'Tinker'
|
||||
tinker: 'Tinker',
|
||||
video_worker: 'Video-Worker'
|
||||
}
|
||||
return nameMapper[this.componentMetric.type]
|
||||
}
|
||||
|
||||
@@ -181,7 +181,7 @@ export default {
|
||||
key: this.$t('users.Phone'),
|
||||
formatter: () => {
|
||||
const phoneObj = this.object.phone
|
||||
return <div>{phoneObj?.code} {phoneObj?.phone}</div>
|
||||
return <div>{phoneObj?.code}{phoneObj?.phone}</div>
|
||||
}
|
||||
},
|
||||
'wecom_id', 'dingtalk_id', 'feishu_id',
|
||||
|
||||
@@ -82,6 +82,12 @@ export default {
|
||||
return this.$store.getters.hasValidLicense && !this.currentOrgIsRoot
|
||||
}
|
||||
},
|
||||
phone: {
|
||||
formatter: (row) => {
|
||||
const phoneObj = row.phone
|
||||
return <div>{phoneObj?.code}{phoneObj?.phone}</div>
|
||||
}
|
||||
},
|
||||
login_blocked: {
|
||||
width: '90px',
|
||||
formatterArgs: {
|
||||
|
||||
Reference in New Issue
Block a user