John Cowen 61e3fa3244 Make sure the dc menu is as useful as possible when things go wrong
1. Check the dc's model for both dcs list and the requested dc.
2. If the dc model doesn't exist use and empty array for dcs and a fake
dc with the Name 'Error' as we can't even trust what is in the
`paramsFor`
2018-06-22 17:23:00 +01:00

24 lines
1016 B
Handlebars

{{#hashicorp-consul id="wrapper" dcs=dcs dc=dc}}
{{#app-view class="error show"}}
{{#block-slot 'header'}}
<h1 data-test-error>
{{#if error.status }}
{{error.status}} ({{error.message}})
{{else}}
{{error.message}}
{{/if}}
</h1>
{{/block-slot}}
{{#block-slot 'content'}}
<p>
Consul returned an error.
You may have visited a URL that is loading an unknown resource, so you can try going back to the root.
If your ACL token was not found you can reset it, and then you will be redirected to the settings page to enter a new ACL token.
Try looking in our <a href="{{env 'CONSUL_DOCUMENTATION_URL'}}/index.html" target="_blank">documentation</a>
</p>
<a href={{href-to 'settings'}}>Reset ACL token</a>
<a rel="home" href={{href-to 'index'}}>Go back to root</a>
{{/block-slot}}
{{/app-view}}
{{/hashicorp-consul}}