style: Adjust style

This commit is contained in:
zhaojisen
2024-12-02 16:06:02 +08:00
committed by ZhaoJiSen
parent 4b309d950c
commit bfde8bd28b
10 changed files with 81 additions and 41 deletions

View File

@@ -1,7 +1,7 @@
<template>
<el-drawer
ref="drawer"
size="35%"
size="61.8%"
direction="rtl"
custom-class="drawer"
:title="title"

View File

@@ -1,9 +1,9 @@
<template>
<el-row :gutter="20">
<el-col :md="15" :sm="24">
<el-col :md="15" :sm="24" class="auto-detail-card">
<AutoDetailCard :object="object" v-bind="detail" />
</el-col>
<el-col :md="9" :sm="24">
<el-col :md="9" :sm="24" class="quick-actions">
<QuickActions :actions="quickActions" type="primary" />
<ViewSecret
v-if="showViewSecretDialog"

View File

@@ -38,6 +38,7 @@ export default {
AccountVisible: false,
account: {},
config: {
url: '/api/v1/accounts/accounts',
activeMenu: 'Detail',
submenu: [
{

View File

@@ -1,7 +1,7 @@
<template>
<div>
<el-row :gutter="24">
<el-col :md="15" :sm="24">
<el-col :md="15" :sm="24" class="generic-list-table">
<AccountListTable
ref="ListTable"
:asset="object"
@@ -21,7 +21,7 @@
@onConfirm="onConfirm"
/>
</el-col>
<el-col :md="9" :sm="24">
<el-col :md="9" :sm="24" class="quick-actions">
<QuickActions :actions="quickActions" :title="title" type="primary" />
</el-col>
</el-row>

View File

@@ -1,12 +1,12 @@
<template>
<el-row :gutter="20">
<el-col :md="15" :sm="24">
<el-col :md="15" :sm="24" class="auto-detail-card">
<AutoDetailCard v-bind="basicInfoConfig" />
<AutoDetailCard v-if="isShowSpecInfo" v-bind="specInfoConfig" />
<AutoDetailCard v-bind="customInfoConfig" />
<AutoDetailCard v-bind="gatheredInfoConfig" />
</el-col>
<el-col :md="9" :sm="24">
<el-col :md="9" :sm="24" class="quick-actions">
<QuickActions :actions="quickActions" type="primary" />
<RelationCard
ref="NodeRelation"

View File

@@ -1,10 +1,10 @@
<template>
<div>
<el-row :gutter="20">
<el-col :md="15" :sm="24">
<el-col :md="15" :sm="24" class="list-table">
<ListTable ref="ListTable" :header-actions="headerActions" :table-config="tableConfig" />
</el-col>
<el-col :md="9" :sm="24">
<el-col :md="9" :sm="24" class="perm-user-group-card">
<PermUserGroupCard v-bind="UserGroupCardConfig" />
</el-col>
</el-row>

View File

@@ -34,6 +34,7 @@ export default {
return {
asset: {},
config: {
url: '/api/v1/assets/assets',
activeMenu: 'Detail',
submenu: [
{

View File

@@ -1,24 +1,73 @@
<template>
<div>
<AccountListTable ref="table" v-bind="tableConfig" :origin="'pam'" />
<Drawer v-if="showTableDetailDrawer" :title="drawerTitle" @close-drawer="showTableDetailDrawer = !showTableDetailDrawer">
<component :is="currentTemplate" />
</Drawer>
</div>
</template>
<script>
import Drawer from '@/components/Drawer/index.vue'
import AssetDetail from '@/views/assets/Asset/AssetDetail'
import AccountListTable from '@/components/Apps/AccountListTable/AccountList.vue'
import AssetAccountDetail from '@/views/accounts/Account/AccountDetail/index.vue'
export default {
name: 'AssetAccountList',
components: {
AccountListTable
Drawer,
AssetDetail,
AccountListTable,
AssetAccountDetail
},
data() {
return {
showTableDetailDrawer: false,
currentTemplate: null,
drawerTitle: '',
tableConfig: {
url: '/api/v1/accounts/accounts/',
hasLeftActions: true,
hasImport: true,
columnsMeta: {
name: {
formatter: (row) => {
return (
<span style={{ color: '#1c84c6', cursor: 'pointer' }} onClick={() => {
this.$route.params.id = row.id
this.currentTemplate = 'AssetAccountDetail'
this.showTableDetailDrawer = true
this.drawerTitle = this.$t('AssetAccountDetail')
}}>
{row.name}
</span>
)
}
},
asset: {
formatter: (row) => {
return (
this.$hasPerm('assets.view_asset') ? (
<span
style={{ color: '#1c84c6', cursor: 'pointer' }}
onClick={() => {
this.$route.params.id = row.asset.id
this.currentTemplate = 'AssetDetail'
this.showTableDetailDrawer = true
this.drawerTitle = this.$t('AssetDetail')
}}
>
{row.name}
</span>
) : (
<span>{row.asset ? row.asset.name : ''}</span>
)
)
}
},
connect: {
width: '80px',
formatter: (row) => {
@@ -90,4 +139,23 @@ export default {
padding-left: 20px;
}
::v-deep .page.tab-page {
.page-heading .el-row--flex {
flex-wrap: wrap;
.page-heading-left .el-button {
display: none;
}
}
//.page-content {
// height: 100% !important;
// overflow-x: unset;
//
// .tab-page-content {
// height: calc(100% - 120px);
// }
//}
}
</style>

View File

@@ -149,26 +149,4 @@ export default {
padding-bottom: unset;
}
}
::v-deep .el-row {
display: flex;
flex-direction: column;
height: 100%;
.auto-detail-card,
.quick-actions,
.generic-list-table,
.resource-activity {
width: 100% !important;
.ibox {
border: 1px solid #EBEEF5 !important;
}
}
.quick-actions {
margin-top: 30px;
}
}
</style>

View File

@@ -43,14 +43,6 @@ export default {
]
}
}
},
watch: {},
async mounted() {
},
methods: {}
}
}
</script>
<style lang="scss" scoped>
</style>