Skip to content

Commit

Permalink
fix: Fix search by app
Browse files Browse the repository at this point in the history
  • Loading branch information
leoliu committed Feb 22, 2020
1 parent 7f46a68 commit 69336fc
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 5 deletions.
3 changes: 2 additions & 1 deletion src/pages/projects/containers/Pods/index.jsx

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/pages/projects/containers/Routes/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,11 @@ export default class Routes extends Base {
},
{
title: t('Application'),
dataIndex: 'app',
dataIndex: 'app.kubernetes.io/name',
isHideable: true,
search: true,
width: '22%',
render: (_, record) => record.app,
},
{
title: t('Created Time'),
Expand Down
3 changes: 2 additions & 1 deletion src/pages/projects/containers/Services/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,11 @@ export default class Services extends Base {
},
{
title: t('Application'),
dataIndex: 'app',
dataIndex: 'app.kubernetes.io/name',
isHideable: true,
search: true,
width: '16%',
render: (_, record) => record.app,
},
{
title: t('Created Time'),
Expand Down
3 changes: 2 additions & 1 deletion src/pages/projects/containers/Workloads/Base.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -141,10 +141,11 @@ export default class WorkloadsBaseList extends Base {
},
{
title: t('Application'),
dataIndex: 'app',
dataIndex: 'app.kubernetes.io/name',
isHideable: true,
search: true,
width: '25%',
render: (_, record) => record.app,
},
this.module === 'deployments'
? {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ export const getQueryString = params =>

export const getFilterString = (
params,
fuzzyMatchKeys = ['name', 'app', 'label', 'annotation']
fuzzyMatchKeys = ['name', 'app.kubernetes.io/name', 'label', 'annotation']
) =>
Object.keys(params)
.filter(key => !isUndefined(params[key]) && params[key] !== '')
Expand Down

0 comments on commit 69336fc

Please sign in to comment.