diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/alphafine/search/manager/impl/RecentSearchManager.java b/designer-realize/src/main/java/com/fr/design/mainframe/alphafine/search/manager/impl/RecentSearchManager.java index bb1d21ec8..5f0ad4da4 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/alphafine/search/manager/impl/RecentSearchManager.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/alphafine/search/manager/impl/RecentSearchManager.java @@ -77,8 +77,12 @@ public class RecentSearchManager implements AlphaFineSearchProvider { recentModelList = getRecentModelList(searchText); if (recentModelList != null && recentModelList.size() > 0) { modelList.add(new MoreModel(com.fr.design.i18n.Toolkit.i18nText("FR-Designer_AlphaFine_Latest"))); + if (recentModelList.size() > AlphaFineConstants.LATEST_SHOW_SIZE) { + modelList.addAll(recentModelList.subList(0, AlphaFineConstants.LATEST_SHOW_SIZE)); + } else { + modelList.addAll(recentModelList); + } } - modelList.addAll(recentModelList.subList(0, AlphaFineConstants.LATEST_SHOW_SIZE)); return modelList; }