From f811190e8a2bc92bc6cf44586d18d6adb542ee2a Mon Sep 17 00:00:00 2001 From: Vincent Fiduccia Date: Sat, 3 Jun 2017 01:20:39 -0700 Subject: [PATCH] Cleanup old add host --- .../project/host-template/keys/controller.js | 68 --------- .../project/host-template/keys/route.js | 9 -- .../project/host-template/keys/template.hbs | 74 ---------- app/components/add-host-template/component.js | 64 --------- app/components/add-host-template/template.hbs | 55 ------- app/components/cloud-host-select/component.js | 135 ------------------ app/components/cloud-host-select/template.hbs | 23 --- .../modal-add-host-template/component.js | 21 --- .../modal-add-host-template/template.hbs | 17 --- app/helpers/host-public-values.js | 9 -- app/hosts/container-cloud/add/route.js | 35 ----- app/hosts/container-cloud/add/template.hbs | 7 - app/hosts/container-cloud/index/controller.js | 6 - app/hosts/container-cloud/index/route.js | 55 ------- app/hosts/container-cloud/index/template.hbs | 1 - app/hosts/container-cloud/template.hbs | 1 - app/templates/host/cloud/browse.hbs | 50 ------- app/templates/host/cloud/favorites.hbs | 36 ----- app/templates/host/cloud/table-content.hbs | 47 ------ 19 files changed, 713 deletions(-) delete mode 100644 app/authenticated/project/host-template/keys/controller.js delete mode 100644 app/authenticated/project/host-template/keys/route.js delete mode 100644 app/authenticated/project/host-template/keys/template.hbs delete mode 100644 app/components/add-host-template/component.js delete mode 100644 app/components/add-host-template/template.hbs delete mode 100644 app/components/cloud-host-select/component.js delete mode 100644 app/components/cloud-host-select/template.hbs delete mode 100644 app/components/modal-add-host-template/component.js delete mode 100644 app/components/modal-add-host-template/template.hbs delete mode 100644 app/helpers/host-public-values.js delete mode 100644 app/hosts/container-cloud/add/route.js delete mode 100644 app/hosts/container-cloud/add/template.hbs delete mode 100644 app/hosts/container-cloud/index/controller.js delete mode 100644 app/hosts/container-cloud/index/route.js delete mode 100644 app/hosts/container-cloud/index/template.hbs delete mode 100644 app/hosts/container-cloud/template.hbs delete mode 100644 app/templates/host/cloud/browse.hbs delete mode 100644 app/templates/host/cloud/favorites.hbs delete mode 100644 app/templates/host/cloud/table-content.hbs diff --git a/app/authenticated/project/host-template/keys/controller.js b/app/authenticated/project/host-template/keys/controller.js deleted file mode 100644 index dde946cdd..000000000 --- a/app/authenticated/project/host-template/keys/controller.js +++ /dev/null @@ -1,68 +0,0 @@ -import Ember from 'ember'; - -const PROVIDERS = [ - { - id: 'Amazon', - translationKey: 'hostTemplatesPage.keys.dropdownAdd.amazon' - }, - { - id: 'Digital Ocean', - translationKey: 'hostTemplatesPage.keys.dropdownAdd.do' - }, - { - id: 'Packet', - translationKey: 'hostTemplatesPage.keys.dropdownAdd.packet' - }, -] - -export default Ember.Controller.extend({ - modalService: Ember.inject.service('modal'), - providers: PROVIDERS, - sortBy: 'flavorPrefix', - actions: { - newTemplateKey(id) { - this.get('modalService').toggleModal('modal-add-host-template', { - provider: id, - hostKeys: this.get('model'), - }); - } - }, - headers: [ - { - name: 'state', - translationKey: 'hostTemplatesPage.table.state', - sort: ['state','flavorPrefix', 'name', 'created'], - width: '100' - }, - { - name: 'flavorPrefix', - translationKey: 'hostTemplatesPage.table.flavor', - sort: ['flavorPrefix', 'state', 'name', 'created'], - width: '150' - }, - { - name: 'name', - translationKey: 'hostTemplatesPage.table.name', - sort: ['name','flavorPrefix', 'state', 'created'], - width: '' - }, - { - name: 'description', - translationKey: 'hostTemplatesPage.table.desc', - sort: ['state','flavorPrefix', 'name', 'created'], - width: '' - }, - { - name: 'publicValues', - translationKey: 'hostTemplatesPage.table.public', - sort: ['publicValues','flavorPrefix', 'name', 'created'], - width: '' - }, - { - name: 'created', - translationKey: 'hostTemplatesPage.table.created', - sort: ['created','flavorPrefix', 'name', 'state'], - width: '150' - }, - ], -}); diff --git a/app/authenticated/project/host-template/keys/route.js b/app/authenticated/project/host-template/keys/route.js deleted file mode 100644 index 5ec4d2fec..000000000 --- a/app/authenticated/project/host-template/keys/route.js +++ /dev/null @@ -1,9 +0,0 @@ -import Ember from 'ember'; - -export default Ember.Route.extend({ - model: function(/*params,transition*/) { - return this.get('store').find('hostTemplates', null, {forceReload: true}).then((templates) => { - return templates; - }); - } -}); diff --git a/app/authenticated/project/host-template/keys/template.hbs b/app/authenticated/project/host-template/keys/template.hbs deleted file mode 100644 index 85c354778..000000000 --- a/app/authenticated/project/host-template/keys/template.hbs +++ /dev/null @@ -1,74 +0,0 @@ -
-

