perf: 新增发布机的部署设置

This commit is contained in:
Eric
2023-02-02 15:30:42 +08:00
committed by Jiangjie.Bai
parent 059aa62ed8
commit 559fc8b837
3 changed files with 35 additions and 7 deletions

View File

@@ -15,12 +15,12 @@ export default {
config: {
url: '/api/v1/terminal/applet-hosts/',
addFields: [
[this.$t('common.Automations'), ['deploy_options'], 3]
[this.$t('common.Automations'), ['deploy_options'], 2]
],
addFieldsMeta: {
deploy_options: {
fields: [
'RDS_Licensing', 'RDS_LicenseServer', 'RDS_LicensingMode',
'CORE_HOST', 'RDS_Licensing', 'RDS_LicenseServer', 'RDS_LicensingMode',
'RDS_fSingleSessionPerUser', 'RDS_MaxDisconnectionTime',
'RDS_RemoteAppLogoffTimeLimit'
]

View File

@@ -45,8 +45,13 @@ export default {
formatter: DetailFormatter,
formatterArgs: {
getIcon: ({ row }) => row.applet?.icon,
getTitle: ({ row }) => row.applet.display_name
}
getTitle: ({ row }) => row.applet.display_name,
getRoute: ({ row }) => ({
name: 'AppletDetail',
params: { id: row.applet.id }
})
},
id: ({ row }) => row.applet.id
},
'applet.version': {
label: this.$t('common.Version')

View File

@@ -3,17 +3,21 @@
<el-col :md="16" :sm="24">
<ListTable :table-config="config" :header-actions="headerConfig" />
</el-col>
<el-col :md="8" :sm="24">
<QuickActions type="primary" :actions="quickActions" />
</el-col>
</el-row>
</template>
<script>
import { ListTable } from '@/components'
import { ListTable, QuickActions } from '@/components'
import { openTaskPage } from '@/utils/jms'
export default {
name: 'Developments',
components: {
ListTable
ListTable,
QuickActions
},
props: {
object: {
@@ -72,7 +76,26 @@ export default {
}
}
}
}
},
quickActions: [
{
title: this.$t('assets.InitialDeploy'),
attrs: {
type: 'primary',
label: this.$t('common.Deploy')
},
callbacks: {
click: function() {
this.$axios.post(
`/api/v1/terminal/applet-host-deployments/`,
{ host: this.object.id }
).then(res => {
openTaskPage(res['task'])
})
}.bind(this)
}
}
]
}
}
}