diff --git a/app/apps-tab/index/route.js b/app/apps-tab/index/route.js index c164da739..fa34ad5cf 100644 --- a/app/apps-tab/index/route.js +++ b/app/apps-tab/index/route.js @@ -13,7 +13,6 @@ export default Route.extend({ const catalog = get(this, 'catalog'); return this.get('globalStore').find('app').then((apps) => { - debugger; let deps = []; apps.forEach((stack) => { diff --git a/lib/shared/addon/components/catalog-index/component.js b/lib/shared/addon/components/catalog-index/component.js index ff271ef12..c64ed7702 100644 --- a/lib/shared/addon/components/catalog-index/component.js +++ b/lib/shared/addon/components/catalog-index/component.js @@ -59,18 +59,15 @@ export default Component.extend({ let out = {}; let templates = this.get('catalog.templateCache'); let base = this.get('catalog.templateBase'); - // let plusInfra = this.get('scope.currentProject.clusterOwner') === true; + let plusInfra = this.get('scope.currentProject.clusterOwner') === true; templates.forEach((tpl) => { - if (base === tpl.get('templateBase') || (tpl.get('templateBase') === 'kubernetes')) { + // TODO 2.0 does a kubernetes template need a category? + if (base === tpl.get('templateBase') || (plusInfra && tpl.get('templateBase') === 'infra') || (tpl.get('templateBase') === 'kubernetes')) { if (tpl.categories) { tpl.categories.forEach((ctgy) => { categories.push(ctgy); }); - } else { - // TODO 2.0 does a kubernetes template need a category? - tpl.set('categories', ['uncategorized']); - categories.push('uncategorized'); } } }); @@ -109,7 +106,7 @@ export default Component.extend({ return this.get('globalStore').all('catalog').map((obj) => { return { catalogId: get(obj, 'id'), - label: get(obj,'displayName'), + label: get(obj,'name'), }; }); }), @@ -119,7 +116,7 @@ export default Component.extend({ let result = []; let base = this.get('catalog.templateBase'); let catalog = this.get('model.catalog').filter((item) => { - if (item.templateBase === base || item.templateBase === 'kubernetes' || item.templateBase === '') { + if (item.templateBase === base || item.templateBase === 'kubernetes' || item.templateBase === 'infra') { return true; } return false; diff --git a/lib/shared/addon/components/catalog-index/template.hbs b/lib/shared/addon/components/catalog-index/template.hbs index fe583d3d2..04597d818 100644 --- a/lib/shared/addon/components/catalog-index/template.hbs +++ b/lib/shared/addon/components/catalog-index/template.hbs @@ -5,7 +5,9 @@