ui/lib/shared/addon/components/cru-node-pools/template.hbs

86 lines
2.7 KiB
Handlebars

{{#sortable-table
classNames="grid"
body=nodePools
suffix=true
search=false
descending=descending
bulkActions=false
rowActions=false
pagingLabel="pagination.nodePool"
headers=headers
as |sortable kind pool dt|
}}
{{#if (eq kind "row")}}
{{node-pool-row
addNodeTemplate=(action "addNodeTemplate")
configAdvancedOptions=(action "configAdvancedOptions")
filteredNodeTemplates=filteredNodeTemplates
pool=pool
removePool=(action "removePool")
dt=dt
mode=mode
}}
{{else if (eq kind "norows")}}
<tr>
<td colspan="{{sortable.fullColspan}}" class="text-center text-muted pt-40 pb-40">
{{t "nodesPage.table.noData"}}
</td>
</tr>
{{else if (eq kind "suffix")}}
<tbody>
<tr class="banner bg-info suffix">
<td colspan="5" class="pl-20 text-bold">
{{t "clusterNew.rke.role.requirements.label"}}
</td>
<td class="text-center {{if etcdOk " text-success" "text-error text-bold" }}">
<i class="icon {{if etcdOk " icon-success" "icon-x-circle" }}"></i>
{{t "clusterNew.rke.role.requirements.etcd"}}
</td>
<td class="text-center {{if controlPlaneOk " text-success" "text-error text-bold" }}">
<i class="icon {{if controlPlaneOk " icon-success" "icon-x-circle" }}"></i>
{{t "clusterNew.rke.role.requirements.controlplane"}}
</td>
<td class="text-center {{if workerOk " text-success" "text-error text-bold" }}">
<i class="icon {{if workerOk " icon-success" "icon-x-circle" }}"></i>
{{t "clusterNew.rke.role.requirements.worker"}}
</td>
<td colspan="{{if (or taintCapabilites (eq mode "new")) "2" "1" }}"></td>
</tr>
</tbody>
{{/if}}
{{/sortable-table}}
{{#if (eq mode "edit")}}
<p class="help-block">{{t "clusterNew.rke.helptext"}}</p>
{{/if}}
{{#if uniqueHostNameError}}
{{#banner-message icon="icon-alert" color="bg-error"}}
<p>{{t "clusterNew.nodePools.errors.hostnamePrefix" }}</p>
{{/banner-message}}
{{/if}}
<div class="mt-20">
<button class="btn bg-primary icon-btn" type="button" {{action "addPool" }}>
<i class="icon icon-plus text-small" />
<span>
{{t "clusterNew.rke.nodes.add"}}
</span>
</button>
</div>
{{#if showIamWarning}}
{{banner-message
icon="icon-alert"
color="bg-warning mb-10"
message=(t "clusterNew.rke.warning.aws.iam")
}}
{{/if}}
{{#if (and (eq mode "edit") (not etcdOk))}}
{{banner-message
icon="icon-alert"
color="bg-warning mb-10"
message=(if (lt etcdCount 1) (t "clusterNew.rke.warning.etcd.noEtcd") (t "clusterNew.rke.warning.etcd.even" count=etcdCount))
}}
{{/if}}