mirror of
https://github.com/status-im/consul.git
synced 2025-01-12 23:05:28 +00:00
be694366a7
* ui: Keep track of existing intentions and use those to save changes Previously we risked overwriting existing data in an intention if we tried to save an intention without having loaded it first, for example Description and Metadata would have been overwritten. This change loads in all the intentions for an origin service so we can pick off the one we need to save and change to ensure that we don't overwrite any existing data.
20 lines
518 B
Handlebars
20 lines
518 B
Handlebars
{{#if (eq @type 'create')}}
|
|
{{#if (eq @status 'success') }}
|
|
Your intention has been added.
|
|
{{else}}
|
|
There was an error adding your intention.
|
|
{{/if}}
|
|
{{else if (eq @type 'update') }}
|
|
{{#if (eq @status 'success') }}
|
|
Your intention has been saved.
|
|
{{else}}
|
|
There was an error saving your intention.
|
|
{{/if}}
|
|
{{/if}}
|
|
{{#let @error.errors.firstObject as |error|}}
|
|
{{#if error.detail }}
|
|
<br />{{concat '(' (if error.status (concat error.status ': ')) error.detail ')'}}
|
|
{{/if}}
|
|
{{/let}}
|
|
|