Skip to content

Commit

Permalink
fix: No data when change pods of helm cluster (#472)
Browse files Browse the repository at this point in the history
  • Loading branch information
liiil825 authored and sunnywx committed Oct 10, 2018
1 parent bb860fb commit 7e782cd
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/locales/zh/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -344,9 +344,9 @@

"Choose category": "选择分类",
"Deployment Name": "部署名称",
"Deployment Node": "部署节点",
"StatefulSet Node": "状态节点",
"DaemonSet Node": "守护节点",
"Deployment Pods": "部署",
"StatefulSet Pods": "有状态副本集",
"DaemonSet Pods": "守护进程集",
"Rollback cluster": "回滚集群",
"Update_env cluster": "修改集群环境",
"Update cluster env": "修改集群环境",
Expand Down
13 changes: 10 additions & 3 deletions src/pages/Admin/Clusters/Detail/Helm/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ export default class HelmCluster extends React.Component {
const { onChangeK8sTag } = this.props.clusterDetailStore;

return (
<DetailTabs tabs={['Deployments', 'StatefulSets', 'DaemonSets']} changeTab={onChangeK8sTag} />
<DetailTabs
tabs={['Deployment Pods', 'StatefulSet Pods', 'DaemonSet Pods']}
changeTab={onChangeK8sTag}
/>
);
}

Expand Down Expand Up @@ -71,11 +74,11 @@ export default class HelmCluster extends React.Component {

const props = {
isLoading,
columns: columns(t, onChangeNodeStatus, extendedRowKeys),
columns: columns(t, onChangeExtend, extendedRowKeys),
dataSource: clusterNodes,
filterList: getFilterOptions({
trans: t,
onChange: onChangeExtend,
onChange: onChangeNodeStatus,
selectValue: selectNodeStatus
}),
pagination: {
Expand Down Expand Up @@ -124,6 +127,10 @@ export default class HelmCluster extends React.Component {
}

render() {
const { clusterDetailStore } = this.props;
const { isLoading } = clusterDetailStore;
if (isLoading) return null;

return (
<div>
{this.renderDetailTabs()}
Expand Down

0 comments on commit 7e782cd

Please sign in to comment.