diff --git a/core/core-backend/src/main/java/io/dataease/template/manage/TemplateCenterManage.java b/core/core-backend/src/main/java/io/dataease/template/manage/TemplateCenterManage.java index f116cdf500..4793de3c25 100644 --- a/core/core-backend/src/main/java/io/dataease/template/manage/TemplateCenterManage.java +++ b/core/core-backend/src/main/java/io/dataease/template/manage/TemplateCenterManage.java @@ -206,7 +206,7 @@ public class TemplateCenterManage { MarketApplicationSpecVO spec = marketTemplateV2ItemResult.getApplication().getSpec(); MarketApplicationMetaDataVO metadata = marketTemplateV2ItemResult.getApplication().getMetadata(); if ("Y".equalsIgnoreCase(spec.getSuggest())) { - contents.add(new TemplateMarketDTO(metadata.getName(), spec.getDisplayName(), spec.getScreenshots().get(0).getUrl(), spec.getLinks().get(0).getUrl(), categoriesMap.get(spec.getLabel()), spec.getTemplateType(), useTime.get(spec.getReadmeName()), "Y")); + contents.add(new TemplateMarketDTO(metadata.getName(), spec.getDisplayName(), spec.getScreenshots().get(0).getUrl(), spec.getLinks().get(0).getUrl(), categoriesMap.get(spec.getLabel()), spec.getTemplateType(), useTime.get(spec.getReadmeName()), "Y", spec.getTemplateClassification())); } }); } @@ -246,7 +246,7 @@ public class TemplateCenterManage { v2BaseResponse.getItems().stream().forEach(marketTemplateV2ItemResult -> { MarketApplicationSpecVO spec = marketTemplateV2ItemResult.getApplication().getSpec(); MarketApplicationMetaDataVO metadata = marketTemplateV2ItemResult.getApplication().getMetadata(); - contents.add(new TemplateMarketDTO(metadata.getName(), spec.getDisplayName(), spec.getScreenshots().get(0).getUrl(), spec.getLinks().get(0).getUrl(), categoriesMap.get(spec.getLabel()), spec.getTemplateType(), useTime.get(spec.getReadmeName()), spec.getSuggest())); + contents.add(new TemplateMarketDTO(metadata.getName(), spec.getDisplayName(), spec.getScreenshots().get(0).getUrl(), spec.getLinks().get(0).getUrl(), categoriesMap.get(spec.getLabel()), spec.getTemplateType(), useTime.get(spec.getReadmeName()), spec.getSuggest(), spec.getTemplateClassification())); if (categoriesMap.get(spec.getLabel()) != null) { activeCategoriesName.add(categoriesMap.get(spec.getLabel())); } diff --git a/core/core-frontend/src/views/template-market/index.vue b/core/core-frontend/src/views/template-market/index.vue index 11e97d151d..b73744189b 100644 --- a/core/core-frontend/src/views/template-market/index.vue +++ b/core/core-frontend/src/views/template-market/index.vue @@ -109,7 +109,11 @@ highlight-current :current-node-key="state.marketActiveTab" @node-click="nodeClick" - /> + > + +
{ } } - public TemplateMarketDTO(String id, String title, String themeRepo, String templateUrl, String categoryName, String templateType, Long recentUseTime, String suggest) { + public TemplateMarketDTO(String id, String title, String themeRepo, String templateUrl, String categoryName, String templateType, Long recentUseTime, String suggest, String classify) { this.id = id; this.title = title; this.metas = new MarketMetasVO(templateUrl); @@ -70,6 +70,9 @@ public class TemplateMarketDTO implements Comparable { this.templateType = templateType; this.categories = new ArrayList<>(Arrays.asList(new MarketCategoryVO(categoryName))) ; this.categoryNames = new ArrayList<>(Arrays.asList(categoryName)) ; + if("DATA".equals(classify)){ + this.classify = "app"; + } if (recentUseTime != null) { this.recentUseTime = recentUseTime; String name = Translator.get("i18n_template_recent"); diff --git a/sdk/api/api-base/src/main/java/io/dataease/api/template/vo/MarketApplicationSpecVO.java b/sdk/api/api-base/src/main/java/io/dataease/api/template/vo/MarketApplicationSpecVO.java index a91e7c9f89..ea4070370b 100644 --- a/sdk/api/api-base/src/main/java/io/dataease/api/template/vo/MarketApplicationSpecVO.java +++ b/sdk/api/api-base/src/main/java/io/dataease/api/template/vo/MarketApplicationSpecVO.java @@ -22,6 +22,8 @@ public class MarketApplicationSpecVO { private String label; + private String templateClassification; + private String readmeName; // 是否推荐