diff --git a/ui/packages/consul-ui/app/components/consul/intention/notifications/index.hbs b/ui/packages/consul-ui/app/components/consul/intention/notifications/index.hbs
new file mode 100644
index 0000000000..b6921fbe7a
--- /dev/null
+++ b/ui/packages/consul-ui/app/components/consul/intention/notifications/index.hbs
@@ -0,0 +1,24 @@
+{{#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}}
+{{ else if (eq @type 'delete')}}
+ {{#if (eq @status 'success') }}
+ Your intention was deleted.
+ {{else}}
+ There was an error deleting your intention.
+ {{/if}}
+{{/if}}
+{{#let @error.errors.firstObject as |error|}}
+ {{#if error.detail }}
+
{{concat '(' (if error.status (concat error.status ': ')) error.detail ')'}}
+ {{/if}}
+{{/let}}
diff --git a/ui/packages/consul-ui/app/components/hashicorp-consul/index.hbs b/ui/packages/consul-ui/app/components/hashicorp-consul/index.hbs
index 8a7336f9c1..b19f471dbb 100644
--- a/ui/packages/consul-ui/app/components/hashicorp-consul/index.hbs
+++ b/ui/packages/consul-ui/app/components/hashicorp-consul/index.hbs
@@ -39,13 +39,20 @@
There was an error, please check your SecretID/Token
{{/if}}
{{else}}
- {{#if (eq flash.model 'token')}}
+ {{#if (or (eq type 'use') (eq flash.model 'token'))}}
+ {{else if (eq flash.model 'intention')}}
+
{{else if (eq flash.model 'role')}}
this.success(item, action),
- error: e => this.error(e, action),
+ success: item => this.success(item, action, undefined, modelName),
+ error: e => this.error(e, action, undefined, modelName),
};
}
@@ -39,7 +39,7 @@ export default class FeedbackService extends Service {
// here..
action: getAction(),
item: item,
- model: model
+ model: model,
});
}
}
@@ -55,7 +55,7 @@ export default class FeedbackService extends Service {
type: getStatus(TYPE_SUCCESS),
// and here
action: getAction(),
- model: model
+ model: model,
});
} else {
this.notify.add({
@@ -63,7 +63,7 @@ export default class FeedbackService extends Service {
type: getStatus(TYPE_ERROR, e),
action: getAction(),
error: e,
- model: model
+ model: model,
});
}
}