fix css issues, stripped table etc.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
This commit is contained in:
Rohit Yadav 2019-08-14 19:43:22 +05:30
parent f71ed85964
commit a0f347e978
2 changed files with 26 additions and 13 deletions

View File

@ -139,7 +139,6 @@
</div>
<div style="margin-top: 12px" v-else>
<a-table
size="small"
:rowKey="record => record.id"
:loading="loading"
:columns="columns"
@ -274,17 +273,18 @@ export default {
return 0
})
}
if (!this.columnKeys.includes('name')) {
this.columnKeys = ['name', ...this.columnKeys]
}
var counter = 0
for (const key of this.columnKeys) {
for (var key of this.columnKeys) {
if (typeof key === 'object') {
key = Object.keys(key)[0]
}
this.columns.push({
title: key,
dataIndex: key,
key: counter++,
scopedSlots: { customRender: key },
sorter: (a, b) => a[key].length - b[key].length
sorter: (a, b) => String(a[key]).length - String(b[key]).length
})
}
@ -447,17 +447,26 @@ export default {
case 'Ready':
case 'Up':
case 'BackedUp':
case 'Allocated':
case 'Implemented':
case 'Enabled':
case 'enabled':
case 'Active':
case 'Completed':
case 'Started':
status = 'success'
break
case 'Stopped':
case 'Error':
status = 'error'
break
case 'Migrating':
case 'Starting':
case 'Scheduled':
status = 'processing'
break
case 'Alert':
case 'Allocated':
case 'Created':
status = 'warning'
break
}
@ -491,7 +500,7 @@ export default {
}
.dark-row {
background-color: #f5f5f5;
background-color: #f9f9f9;
}
</style>

View File

@ -68,11 +68,7 @@ export default {
height: auto;
/deep/ .ant-layout-sider-children {
overflow-y: hidden;
&:hover {
overflow-y: auto;
}
overflow-y: auto;
}
&.ant-fixed-sidemenu {
@ -86,6 +82,14 @@ export default {
.ant-menu-light {
border-right-color: transparent;
padding: 14px 0;
}
}
&.dark {
.ant-menu-dark {
border-right-color: transparent;
padding: 14px 0;
}
}
}