* keep query criteria * configlist_returnpage_bug_fix
This commit is contained in:
parent
ee8da9ba6f
commit
49ff59ef67
@ -185,23 +185,31 @@ class ClusterNodeList extends React.Component {
|
||||
width="20%"
|
||||
cell={function(value, index, record) {
|
||||
if (value === 'UP') {
|
||||
return (<Tag key={`p_p_${value}`} type="primary" color="green">
|
||||
{value}
|
||||
</Tag>);
|
||||
return (
|
||||
<Tag key={`p_p_${value}`} type="primary" color="green">
|
||||
{value}
|
||||
</Tag>
|
||||
);
|
||||
}
|
||||
if (value === 'DOWN') {
|
||||
return (<Tag key={`p_p_${value}`} type="primary" color="red">
|
||||
{value}
|
||||
</Tag>);
|
||||
return (
|
||||
<Tag key={`p_p_${value}`} type="primary" color="red">
|
||||
{value}
|
||||
</Tag>
|
||||
);
|
||||
}
|
||||
if (value === 'SUSPICIOUS') {
|
||||
return (<Tag key={`p_p_${value}`} type="primary" color="orange">
|
||||
{value}
|
||||
</Tag>);
|
||||
return (
|
||||
<Tag key={`p_p_${value}`} type="primary" color="orange">
|
||||
{value}
|
||||
</Tag>
|
||||
);
|
||||
}
|
||||
return (<Tag key={`p_p_${value}`} type="primary" color="turquoise">
|
||||
{value}
|
||||
</Tag>);
|
||||
return (
|
||||
<Tag key={`p_p_${value}`} type="primary" color="turquoise">
|
||||
{value}
|
||||
</Tag>
|
||||
);
|
||||
}}
|
||||
/>
|
||||
<Column
|
||||
@ -210,13 +218,17 @@ class ClusterNodeList extends React.Component {
|
||||
width="50%"
|
||||
cell={function(value, index, record) {
|
||||
function showCollapse() {
|
||||
const collapse = (<Collapse>
|
||||
<Panel title="节点元数据">
|
||||
<ul>
|
||||
<li><pre>{JSON.stringify(value, null, 4)}</pre></li>
|
||||
</ul>
|
||||
</Panel>
|
||||
</Collapse>);
|
||||
const collapse = (
|
||||
<Collapse>
|
||||
<Panel title="节点元数据">
|
||||
<ul>
|
||||
<li>
|
||||
<pre>{JSON.stringify(value, null, 4)}</pre>
|
||||
</li>
|
||||
</ul>
|
||||
</Panel>
|
||||
</Collapse>
|
||||
);
|
||||
return collapse;
|
||||
}
|
||||
|
||||
|
@ -54,6 +54,8 @@ class ConfigDetail extends React.Component {
|
||||
this.tenant = getParams('namespace') || '';
|
||||
this.searchDataId = getParams('searchDataId') || '';
|
||||
this.searchGroup = getParams('searchGroup') || '';
|
||||
this.pageSize = getParams('pageSize');
|
||||
this.pageNo = getParams('pageNo');
|
||||
// this.params = window.location.hash.split('?')[1]||'';
|
||||
}
|
||||
|
||||
@ -149,6 +151,8 @@ class ConfigDetail extends React.Component {
|
||||
group: this.searchGroup,
|
||||
dataId: this.searchDataId,
|
||||
namespace: this.tenant,
|
||||
pageNo: this.pageNo,
|
||||
pageSize: this.pageSize,
|
||||
})
|
||||
);
|
||||
}
|
||||
|
@ -318,8 +318,17 @@ class ConfigEditor extends React.Component {
|
||||
const namespace = getParams('namespace');
|
||||
const group = getParams('searchGroup') || '';
|
||||
const dataId = getParams('searchDataId') || '';
|
||||
const pageSize = getParams('pageSize');
|
||||
const pageNo = getParams('pageNo');
|
||||
this.props.history.push(
|
||||
generateUrl('/configurationManagement', { serverId, group, dataId, namespace })
|
||||
generateUrl('/configurationManagement', {
|
||||
serverId,
|
||||
group,
|
||||
dataId,
|
||||
namespace,
|
||||
pageSize,
|
||||
pageNo,
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -84,7 +84,7 @@ class ConfigurationManagement extends React.Component {
|
||||
value: '',
|
||||
visible: false,
|
||||
total: 0,
|
||||
pageSize: 10,
|
||||
pageSize: getParams('pageSize') ? getParams('pageSize') : 10,
|
||||
currentPage: 1,
|
||||
dataSource: [],
|
||||
fieldValue: [],
|
||||
@ -252,15 +252,21 @@ class ConfigurationManagement extends React.Component {
|
||||
}
|
||||
this.tenant = getParams('namespace') || ''; // 为当前实例保存tenant参数
|
||||
this.serverId = getParams('serverId') || '';
|
||||
const prePageNo = getParams('pageNo');
|
||||
const prePageSize = getParams('pageSize');
|
||||
this.pageNo = prePageNo ? prePageNo : pageNo;
|
||||
this.pageSize = prePageSize ? prePageSize : this.state.pageSize;
|
||||
const params = {
|
||||
dataId: this.dataId,
|
||||
group: this.group,
|
||||
appName: this.appName,
|
||||
config_tags: this.state.config_tags.join(','),
|
||||
pageNo,
|
||||
pageSize: this.state.pageSize,
|
||||
pageNo: prePageNo ? prePageNo : pageNo,
|
||||
pageSize: prePageSize ? prePageSize : this.state.pageSize,
|
||||
tenant: this.tenant,
|
||||
};
|
||||
setParams('pageSize', null);
|
||||
setParams('pageNo', null);
|
||||
if (this.dataId.indexOf('*') !== -1 || this.group.indexOf('*') !== -1) {
|
||||
params.search = 'blur';
|
||||
} else {
|
||||
@ -514,7 +520,7 @@ class ConfigurationManagement extends React.Component {
|
||||
record.group
|
||||
}&namespace=${this.tenant}&edasAppName=${this.edasAppName}&searchDataId=${
|
||||
this.dataId
|
||||
}&searchGroup=${this.group}`
|
||||
}&searchGroup=${this.group}&pageSize=${this.pageSize}&pageNo=${this.pageNo}`
|
||||
);
|
||||
}
|
||||
|
||||
@ -526,7 +532,9 @@ class ConfigurationManagement extends React.Component {
|
||||
record.group
|
||||
}&namespace=${this.tenant}&edasAppName=${this.edasAppName}&edasAppId=${
|
||||
this.edasAppId
|
||||
}&searchDataId=${this.dataId}&searchGroup=${this.group}`
|
||||
}&searchDataId=${this.dataId}&searchGroup=${this.group}&pageSize=${this.pageSize}&pageNo=${
|
||||
this.pageNo
|
||||
}`
|
||||
);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user