diff --git a/addons/core/translations/resources/en-us.yaml b/addons/core/translations/resources/en-us.yaml index ff2dce9eb..55b547d0b 100644 --- a/addons/core/translations/resources/en-us.yaml +++ b/addons/core/translations/resources/en-us.yaml @@ -195,6 +195,9 @@ target: messages: welcome: title: Welcome to Targets + none: + title: No Targets Available + description: No Targets to display yet. Contact your Boundary admin if you don't see a Target you expect access to. actions: create: New Target delete: Delete Target diff --git a/ui/desktop/app/templates/scopes/scope/projects/targets/index.hbs b/ui/desktop/app/templates/scopes/scope/projects/targets/index.hbs index b816ced05..bbb3e7b5d 100644 --- a/ui/desktop/app/templates/scopes/scope/projects/targets/index.hbs +++ b/ui/desktop/app/templates/scopes/scope/projects/targets/index.hbs @@ -7,73 +7,87 @@ - - - - {{t "form.name.label"}} - {{t "form.id.label"}} - {{t "form.type.label"}} - {{t "resources.project.title"}} - - - - - {{#each @model as |model|}} - - - - - {{model.target.displayName}} - -

{{model.target.description}}

-
- - - {{model.target.id}} - - - - {{#if model.target.type}} - - {{t (concat "resources.target.types." model.target.type)}} - - {{/if}} - - -
+ {{#if @model}} + + + + + {{t "form.name.label"}} + {{t "form.id.label"}} + {{t "form.type.label"}} + {{t "resources.project.title"}} + + + + + {{#each @model as |model|}} + + + + + {{model.target.displayName}} + +

{{model.target.description}}

+
+ - {{model.project.id}} + {{model.target.id}} -
- - {{model.project.name}} - -
- - - {{t "resources.session.actions.connect"}} - - -
- {{/each}} -
-
+ + + {{#if model.target.type}} + + {{t (concat "resources.target.types." model.target.type)}} + + {{/if}} + + +
+ + {{model.project.id}} + +
+ + {{model.project.name}} + +
+ + + {{t "resources.session.actions.connect"}} + + + + {{/each}} + + + + {{else}} + + + + + {{t "resources.target.messages.none.description"}} + + + + + {{/if}}
diff --git a/ui/desktop/app/templates/scopes/scope/projects/targets/target/hosts.hbs b/ui/desktop/app/templates/scopes/scope/projects/targets/target/hosts.hbs index bb76d5e56..e2cf73f39 100644 --- a/ui/desktop/app/templates/scopes/scope/projects/targets/target/hosts.hbs +++ b/ui/desktop/app/templates/scopes/scope/projects/targets/target/hosts.hbs @@ -1,32 +1,46 @@ {{page-title (t "resources.host-set.title_plural")}} - - - {{#each @model.hosts as |host|}} - - - {{host.displayName}} -

{{host.description}}

-
- - - {{host.id}} - - - {{host.attributes.address}} - - {{t (concat 'resources.host.types.' host.type)}} - - - - {{t "resources.session.actions.connect"}} - - -
- {{/each}} -
-
+{{#if @model.hosts}} + + + + {{#each @model.hosts as |host|}} + + + {{host.displayName}} +

{{host.description}}

+
+ + + {{host.id}} + + + {{host.attributes.address}} + + {{t (concat 'resources.host.types.' host.type)}} + + + + {{t "resources.session.actions.connect"}} + + +
+ {{/each}} +
+
+ +{{else}} + + + + + {{t "resources.host.messages.none.description"}} + + + + +{{/if}} diff --git a/ui/desktop/app/templates/scopes/scope/projects/targets/target/sessions.hbs b/ui/desktop/app/templates/scopes/scope/projects/targets/target/sessions.hbs index 48f10efda..d9edc3900 100644 --- a/ui/desktop/app/templates/scopes/scope/projects/targets/target/sessions.hbs +++ b/ui/desktop/app/templates/scopes/scope/projects/targets/target/sessions.hbs @@ -1,40 +1,54 @@ - - - {{!-- - TODO: sort these via the controller so that active and pending appear first - similar to the way the sessions routes are sorted. - --}} - {{#each @model.target.sessions as |session|}} - - - - - {{session.id}} - - - - - - - {{session.status}} - - - {{#if session.isCancelable}} - - {{t "actions.cancel"}} - - {{/if}} - - - {{/each}} - - +{{#if @model.target.sessions}} + + + + {{!-- + TODO: sort these via the controller so that active and pending appear first + similar to the way the sessions routes are sorted. + --}} + {{#each @model.target.sessions as |session|}} + + + + + {{session.id}} + + + + + + + {{session.status}} + + + {{#if session.isCancelable}} + + {{t "actions.cancel"}} + + {{/if}} + + + {{/each}} + + + +{{else}} + + + + + {{t "resources.session.messages.none.description"}} + + + + +{{/if}} \ No newline at end of file