Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AMORO-2698] Display more details in the page of Optimizing->Optimizers #2699

Merged
merged 6 commits into from
Apr 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions ams/dashboard/src/language/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export default {
logout: 'Logout',
logoutModalTitle: 'Log out of the ams?',
order: 'Order',
token: 'Token',
cluster: 'Cluster',
database: 'Database | Databases',
table: 'Table | Tables',
Expand Down Expand Up @@ -83,6 +84,7 @@ export default {
fileContent: 'File Content',
startTime: 'Start Time',
finishTime: 'Finish Time',
touchTime: 'Touch Time',
duration: 'Duration',
optimizeType: 'Optimize Type',
parallelism: 'Parallelism',
Expand All @@ -94,6 +96,7 @@ export default {
operationDetails: 'Operation Details',
copy: 'Copy',
optimizer: 'Optimizer',
optimizerId: 'Optimizer Id',
optimizers: 'Optimizers',
container: 'Container',
status: 'Status',
Expand Down
10 changes: 8 additions & 2 deletions ams/dashboard/src/views/resource/components/List.vue
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ import { mbToSize } from '@/utils'
import { Modal, message } from 'ant-design-vue-v3'
import { useRouter } from 'vue-router'
import ScaleOut from '@/views/resource/components/ScaleOut.vue'
import { dateFormat } from '@/utils/index'

const { t } = useI18n()
const router = useRouter()
Expand Down Expand Up @@ -96,11 +97,14 @@ const tableColumns = shallowReactive([
{ dataIndex: 'operationGroup', title: t('operation'), key: 'operationGroup', ellipsis: true, width: 230, scopedSlots: { customRender: 'operationGroup' } }
])
const optimizerColumns = shallowReactive([
{ dataIndex: 'index', title: t('order'), width: 80, ellipsis: true },
{ dataIndex: 'jobId', title: t('optimizerId'), width: '15%', ellipsis: true },
{ dataIndex: 'token', title: t('token'), width: '10%', ellipsis: true },
{ dataIndex: 'groupName', title: t('optimizerGroup'), ellipsis: true },
{ dataIndex: 'container', title: t('container'), ellipsis: true },
{ dataIndex: 'jobStatus', title: t('status'), ellipsis: true },
{ dataIndex: 'resourceAllocation', title: t('resourceAllocation'), width: '20%', ellipsis: true },
{ dataIndex: 'resourceAllocation', title: t('resourceAllocation'), width: '10%', ellipsis: true },
{ dataIndex: 'startTime', title: t('startTime'), width: 172, ellipsis: true },
{ dataIndex: 'touchTime', title: t('touchTime'), width: 172, ellipsis: true },
{ dataIndex: 'operation', title: t('operation'), key: 'operation', ellipsis: true, width: 160, scopedSlots: { customRender: 'operationGroup' } }
])
const pagination = reactive(usePagination())
Expand Down Expand Up @@ -169,6 +173,8 @@ async function getOptimizersList () {
(list || []).forEach((p: IOptimizeResourceTableItem, index: number) => {
p.resourceAllocation = `${p.coreNumber} ${t('core')} ${mbToSize(p.memory)}`
p.index = (pagination.current - 1) * pagination.pageSize + index + 1
p.startTime = p.startTime ? dateFormat(p.startTime) : '-'
p.touchTime = p.touchTime ? dateFormat(p.touchTime) : '-'
optimizersList.push(p)
})
} catch (error) {
Expand Down
Loading