{{t 'hostTemplatesPage.keys.header'}}

- -
- -
-
- -
-

{{t 'hostTemplatesPage.keys.header'}}

- {{#if instances.length}} - {{#sortable-table - classNames="grid fixed mt-10 sortable-table" - bulkActions=false - paging=false - search=false - sortBy=sortBy - headers=headers - body=model - fullRows=false - as |sortable kind key| - }} - {{#if (eq kind "row")}} - - {{badge-state model=key}} - - - {{#if key.flavorPrefix}}{{key.flavorPrefix}}{{else}}{{t 'hostTemplatesPage.table.noName'}}{{/if}} - - - {{#if key.name}}{{key.displayName}}{{else}}{{t 'hostTemplatesPage.table.noName'}}{{/if}} - - - {{#if key.description}}{{key.description}}{{else}}{{t 'hostTemplatesPage.table.noDesc'}}{{/if}} - - - {{#if key.publicValues}} - {{#copy-to-clipboard clipboardText=key.publicValues size="small"}} - {{key.publicValues}} - {{/copy-to-clipboard}} - {{else}} - {{t 'hostTemplatesPage.table.noPublicValue'}} - {{/if}} - - - {{date-calendar key.created}} - - - {{action-menu model=key}} - - {{else if (eq kind "norows")}} - - {{t 'hostTemplatesPage.table.noData'}} - - {{/if}} - {{/sortable-table}} - {{else}} - {{empty-table resource="container" showNew=false}} - {{/if}} -
\ No newline at end of file diff --git a/app/components/add-host-template/component.js b/app/components/add-host-template/component.js deleted file mode 100644 index 983d1609d..000000000 --- a/app/components/add-host-template/component.js +++ /dev/null @@ -1,64 +0,0 @@ -import Ember from 'ember'; - -// this component really doesn't care about the host provider -// all its going to do is validate and save so the partial could -// load the template for adding and saving keys -export default Ember.Component.extend({ - store: Ember.inject.service(), - cloudPlans: Ember.inject.service(), - add: false, - templates: null, - hostTemplate: null, - selectedKey: null, - newSelectedKey: null, - provider: null, - providerKeyDetails: Ember.computed.alias('cloudPlans.hostDetails'), - name: null, - secretValue: null, - publicValue: null, - noSelect: false, - init() { - this._super(...arguments); - if (this.get('add') && this.get('selectedKey')) { - this.set('newSelectedKey', this.get('selectedKey')); - } - }, - createNewTemplate: function() { - return Ember.$.extend(this.get('store').createRecord({type: 'hostTemplate'}), this.get('providerKeyDetails').findBy('flavorPrefix', this.get('provider'))); - }, - newKeyObserver: Ember.on('init', Ember.observer('name', 'secretValue', 'publicValue', function() { - var {name, secretValue, publicValue} = this.getProperties('name', 'secretValue', 'publicValue'); - var selectedKey = this.get('selectedKey'); - - if (this.get('add')) { - this.set('selectedKey.name', name); - if (selectedKey.publicValues) { - Object.keys(selectedKey.publicValues).forEach((pvk) => { - selectedKey.publicValues[pvk] = publicValue; - }); - } - if (selectedKey.secretValues) { - Object.keys(selectedKey.secretValues).forEach((svk) => { - selectedKey.secretValues[svk] = secretValue; - }); - } - } - })), - actions: { - addKey() { - this.set('selectedKey', this.set('newSelectedKey', this.createNewTemplate())); - this.set('add', true); - }, - cancelAdd(){ - this.set('selectedKey', null); - this.set('add', false); - } - }, - setHostTemplate: Ember.observer('hostTemplate', function() { - if (this.get('hostTemplate')) { - this.set('selectedKey', this.get('templates').findBy('id', this.get('hostTemplate'))); - } else { - this.set('selectedKey', null); - } - }), -}); diff --git a/app/components/add-host-template/template.hbs b/app/components/add-host-template/template.hbs deleted file mode 100644 index f1dc9feea..000000000 --- a/app/components/add-host-template/template.hbs +++ /dev/null @@ -1,55 +0,0 @@ -
- {{#if add}} -

{{t 'addHostTemplate.add.header'}}

- {{#each-in newSelectedKey as |key value|}} - {{#if (eq key 'name')}} -
- - {{input type='text' value=name}} -
- {{/if}} - {{#if (eq key 'publicValues')}} - {{#each-in (get selectedKey key) as |pKey pValue|}} -
- - {{input type='text' value=publicValue}} -
- {{/each-in}} - {{/if}} - {{#if (eq key 'secretValues')}} -
- {{#each-in (get selectedKey key) as |sKey sValue|}} -
- - {{input type='password' value=secretValue}} -
- {{/each-in}} - {{#unless noSelect}} - - {{/unless}} -
- {{/if}} - {{/each-in}} - {{else}} -
-
- - -
- {{new-select - classNames="form-control" - content=templates - optionLabelPath="name" - optionValuePath="id" - localizedLabel=false - localizedPrompt=true - prompt='addHostTemplate.choose.prompt' - value=hostTemplate - }} -
- {{/if}} -
diff --git a/app/components/cloud-host-select/component.js b/app/components/cloud-host-select/component.js deleted file mode 100644 index 47305bb5d..000000000 --- a/app/components/cloud-host-select/component.js +++ /dev/null @@ -1,135 +0,0 @@ -import Ember from 'ember'; - -const DEFAULT_REALM = 'us-west'; -const PROVIDERS = [{id: 'All'}, {id: 'Amazon'}, {id: 'Digital Ocean' }, {id: 'Packet' }]; - -export default Ember.Component.extend({ - prefs: Ember.inject.service(), - from: null, - tab: Ember.computed.alias('from'), - realmSort: DEFAULT_REALM, - providers: PROVIDERS, - memSort: null, - storageSort: null, - costSort: null, - providerSort: 'All', - sortBy: 'uiOptions.pricePerMonth', - actions: { - sendTab(id) { - this.get('triggerTabChange')(id); - }, - selectMachine(id) { - this.setProperties({ - providerSort: 'All', - memSort: null, - storageSort: null, - costSort: null, - realmSort: DEFAULT_REALM, - }); - this.get('triggerSelectMachine')(id); - }, - favoriteChanged(id) { - if (this.get('tab') === 'favorites') { - this.set('model.plans', this.get('model.plans').filter((item) => { - if (item.id !== id) { - return true; - } - return false; - })); - } - } - }, - noDataMessage: Ember.computed('tab', function() { - if (this.get('tab') === 'favorites') { - return 'hostsPage.cloudHostsPage.browsePage.table.noFavs'; - } - - return 'hostsPage.cloudHostsPage.browsePage.table.noData'; - }), - headers: [ - { - name: 'uiOptions.favorite', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.favorite', - width: '100' - }, - { - name: 'provider', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.provider', - sort: ['provider', 'uiOptions.pricePerMonth', 'uiOptions.id'], - width: '175' - }, - { - name: 'uiOptions.zone', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.zone', - sort: ['uiOptions.zone', 'provider', 'uiOptions.id'], - }, - { - name: 'uiOptions.displayName', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.instance', - sort: ['uiOptions.displayName', 'uiOptions.pricePerMonth', 'uiOptions.id'], - }, - { - name: 'uiOptions.memory', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.memory', - sort: ['uiOptions.memory', 'uiOptions.pricePerMonth','uiOptions.displayName'], - }, - { - name: 'uiOptions.transfer', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.transfer', - sort: ['uiOptions.transfer'], - }, - // { - // name: 'cpuRating', - // translationKey: 'hostsPage.cloudHostsPage.browsePage.table.cpu', - // sort: ['cpuRating:desc','displayName'], - // width: 120, - // }, - // { - // name: 'diskRating', - // translationKey: 'hostsPage.cloudHostsPage.browsePage.table.disk', - // sort: ['diskRating','displayName','zome'], - // width: 120 - // }, - { - name: 'uiOptions.pricePerMonth', - translationKey: 'hostsPage.cloudHostsPage.browsePage.table.price', - sort: ['uiOptions.pricePerMonth','uiOptions.memory:desc','uiOptions.displayName'], - width: 75, - }, - - { - width: 100, - }, - ], - - providerContent: Ember.computed('model.plans', 'providerSort', function() { - var content = this.get('model.plans'); - var prov = this.get('providerSort'); - - if (prov !== 'All') { - content = content.filterBy('provider', this.get('providerSort')) - } - - return content; - }), - - filteredContent: Ember.computed('providerContent', 'realmSort', 'costSort', 'storageSort', 'memSort', function() { - var rs = this.get('realmSort'); - var cs = this.get('costSort'); - var ms = this.get('memSort'); - var ss = this.get('storageSort'); - - if (rs === 'all') { - return this.get('providerContent'); - } else { - return this.get('providerContent').filter((plan) => { - return ( - (!rs || plan.uiOptions.realm === rs) && - (!ms || plan.uiOptions.memory >= ms) && - (!ss || plan.uiOptions.storage >= ss) && - (!cs || plan.uiOptions.pricePerMonth <= cs) - ); - }); - } - }), -}); diff --git a/app/components/cloud-host-select/template.hbs b/app/components/cloud-host-select/template.hbs deleted file mode 100644 index 8b1d0f567..000000000 --- a/app/components/cloud-host-select/template.hbs +++ /dev/null @@ -1,23 +0,0 @@ -
-
-

{{t 'hostsPage.new.header.text'}}

- {{#select-tab initialTab=from tab=tab tagName='div' classNames='inline-block' as |component|}} - - {{/select-tab}} -
-
- -
-
-
- {{partial (concat 'host/cloud/' tab)}} -
-
-
diff --git a/app/components/modal-add-host-template/component.js b/app/components/modal-add-host-template/component.js deleted file mode 100644 index 23d0dbcbe..000000000 --- a/app/components/modal-add-host-template/component.js +++ /dev/null @@ -1,21 +0,0 @@ -import Ember from 'ember'; -import ModalBase from 'ui/mixins/modal-base'; -import NewOrEdit from 'ui/mixins/new-or-edit'; - -export default Ember.Component.extend(ModalBase, NewOrEdit, { - classNames: ['medium-modal'], - store: Ember.inject.service(), - cloudPlans: Ember.inject.service(), - provider: Ember.computed.alias('modalOpts.provider'), - selectedHostTemplate: null, - primaryResource: Ember.computed.alias('selectedHostTemplate'), - hostDetails: Ember.computed.alias('cloudPlans.hostDetails'), - init() { - this._super(...arguments); - this.set('selectedHostTemplate', Ember.$.extend(this.get('store').createRecord({type: 'hostTemplate'}), this.get('hostDetails').findBy('flavorPrefix', this.get('provider')))); - }, - doneSaving(neu) { - this.get('modalOpts.hostKeys.content').pushObject(neu); - this.send('cancel'); - } -}); diff --git a/app/components/modal-add-host-template/template.hbs b/app/components/modal-add-host-template/template.hbs deleted file mode 100644 index f97f70d1e..000000000 --- a/app/components/modal-add-host-template/template.hbs +++ /dev/null @@ -1,17 +0,0 @@ -
-

{{t 'addHostTemplate.add.header'}}

-
-
- -{{top-errors errors=errors}} - \ No newline at end of file diff --git a/app/helpers/host-public-values.js b/app/helpers/host-public-values.js deleted file mode 100644 index 009fc8380..000000000 --- a/app/helpers/host-public-values.js +++ /dev/null @@ -1,9 +0,0 @@ -import Ember from 'ember'; - -export function hostPublicValues(params/*, hash*/) { - var [host] = params; - var pv = host.publicValues[`${host.driver}Config`]; - return pv; -} - -export default Ember.Helper.helper(hostPublicValues); diff --git a/app/hosts/container-cloud/add/route.js b/app/hosts/container-cloud/add/route.js deleted file mode 100644 index 1034deac4..000000000 --- a/app/hosts/container-cloud/add/route.js +++ /dev/null @@ -1,35 +0,0 @@ -import Ember from 'ember'; - - -export default Ember.Route.extend({ - cloudPlans: Ember.inject.service(), - actions: { - save() { - this.transitionTo('hosts'); - }, - cancel() { - this.transitionTo('hosts.container-cloud'); - } - }, - model(params/*, transition*/){ - if (params.cloud_id) { - return this.get('store').find('hostTemplates', null, {forceReload: true}).then((templates) => { - var plan = this.get('cloudPlans.plans').findBy('uiOptions.id', params.cloud_id); - return Ember.Object.create({ - plans: plan, - hostTemplates: templates.filterBy('flavorPrefix', plan.pretty_provider), - host: this.get('store').createRecord({type: 'host'}), - }); - }); - } else { - return this.transitionTo('hosts.container-cloud'); - } - }, - resetController(controller, isExisting /*, transition*/) { - if ( isExisting ) - { - controller.set('host', null); - controller.set('model', null); - } - }, -}); diff --git a/app/hosts/container-cloud/add/template.hbs b/app/hosts/container-cloud/add/template.hbs deleted file mode 100644 index a9c482343..000000000 --- a/app/hosts/container-cloud/add/template.hbs +++ /dev/null @@ -1,7 +0,0 @@ -{{cloud-host-add-or-edit - model=model.host - config=model.plans - hostTemplates=model.hostTemplates - cancel=(route-action 'cancel') - save=(route-action 'save') -}} \ No newline at end of file diff --git a/app/hosts/container-cloud/index/controller.js b/app/hosts/container-cloud/index/controller.js deleted file mode 100644 index 64ccad25f..000000000 --- a/app/hosts/container-cloud/index/controller.js +++ /dev/null @@ -1,6 +0,0 @@ -import Ember from 'ember'; - -export default Ember.Controller.extend({ - queryParams: ['from'], - from: 'favorites', -}); diff --git a/app/hosts/container-cloud/index/route.js b/app/hosts/container-cloud/index/route.js deleted file mode 100644 index c595ccefe..000000000 --- a/app/hosts/container-cloud/index/route.js +++ /dev/null @@ -1,55 +0,0 @@ -import Ember from 'ember'; -import C from 'ui/utils/constants'; - - -export default Ember.Route.extend({ - prefs: Ember.inject.service(), - cloudPlans: Ember.inject.service(), - queryParams: { - from: { - refreshModel: true - }, - }, - actions: { - selectMachine(id) { - this.transitionTo('hosts.container-cloud.add', id); - }, - selectTab(from) { - this.transitionTo('hosts.container-cloud', {queryParams: {from: from}}); - }, - }, - model(params/*, transition*/){ - var model = {}; - var plans = this.get('cloudPlans.plans'); - - model.realms = this.get('cloudPlans.realms'); - - switch(params.from) { - case 'favorites': - var favs = this.get(`prefs.${C.PREFS.HOST_FAVORITES}`) || []; - if (favs.length) { - model.plans = plans.filter((plan) => { - if (favs.includes(plan.uiOptions.id)) { - return true; - } - return false; - }); - } else { - let defaults = ['digitalocean-sfo2-2gb', 'digitalocean-sfo2-4gb', 'digitalocean-sfo2-8gb', 'digitalocean-sfo2-16gb']; - model.plans = plans.filter((plan) => { - if (defaults.includes(plan.uiOptions.id)) { - return true; - } - }); - this.set(`prefs.${C.PREFS.HOST_FAVORITES}`, model.plans.mapBy('uiOptions.id')); - } - break; - default: - case 'browse': - model.plans = plans; - break; - } - - return model; - }, -}); diff --git a/app/hosts/container-cloud/index/template.hbs b/app/hosts/container-cloud/index/template.hbs deleted file mode 100644 index 587619708..000000000 --- a/app/hosts/container-cloud/index/template.hbs +++ /dev/null @@ -1 +0,0 @@ -{{cloud-host-select from=from model=model triggerTabChange=(route-action 'selectTab') triggerSelectMachine=(route-action 'selectMachine')}} diff --git a/app/hosts/container-cloud/template.hbs b/app/hosts/container-cloud/template.hbs deleted file mode 100644 index e2147cab0..000000000 --- a/app/hosts/container-cloud/template.hbs +++ /dev/null @@ -1 +0,0 @@ -{{outlet}} \ No newline at end of file diff --git a/app/templates/host/cloud/browse.hbs b/app/templates/host/cloud/browse.hbs deleted file mode 100644 index 10d3b7e40..000000000 --- a/app/templates/host/cloud/browse.hbs +++ /dev/null @@ -1,50 +0,0 @@ -
-
-
- - {{new-select - classNames="form-control" - content=providers - optionLabelPath="id" - optionValuePath="id" - value=providerSort - }} -
-
- - {{new-select - classNames="form-control" - content=model.realms - optionLabelPath="translationKey" - optionValuePath="id" - localizedLabel=true - value=realmSort - }} -
-
-
-
- -
- {{input type='text' value=memSort}} - {{t 'hostsPage.cloudHostsPage.browsePage.sorts.mem.unit'}} -
-
-
- -
- {{input type='text' value=storageSort}} - {{t 'hostsPage.cloudHostsPage.browsePage.sorts.storage.unit'}} -
-
-
- -
- {{t 'hostsPage.cloudHostsPage.browsePage.sorts.cost.preUnit'}} - {{input type='text' value=costSort}} - {{t 'hostsPage.cloudHostsPage.browsePage.sorts.cost.unit'}} -
-
-
-
-{{ partial 'host/cloud/table-content' }} \ No newline at end of file diff --git a/app/templates/host/cloud/favorites.hbs b/app/templates/host/cloud/favorites.hbs deleted file mode 100644 index d1f1d9794..000000000 --- a/app/templates/host/cloud/favorites.hbs +++ /dev/null @@ -1,36 +0,0 @@ -
- {{#each filteredContent as |host|}} - {{#catalog-box - model=host.uiOptions - active=(not (eq host.uiOptions.state 'inactive')) - classNames='cloud-host' - showIcon=false - showDescription=false - as |section| - }} - {{#if (eq section 'header')}} - {{mark-favorite classNames="pull-left" tagName="span" id=host.uiOptions.id rowRemoved=(action 'favoriteChanged') iconSize='icon-2x'}} -
- {{else if (eq section 'body')}} -
-

{{host.uiOptions.displayName}}

-
-
-
- {{host.uiOptions.memory}}{{t 'hostsPage.cloudHostsPage.favoritesPage.memStUnit'}} {{t 'hostsPage.cloudHostsPage.favoritesPage.help.ram'}} -
-
- {{host.uiOptions.storage}}{{#if (not (eq host.uiOptions.provider 'Amazon'))}}{{t 'hostsPage.cloudHostsPage.favoritesPage.memStUnit'}}{{/if}} {{#if (not (eq host.uiOptions.provider 'Amazon'))}}{{t 'hostsPage.cloudHostsPage.favoritesPage.help.storage'}}{{/if}} -
-
- {{host.uiOptions.transfer}}{{t 'hostsPage.cloudHostsPage.favoritesPage.transferUnit'}} {{t 'hostsPage.cloudHostsPage.favoritesPage.help.transfer'}} -
-
- -
- {{else if (eq section 'footer')}} - - {{/if}} - {{/catalog-box}} - {{/each}} -
diff --git a/app/templates/host/cloud/table-content.hbs b/app/templates/host/cloud/table-content.hbs deleted file mode 100644 index a7139d362..000000000 --- a/app/templates/host/cloud/table-content.hbs +++ /dev/null @@ -1,47 +0,0 @@ -
- {{#sortable-table - classNames="grid sortable-table" - bulkActions=false - rowActions=false - paging=false - search=false - sortBy=sortBy - headers=headers - body=filteredContent - as |sortable kind row dt| - }} - {{#if (eq kind "row")}} - - {{mark-favorite id=row.uiOptions.id rowRemoved=(action 'favoriteChanged')}} - - {{row.pretty_provider}} - {{row.uiOptions.zone}} - {{row.uiOptions.displayName}} - {{row.uiOptions.memory}} GB - - {{#if (eq row.uiOptions.transfer -1)}} - Unlimited - {{else if (eq row.uiOptions.transfer 0)}} - None - {{else}} - {{#if (eq row.provider 'amazonec2') }} - {{format-si row.uiOptions.transfer suffix="B" startingExponent=3}} - {{else}} - {{format-si row.uiOptions.transfer suffix="B" startingExponent=4}} - {{/if}} - {{/if}} - - - - - {{format-number row.uiOptions.pricePerMonth style='currency' currency='USD' maximumFractionDigits=2}}{{#if row.uiOptions.variableFees}}{{/if}} - - - {{else if (eq kind "norows")}} - {{t noDataMessage}} - {{/if}} - {{/sortable-table}} -
{{#link-to "hosts.new"}}{{t 'hostsPage.cloudHostsPage.browsePage.table.classic'}}{{/link-to}}
-
{{t 'hostsPage.cloudHostsPage.browsePage.table.help' htmlSafe=true}}
- -