Skip to content

Commit

Permalink
Merge pull request #735 from PmcFizz/main
Browse files Browse the repository at this point in the history
feat: Select组件配置可以搜索
  • Loading branch information
qmhu authored Apr 25, 2023
2 parents 33e4bc3 + 738c934 commit ad1f84e
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/web/src/pages/Cost/WorkloadInsight/InsightSearchPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ export const InsightSearchPanel = React.memo(() => {
<Select
options={namespaceOptions}
placeholder={t('命名空间')}
filterable
value={selectedNamespace ?? undefined}
onChange={(value: any) => {
dispatch(insightAction.selectedNamespace(value));
Expand All @@ -188,6 +189,7 @@ export const InsightSearchPanel = React.memo(() => {
<Select
options={workloadTypeOptions}
placeholder={t('Workload类型')}
filterable
value={selectedWorkloadType ?? undefined}
onChange={(value: any) => {
dispatch(insightAction.selectedWorkloadType(value));
Expand All @@ -209,6 +211,7 @@ export const InsightSearchPanel = React.memo(() => {
<Select
options={workloadOptions}
placeholder={t('Workload')}
filterable
value={selectedWorkload ?? undefined}
onChange={(value: any) => {
dispatch(insightAction.selectedWorkload(value));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ export const OverviewSearchPanel = React.memo(() => {
<Select
options={namespaceOptions}
placeholder={t('命名空间')}
filterable
value={selectedNamespace ?? undefined}
onChange={(value: any) => {
dispatch(insightAction.selectedNamespace(value));
Expand All @@ -164,6 +165,7 @@ export const OverviewSearchPanel = React.memo(() => {
<Select
options={workloadTypeOptions}
placeholder={t('Workload类型')}
filterable
value={selectedWorkloadType ?? undefined}
onChange={(value: any) => {
dispatch(insightAction.selectedWorkloadType(value));
Expand All @@ -185,6 +187,7 @@ export const OverviewSearchPanel = React.memo(() => {
<Select
options={workloadOptions}
placeholder={t('Workload')}
filterable
value={selectedWorkload ?? undefined}
onChange={(value: any) => {
dispatch(insightAction.selectedWorkload(value));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ const SearchForm: React.FC<SearchFormProps> = ({ recommendation, setFilterParams
<Select
options={nameSpaceOptions}
placeholder={t('请选择Namespace')}
filterable
style={{ margin: '0px 20px' }}
/>
</FormItem>
Expand All @@ -56,6 +57,7 @@ const SearchForm: React.FC<SearchFormProps> = ({ recommendation, setFilterParams
<Select
options={workloadTypeOptions}
placeholder={t('请选择工作负载类型')}
filterable
style={{ margin: '0px 20px' }}
/>
</FormItem>
Expand Down

0 comments on commit ad1f84e

Please sign in to comment.