File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
projects/angular/components/ui-grid/src Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change 742742 [searchable] ="false "
743743 [value] ="suggestValue "
744744 [placeholder] ="column.title ?? '' "
745- [items] ="addAllFilterOption (column.dropdown!.suggestItems, column) "
745+ [items] ="mapFilterOptions (column.dropdown!.suggestItems, column) "
746746 [compactSummaryTemplate] ="displayedFilterName "
747747 [maxSelectionConfig] ="{
748748 count: (disableFilterSelection$ | async) && (column.dropdown!.multi || selectedFilters === undefined) ? suggestValue.length : Infinity,
Original file line number Diff line number Diff line change @@ -1250,7 +1250,17 @@ export class UiGridComponent<T extends IGridDataEntry>
12501250 return dropdownHasValue || searchableHasValue ;
12511251 }
12521252
1253- addAllFilterOption ( items : ISuggestDropdownValueData [ ] , column : UiGridColumnDirective < T > ) {
1253+ mapFilterOptions ( items : ISuggestDropdownValueData [ ] , column : UiGridColumnDirective < T > ) {
1254+ items = items
1255+ . filter ( item => ! ! column . dropdown ! . findDropDownOptionBySuggestValue ( item ) )
1256+ . map ( item => {
1257+ const translatedText = this . intl . translateDropdownOption ( column . dropdown ! . findDropDownOptionBySuggestValue ( item ) ! ) ;
1258+ return {
1259+ ...item ,
1260+ text : translatedText ,
1261+ } ;
1262+ } ) ;
1263+
12541264 if ( column . dropdown ?. multi || ! column . dropdown ?. showAllOption ) { return items ; }
12551265
12561266 const allOption : ISuggestValueData < undefined > = {
You can’t perform that action at this time.
0 commit comments