Merge pull request #912 from jumpserver/dev

v2.12.0 rc5
This commit is contained in:
Jiangjie.Bai
2021-07-15 17:05:11 +08:00
committed by GitHub
5 changed files with 16 additions and 25 deletions

View File

@@ -8,7 +8,7 @@
<script> <script>
import ListTable from '@/components/ListTable/index' import ListTable from '@/components/ListTable/index'
import { ActionsFormatter, DetailFormatter } from '@/components/TableFormatters' import { ActionsFormatter, DetailFormatter, DisplayFormatter } from '@/components/TableFormatters'
import ShowSecretInfo from './ShowSecretInfo' import ShowSecretInfo from './ShowSecretInfo'
import UpdateSecretInfo from './UpdateSecretInfo' import UpdateSecretInfo from './UpdateSecretInfo'
import { connectivityMeta } from './const' import { connectivityMeta } from './const'
@@ -53,7 +53,7 @@ export default {
url: this.url, url: this.url,
columns: [ columns: [
'hostname', 'ip', 'username', 'version', 'connectivity', 'hostname', 'ip', 'username', 'version', 'connectivity',
'date_created', 'date_updated', 'actions' 'systemuser', 'date_created', 'date_updated', 'actions'
], ],
columnsShow: { columnsShow: {
min: ['username', 'actions'], min: ['username', 'actions'],
@@ -80,6 +80,9 @@ export default {
username: { username: {
showOverflowTooltip: true showOverflowTooltip: true
}, },
systemuser: {
formatter: DisplayFormatter
},
version: { version: {
width: '70px' width: '70px'
}, },

View File

@@ -41,7 +41,6 @@ export default {
computed: { computed: {
iconClass() { iconClass() {
const key = this.formatterArgs.getIconKey({ row: this.row, cellValue: this.cellValue }) const key = this.formatterArgs.getIconKey({ row: this.row, cellValue: this.cellValue })
console.log('What key: ', key)
return this.formatterArgs.iconChoices[key] return this.formatterArgs.iconChoices[key]
}, },
tips() { tips() {

View File

@@ -13,10 +13,17 @@ export default {
return { return {
tableConfig: { tableConfig: {
url: '/api/v1/acls/login-asset-acls/', url: '/api/v1/acls/login-asset-acls/',
columns: ['name', 'user_username_group', 'hostname_group', 'ip_group', 'name_group', 'protocol_group', 'systemuser_username_group', 'reviewers', 'priority', 'is_active', 'comment', 'actions'], columns: [
'name', 'user_username_group', 'hostname_group', 'ip_group', 'name_group',
'protocol_group', 'systemuser_username_group', 'reviewers', 'priority',
'is_active', 'comment', 'actions'
],
columnsShow: { columnsShow: {
min: ['name', 'actions'], min: ['name', 'actions'],
default: ['name', 'user_username_group', 'hostname_group', 'ip_group', 'reviewers', 'priority', 'is_active', 'comment', 'actions'] default: [
'name', 'user_username_group', 'hostname_group', 'ip_group', 'reviewers',
'priority', 'is_active', 'comment', 'actions'
]
}, },
columnsMeta: { columnsMeta: {
user_username_group: { user_username_group: {

View File

@@ -91,24 +91,6 @@ export default {
}.bind(this) }.bind(this)
} }
} }
// {
// title: this.$t('assets.PushSystemUserNow'),
// attrs: {
// type: 'primary',
// label: this.$t('assets.Push')
// },
// callbacks: {
// click: function() {
// this.$axios.post(
// `api/v1/assets/system-users/${this.object.id}/tasks/`,
// { action: 'push' }
// ).then(res => {
// window.open(`/ops/celery/task/${res.task}/log/`, '', 'width=900,height=600')
// }
// )
// }.bind(this)
// }
// }
], ],
nodeRelationConfig: { nodeRelationConfig: {
icon: 'fa-info', icon: 'fa-info',

View File

@@ -48,8 +48,8 @@ export default {
name: routeName, name: routeName,
params: { id: id }, params: { id: id },
query: { query: {
protocol: vm.systemUser.protocol, type: vm.systemUser.type,
type: vm.systemUser.type protocol: vm.systemUser.protocol
} }
}) })
} }