perf: 修改 panel

This commit is contained in:
ibuler 2025-03-11 10:57:55 +08:00
parent 05e3128dbc
commit 7c1d1278f6
5 changed files with 19 additions and 8 deletions

View File

@ -259,14 +259,14 @@ export default {
connectivity: connectivityMeta,
actions: {
formatter: ActionsFormatter,
has: false,
has: this.showActions,
formatterArgs: {
hasUpdate: false, // can set function(row, value)
hasDelete: true, // can set function(row, value)
hasClone: false,
canDelete: () => vm.$hasPerm('accounts.delete_account'),
moreActionsTitle: this.$t('More'),
extraActions: this.showActions ? accountOtherActions(this) : []
extraActions: accountOtherActions(this)
}
},
...this.columnsMeta

View File

@ -2,7 +2,7 @@
<div class="item-info">
<el-row>
<el-col v-for="item of infos" :key="item.content" :span="12" class="panel-item">
<small class="item-label">{{ item.title }}:</small>
<small class="item-label">{{ item.title }}</small>
<h4 class="item-value">{{ item.content }}</h4>
</el-col>
</el-row>
@ -21,9 +21,6 @@ export default {
},
data() {
return {}
},
mounted() {
console.log('INfo: ', this.infos)
}
}
</script>

View File

@ -5,7 +5,7 @@
<el-avatar :src="imageUrl" shape="square" />
<div class="title-display">
<span class="name">{{ object.name }}</span>
<small class="comment">{{ object.provider.label }}</small>
<span class="comment">{{ object.provider.label }}</span>
</div>
</div>
<div
@ -177,9 +177,15 @@ div.info-panel {
flex-direction: column;
text-align: left;
.name {
font-size: 1.1em;
color: #555555;
}
.comment {
color: #62686c;
font-weight: 300;
font-size: 0.8em;
}
}

View File

@ -1,5 +1,5 @@
<template>
<AccountListTable ref="table" :show-extra-actions="false" v-bind="tableConfig" />
<AccountListTable ref="table" :show-actions="false" v-bind="tableConfig" />
</template>
<script>

View File

@ -24,6 +24,14 @@ export default {
columns: [
'service', 'service_id', 'asset', 'account', 'remote_addr', 'datetime'
],
columnsShow: {
min: [
'service', 'account', 'datetime'
],
default: [
'service', 'asset', 'account', 'remote_addr', 'datetime'
]
},
extraQuery: {
order: '-datetime'
},