fix: Support search filter for cluster and template.
Support search filter for cluster instance and cluster template Closes-Bug: #1999128 Change-Id: Ic1ec950f483f6eca845aa13ba3ae533b29d844e0
This commit is contained in:
parent
228ccff07b
commit
77df05477e
@ -432,7 +432,6 @@
|
|||||||
"Container Format": "Container Format",
|
"Container Format": "Container Format",
|
||||||
"Container Killing": "Container Killing",
|
"Container Killing": "Container Killing",
|
||||||
"Container Name": "Container Name",
|
"Container Name": "Container Name",
|
||||||
"Container Orchestration Engine": "Container Orchestration Engine",
|
|
||||||
"Container Rebooting": "Container Rebooting",
|
"Container Rebooting": "Container Rebooting",
|
||||||
"Container Rebuilding": "Container Rebuilding",
|
"Container Rebuilding": "Container Rebuilding",
|
||||||
"Container Starting": "Container Starting",
|
"Container Starting": "Container Starting",
|
||||||
@ -951,7 +950,6 @@
|
|||||||
"Fixed Subnet ID": "Fixed Subnet ID",
|
"Fixed Subnet ID": "Fixed Subnet ID",
|
||||||
"Flavor": "Flavor",
|
"Flavor": "Flavor",
|
||||||
"Flavor Detail": "Flavor Detail",
|
"Flavor Detail": "Flavor Detail",
|
||||||
"Flavor ID": "Flavor ID",
|
|
||||||
"Flavor Info": "Flavor Info",
|
"Flavor Info": "Flavor Info",
|
||||||
"Flavor Name": "Flavor Name",
|
"Flavor Name": "Flavor Name",
|
||||||
"Flavor of Master Nodes": "Flavor of Master Nodes",
|
"Flavor of Master Nodes": "Flavor of Master Nodes",
|
||||||
|
@ -272,8 +272,8 @@
|
|||||||
"CIDR": "网络地址",
|
"CIDR": "网络地址",
|
||||||
"CIDR Format Error(e.g. 192.168.0.0/24, 2001:DB8::/48)": "CIDR格式错误(如:192.168.0.0/24, 2001:DB8::/48)",
|
"CIDR Format Error(e.g. 192.168.0.0/24, 2001:DB8::/48)": "CIDR格式错误(如:192.168.0.0/24, 2001:DB8::/48)",
|
||||||
"CIFS": "CIFS",
|
"CIFS": "CIFS",
|
||||||
"COE": "COE",
|
"COE": "容器编排引擎",
|
||||||
"COE Version": "COE版本",
|
"COE Version": "容器编排引擎版本",
|
||||||
"CPU": "CPU",
|
"CPU": "CPU",
|
||||||
"CPU %": "CPU使用率(%)",
|
"CPU %": "CPU使用率(%)",
|
||||||
"CPU (Core)": "CPU (核)",
|
"CPU (Core)": "CPU (核)",
|
||||||
@ -432,7 +432,6 @@
|
|||||||
"Container Format": "容器格式",
|
"Container Format": "容器格式",
|
||||||
"Container Killing": "容器终止中",
|
"Container Killing": "容器终止中",
|
||||||
"Container Name": "容器名称",
|
"Container Name": "容器名称",
|
||||||
"Container Orchestration Engine": "容器编排引擎",
|
|
||||||
"Container Rebooting": "容器重启中",
|
"Container Rebooting": "容器重启中",
|
||||||
"Container Rebuilding": "容器重建中",
|
"Container Rebuilding": "容器重建中",
|
||||||
"Container Starting": "容器启动中",
|
"Container Starting": "容器启动中",
|
||||||
@ -951,7 +950,6 @@
|
|||||||
"Fixed Subnet ID": "内网子网ID",
|
"Fixed Subnet ID": "内网子网ID",
|
||||||
"Flavor": "云主机类型",
|
"Flavor": "云主机类型",
|
||||||
"Flavor Detail": "云主机类型详情",
|
"Flavor Detail": "云主机类型详情",
|
||||||
"Flavor ID": "云主机类型ID",
|
|
||||||
"Flavor Info": "配置信息",
|
"Flavor Info": "配置信息",
|
||||||
"Flavor Name": "云主机类型名称",
|
"Flavor Name": "云主机类型名称",
|
||||||
"Flavor of Master Nodes": "主节点类型",
|
"Flavor of Master Nodes": "主节点类型",
|
||||||
|
@ -69,7 +69,7 @@ export class StepInfo extends Base {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'coe',
|
name: 'coe',
|
||||||
label: t('Container Orchestration Engine'),
|
label: t('COE'),
|
||||||
type: 'select',
|
type: 'select',
|
||||||
options: [
|
options: [
|
||||||
{
|
{
|
||||||
|
@ -41,7 +41,18 @@ export class ClusterTemplates extends Base {
|
|||||||
return actionConfigs.actionConfigs;
|
return actionConfigs.actionConfigs;
|
||||||
}
|
}
|
||||||
|
|
||||||
getColumns = () => getBaseTemplateColumns(this);
|
getColumns() {
|
||||||
|
return getBaseTemplateColumns(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
get searchFilters() {
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
label: t('Name'),
|
||||||
|
name: 'name',
|
||||||
|
},
|
||||||
|
];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default inject('rootStore')(observer(ClusterTemplates));
|
export default inject('rootStore')(observer(ClusterTemplates));
|
||||||
|
@ -14,6 +14,7 @@
|
|||||||
|
|
||||||
import Base from 'containers/List';
|
import Base from 'containers/List';
|
||||||
import { inject, observer } from 'mobx-react';
|
import { inject, observer } from 'mobx-react';
|
||||||
|
import { getOptions } from 'utils';
|
||||||
import { clusterStatus, healthStatus } from 'resources/magnum/cluster';
|
import { clusterStatus, healthStatus } from 'resources/magnum/cluster';
|
||||||
import globalClustersStore from 'src/stores/magnum/clusters';
|
import globalClustersStore from 'src/stores/magnum/clusters';
|
||||||
import actionConfigs from './actions';
|
import actionConfigs from './actions';
|
||||||
@ -43,36 +44,57 @@ export class Clusters extends Base {
|
|||||||
return actionConfigs.actionConfigs;
|
return actionConfigs.actionConfigs;
|
||||||
}
|
}
|
||||||
|
|
||||||
getColumns = () => [
|
getColumns() {
|
||||||
{
|
return [
|
||||||
title: t('ID/Name'),
|
{
|
||||||
dataIndex: 'name',
|
title: t('ID/Name'),
|
||||||
routeName: this.getRouteName('containerInfraClusterDetail'),
|
dataIndex: 'name',
|
||||||
},
|
routeName: this.getRouteName('containerInfraClusterDetail'),
|
||||||
{
|
|
||||||
title: t('Status'),
|
|
||||||
isHideable: true,
|
|
||||||
dataIndex: 'status',
|
|
||||||
valueMap: clusterStatus,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: t('Health Status'),
|
|
||||||
isHideable: true,
|
|
||||||
dataIndex: 'health_status',
|
|
||||||
render: (value) => healthStatus[value] || value || '-',
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: t('Keypair'),
|
|
||||||
isHideable: true,
|
|
||||||
dataIndex: 'keypair',
|
|
||||||
hidden: this.isAdminPage,
|
|
||||||
render: (value) => {
|
|
||||||
return value
|
|
||||||
? this.getLinkRender('keypairDetail', value, { id: value })
|
|
||||||
: '-';
|
|
||||||
},
|
},
|
||||||
},
|
{
|
||||||
];
|
title: t('Status'),
|
||||||
|
isHideable: true,
|
||||||
|
dataIndex: 'status',
|
||||||
|
valueMap: clusterStatus,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: t('Health Status'),
|
||||||
|
isHideable: true,
|
||||||
|
dataIndex: 'health_status',
|
||||||
|
render: (value) => healthStatus[value] || value || '-',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: t('Keypair'),
|
||||||
|
isHideable: true,
|
||||||
|
dataIndex: 'keypair',
|
||||||
|
hidden: this.isAdminPage,
|
||||||
|
render: (value) => {
|
||||||
|
return value
|
||||||
|
? this.getLinkRender('keypairDetail', value, { id: value })
|
||||||
|
: '-';
|
||||||
|
},
|
||||||
|
},
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
get searchFilters() {
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
label: t('Name'),
|
||||||
|
name: 'name',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: t('Status'),
|
||||||
|
name: 'status',
|
||||||
|
options: getOptions(clusterStatus),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: t('Health Status'),
|
||||||
|
name: 'health_status',
|
||||||
|
options: getOptions(healthStatus),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default inject('rootStore')(observer(Clusters));
|
export default inject('rootStore')(observer(Clusters));
|
||||||
|
Loading…
Reference in New Issue
Block a user