From 501f7bfd3e5a05aa4e68edd83fcccafa606c5ec0 Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Fri, 25 Sep 2020 12:36:26 -0400 Subject: [PATCH 01/15] refactor: reorg sessions strings --- .../scopes/scope/projects/project/_sidebar.hbs | 2 +- .../scopes/scope/projects/project/sessions.hbs | 2 +- .../scope/projects/project/sessions/index.hbs | 7 ++++--- ui/core/translations/en-us.yaml | 2 -- ui/core/translations/resources/en-us.yaml | 14 +++++++++----- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs b/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs index e29af0451..a3913f3a5 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs @@ -1,6 +1,6 @@ - {{t "resources.sessions"}} + {{t "resources.session.title_plural"}} {{t "resources.targets"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/sessions.hbs b/ui/core/app/templates/scopes/scope/projects/project/sessions.hbs index 37fea125e..f7ffb23d4 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/sessions.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/sessions.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.sessions")}} +{{title (t "resources.session.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs index 587b6a963..af5ee3555 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs @@ -5,7 +5,8 @@ -

{{t "resources.sessions"}}

+

{{t "resources.session.title_plural"}}

+

{{t "resources.session.description"}}

@@ -52,9 +53,9 @@ {{else}} - + - {{t "descriptions.no-sessions"}} + {{t "resources.session.messages.none.description"}} diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index d53d5e4b9..bb991a334 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -47,7 +47,6 @@ titles: members: Members group-members-welcome: Welcome to Members no-available-users: No Users Available - no-sessions: No Active Sessions actions: Actions descriptions: host-catalogs: Overview of collections of hosts and host sets. @@ -68,4 +67,3 @@ descriptions: no-principals-available: Principals are not available for assignment. group-members-welcome: Users belonging to this group appear here. no-available-users: No users are available to add to this group. - no-sessions: There are no active sessions at this time. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 5a1e3ac32..081dc839e 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -23,12 +23,20 @@ auth-method: description: Auth methods are configurations to authenticate users. none: title: No Authentication Methods - description: No authentication methods were found for this scope. Switch scopes and try again. + description: No authentication methods were found for this scope. types: password: Password actions: create: Create Auth Method delete: Delete Auth Method +session: + title: Session + title_plural: Sessions + description: A session is a connection to a target initiated through Boundary. + messages: + none: + title: No Sessions + description: There are no active sessions within the current scope. user: User users: Users role: Role @@ -47,8 +55,6 @@ host: Host hosts: Hosts target: Target targets: Targets -sessions: Sessions -session: Session descriptions: user: A User inherits from Principal ("is-a" Principal) allowing it to be associated with zero or more Roles. users: A user is any entity authorized to access Boundary using authentication credentials specific to one of the configured Authentication Methods. A User is owned by one and only one Organization. A User is associated with zero or one Authentication Methods. A User not associated with an Authentication Method can not log in to the system. A User can belong to zero or more Groups. A User is deleted when the Organization it belongs to is deleted. The lifecycle of a User is not tied to the lifecycle of any Authentication Method, Group or Role, but rather to its Organization only. @@ -70,5 +76,3 @@ descriptions: hosts: A host is a computing element with a network address reachable from Boundary. A Host belongs to one and only one Host Catalog. A Host can be contained by zero or more Host Sets. The lifecycle of a Host is not tied to the lifecycle of any Host Sets. target: Target is abstract. A Target is deleted when the Scope it belongs to is deleted. targets: A target is a networked service a User can connect to and interact with through Boundary. A Target does not directly contain any secrets. A Target contains a collection of Hosts. A Target belongs to one and only one Scope. A Target can contain zero or more Host Sets. The lifecycle of a Target is not tied to the lifecycle of any Host Set. - sessions: Sessions - session: Session From 55b8062ef475a33057c05b01206bffdc8bf695c0 Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Fri, 25 Sep 2020 13:09:16 -0400 Subject: [PATCH 02/15] refactor: reorg group strings --- .../form/group/add-members/index.hbs | 2 +- .../app/controllers/scopes/scope/groups.js | 2 +- .../scopes/scope/groups/group/add-members.js | 2 +- ui/core/app/templates/scopes/scope.hbs | 2 +- ui/core/app/templates/scopes/scope/groups.hbs | 2 +- .../scopes/scope/groups/group/-actions.hbs | 2 +- .../scopes/scope/groups/group/-header.hbs | 4 ++-- .../scopes/scope/groups/group/-navigation.hbs | 2 +- .../scopes/scope/groups/group/add-members.hbs | 2 +- .../groups/group/add-members/-header.hbs | 3 ++- .../scopes/scope/groups/group/members.hbs | 6 +++--- .../templates/scopes/scope/groups/index.hbs | 8 ++++---- ui/core/translations/en-us.yaml | 5 ----- ui/core/translations/resources/en-us.yaml | 19 +++++++++++++++---- 14 files changed, 34 insertions(+), 27 deletions(-) diff --git a/ui/core/app/components/form/group/add-members/index.hbs b/ui/core/app/components/form/group/add-members/index.hbs index 14943ae3f..3f93cdc7a 100644 --- a/ui/core/app/components/form/group/add-members/index.hbs +++ b/ui/core/app/components/form/group/add-members/index.hbs @@ -9,7 +9,7 @@ > diff --git a/ui/core/app/controllers/scopes/scope/groups.js b/ui/core/app/controllers/scopes/scope/groups.js index 000d18739..b77fc8dcc 100644 --- a/ui/core/app/controllers/scopes/scope/groups.js +++ b/ui/core/app/controllers/scopes/scope/groups.js @@ -13,6 +13,6 @@ export default class ScopesScopeGroupsController extends Controller { * @type {string} */ get breadCrumb() { - return this.intl.t('resources.groups'); + return this.intl.t('resources.group.title_plural'); } } diff --git a/ui/core/app/controllers/scopes/scope/groups/group/add-members.js b/ui/core/app/controllers/scopes/scope/groups/group/add-members.js index fc07abb38..6ce53c655 100644 --- a/ui/core/app/controllers/scopes/scope/groups/group/add-members.js +++ b/ui/core/app/controllers/scopes/scope/groups/group/add-members.js @@ -13,6 +13,6 @@ export default class ScopesScopeGroupsGroupAddMembersController extends Controll * @type {string} */ get breadCrumb() { - return this.intl.t('actions.add-members'); + return this.intl.t('resources.group.messages.add-members.title'); } } diff --git a/ui/core/app/templates/scopes/scope.hbs b/ui/core/app/templates/scopes/scope.hbs index 341b098f8..0692adaa0 100644 --- a/ui/core/app/templates/scopes/scope.hbs +++ b/ui/core/app/templates/scopes/scope.hbs @@ -14,7 +14,7 @@ {{t "resources.users"}}
- {{t "resources.groups"}} + {{t "resources.group.title_plural"}} {{t "resources.roles"}} diff --git a/ui/core/app/templates/scopes/scope/groups.hbs b/ui/core/app/templates/scopes/scope/groups.hbs index c53da7f4b..14f6b8561 100644 --- a/ui/core/app/templates/scopes/scope/groups.hbs +++ b/ui/core/app/templates/scopes/scope/groups.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.groups")}} +{{title (t "resources.group.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/groups/group/-actions.hbs b/ui/core/app/templates/scopes/scope/groups/group/-actions.hbs index 1ebd9d2c6..d4a53deb0 100644 --- a/ui/core/app/templates/scopes/scope/groups/group/-actions.hbs +++ b/ui/core/app/templates/scopes/scope/groups/group/-actions.hbs @@ -1,6 +1,6 @@ - {{t "actions.add-members"}} + {{t "resources.group.actions.add-members"}} {{t "resources.group"}} -

{{t "resources.descriptions.group"}}

+

{{t "resources.group.title"}}

+

{{t "resources.group.description"}}

diff --git a/ui/core/app/templates/scopes/scope/groups/group/-navigation.hbs b/ui/core/app/templates/scopes/scope/groups/group/-navigation.hbs index 6dc45b637..43ebee5ef 100644 --- a/ui/core/app/templates/scopes/scope/groups/group/-navigation.hbs +++ b/ui/core/app/templates/scopes/scope/groups/group/-navigation.hbs @@ -3,6 +3,6 @@ {{t 'titles.details'}}
- {{t 'titles.members'}} + {{t 'resources.group.messages.members.title'}} diff --git a/ui/core/app/templates/scopes/scope/groups/group/add-members.hbs b/ui/core/app/templates/scopes/scope/groups/group/add-members.hbs index 6f674b02d..0981d22d7 100644 --- a/ui/core/app/templates/scopes/scope/groups/group/add-members.hbs +++ b/ui/core/app/templates/scopes/scope/groups/group/add-members.hbs @@ -1,4 +1,4 @@ -{{title (t "actions.add-members")}} +{{title (t "resources.group.messages.add-members.title")}} {{t "actions.add-members"}} +

{{t "resources.group.messages.add-members.title"}}

+

{{t "resources.group.messages.add-members.description"}}

diff --git a/ui/core/app/templates/scopes/scope/groups/group/members.hbs b/ui/core/app/templates/scopes/scope/groups/group/members.hbs index 7080c05f1..0b6dee825 100644 --- a/ui/core/app/templates/scopes/scope/groups/group/members.hbs +++ b/ui/core/app/templates/scopes/scope/groups/group/members.hbs @@ -1,4 +1,4 @@ -{{title (t 'titles.members')}} +{{title (t 'resources.group.messages.members.title')}} {{#if @model.members}} @@ -43,9 +43,9 @@ {{else}} - + - {{t "descriptions.group-members-welcome"}} + {{t "resources.group.messages.members.description"}} diff --git a/ui/core/app/templates/scopes/scope/groups/index.hbs b/ui/core/app/templates/scopes/scope/groups/index.hbs index 8b153a923..499e71589 100644 --- a/ui/core/app/templates/scopes/scope/groups/index.hbs +++ b/ui/core/app/templates/scopes/scope/groups/index.hbs @@ -5,8 +5,8 @@ -

{{t "resources.groups"}}

-

{{t "resources.descriptions.groups"}}

+

{{t "resources.group.title_plural"}}

+

{{t "resources.group.description"}}

@@ -49,9 +49,9 @@ {{else}} - + - {{t 'descriptions.groups-welcome'}} + {{t 'resources.group.description'}} diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index bb991a334..ba39b23c4 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -30,7 +30,6 @@ titles: hosts-welcome: Welcome to Hosts users-welcome: Welcome to Users roles-welcome: Welcome to Roles - groups-welcome: Welcome to Groups targets-welcome: Create your first Target target-host-sets-welcome: No Host Sets Associated grants: Permissions @@ -44,8 +43,6 @@ titles: no-host-sets-for-target: No Host Sets Available role-principals-welcome: No Principals Associated no-principals-available: No Principals Available - members: Members - group-members-welcome: Welcome to Members no-available-users: No Users Available actions: Actions descriptions: @@ -58,12 +55,10 @@ descriptions: hosts-welcome: Configure a static host in this host catalog. users-welcome: Users are authorized to access Boundary. roles-welcome: Roles are collections of capabilities that can be granted to user and/or groups. - groups-welcome: Groups are collections of users. targets-welcome: Targets provide Users the means to connect to and interact networked services. A Target contains a collection of Hosts and a collection of Credentials. target-host-sets-welcome: Add Host Sets to this target to provide access. no-host-set-hosts: Before associating hosts with this host set, create hosts within the host catalog. no-host-sets-for-target: No host sets are available to add to this target. role-principals-welcome: No principals are available in this role. no-principals-available: Principals are not available for assignment. - group-members-welcome: Users belonging to this group appear here. no-available-users: No users are available to add to this group. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 081dc839e..e7615fcc3 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -29,6 +29,21 @@ auth-method: actions: create: Create Auth Method delete: Delete Auth Method +group: + title: Group + title_plural: Groups + description: Groups are collections of users. Groups may be assigned to roles, thereby receiving the role's grants. + messages: + welcome: + title: Welcome to Groups + members: + title: Members + description: Members are the users assigned to a group. + add-members: + title: Add Members + description: Select users to add users to this group. + actions: + add-members: Add Members session: title: Session title_plural: Sessions @@ -41,8 +56,6 @@ user: User users: Users role: Role roles: Roles -group: Group -groups: Groups orgs: Orgs org: Org projects: Projects @@ -62,8 +75,6 @@ descriptions: roles: A role is a collection of capabilities granted to any Principal the Role is assigned to. A Role belongs to one and only one Scope. A Role owns zero or more Direct Grants. The lifecycle of a Role is not tied to the lifecycle of any Principal. grants: A grant represents a set of capabilities granted to a role. It couples a set of Actions to either a set of Resource Types or an individual Resource. A Direct Grant belongs exclusively to one and only one Role. However, equivalent Direct Grants may exist across different Roles. A Direct Grant references one or more Actions and either one or more Resource types or one specific Resource. A Direct Grant is deleted when the Role it belongs to is deleted. A Direct Grant is also deleted if it is associated with a specific Resource and that Resource itself is deleted. The lifecycle of a Direct Grant is not tied to the lifecycle of any Action or Resource Type. principals: A principal is any entity which can be assigned capabilities. Principal is abstract. User, Group, and Project are concrete Principals. A Principal can be assigned to zero or more Roles. - group: All Users in a Group are granted the capabilities of all Roles the Group is associated with. A Group is deleted when the Scope it belongs to is deleted. - groups: Groups are collections of Users used only for access control purposes. A Group is owned by one and only one Scope. A Group can contain zero or more Users. A Group inherits from Principal ("is-a" Principal) allowing it to be associated with zero or more Roles. The lifecycle of a Group is not tied to the lifecycle of any User or Role. org: When an Organization is deleted, all resources owned by it are also deleted. orgs: An Organization is a top-level container, and owns zero to many Projects and zero to many Authentication Methods. An Organization inherits from Scope ("is-a" Scope) allowing it to own zero to many Groups, Roles, Targets, or Host Catalogs. The lifecycle of an Organization is not tied to anything else. A Role at the Organization level can grant permissions at the Project level. project: When a Project is deleted, all resources owned by it are also deleted. The lifecycle of a Project is not tied to any resource it contains. From 11bbf357ca8d6c5779ff3a94cb0a7f403f434a80 Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Fri, 25 Sep 2020 13:23:36 -0400 Subject: [PATCH 03/15] refactor: reorg host catalog strings --- .../components/form/target/add-host-sets/index.hbs | 2 +- .../scopes/scope/projects/project/host-catalogs.js | 2 +- .../scopes/scope/projects/project/_sidebar.hbs | 2 +- .../scopes/scope/projects/project/host-catalogs.hbs | 2 +- .../projects/project/host-catalogs/host-catalog.hbs | 2 ++ .../project/host-catalogs/host-catalog/-header.hbs | 4 ++-- .../scope/projects/project/host-catalogs/index.hbs | 8 ++++---- ui/core/translations/en-us.yaml | 3 --- ui/core/translations/resources/en-us.yaml | 11 +++++++---- 9 files changed, 19 insertions(+), 17 deletions(-) diff --git a/ui/core/app/components/form/target/add-host-sets/index.hbs b/ui/core/app/components/form/target/add-host-sets/index.hbs index 46fc66308..5ad080dee 100644 --- a/ui/core/app/components/form/target/add-host-sets/index.hbs +++ b/ui/core/app/components/form/target/add-host-sets/index.hbs @@ -17,7 +17,7 @@ {{t 'form.id.label'}} {{t 'form.name.label'}} {{t 'form.type.label'}} - {{t 'resources.host-catalog'}} + {{t 'resources.host-catalog.title_plural'}} diff --git a/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs.js b/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs.js index e323437e8..5e90268a0 100644 --- a/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs.js +++ b/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs.js @@ -12,6 +12,6 @@ export default class ScopesScopeProjectsProjectHostCatalogsController extends Co * @type {string} */ get breadCrumb() { - return this.intl.t('resources.host-catalogs'); + return this.intl.t('resources.host-catalog.title_plural'); } } diff --git a/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs b/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs index a3913f3a5..30441e047 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs @@ -6,6 +6,6 @@ {{t "resources.targets"}} - {{t "resources.host-catalogs"}} + {{t "resources.host-catalog.title_plural"}}
diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs.hbs index 6ad0035fb..abbb6702e 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.host-catalogs")}} +{{title (t "resources.host-catalog.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog.hbs index e9bdb8c81..271a98d73 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog.hbs @@ -1,3 +1,5 @@ +{{title @model.displayName}} + diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-header.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-header.hbs index 655ecb273..65dddb9f1 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-header.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-header.hbs @@ -1,2 +1,2 @@ -

{{t "resources.host-catalog"}}

-

{{t "resources.descriptions.host-catalog"}}

\ No newline at end of file +

{{t "resources.host-catalog.title"}}

+

{{t "resources.host-catalog.description"}}

diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs index dda201a70..e19459843 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs @@ -5,8 +5,8 @@
-

{{t "resources.host-catalogs"}}

-

{{t "resources.descriptions.host-catalogs"}}

+

{{t "resources.host-catalog.title_plural"}}

+

{{t "resources.host-catalog.description"}}

@@ -57,9 +57,9 @@ {{else}} - + - {{t "descriptions.host-catalogs-welcome"}} + {{t "resources.host-catalog.description"}} diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index ba39b23c4..815f6cdc2 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -25,7 +25,6 @@ titles: empty-set: No Items Yet orgs-welcome: Welcome to Orgs projects-welcome: Welcome to Projects - host-catalogs-welcome: Welcome to Host Catalogs host-sets-welcome: Welcome to Host Sets hosts-welcome: Welcome to Hosts users-welcome: Welcome to Users @@ -46,11 +45,9 @@ titles: no-available-users: No Users Available actions: Actions descriptions: - host-catalogs: Overview of collections of hosts and host sets. empty-set: There are no items to display yet. You may be able to add items or try back later. orgs-welcome: Create your orgs here. projects-welcome: Projects allow you to create and manage host catalogs. To start, create a project. - host-catalogs-welcome: Host catalogs allow you to configure to collect and create hosts and host sets. To start, create a host catalog. host-sets-welcome: Configure a static host set in this host catalog. hosts-welcome: Configure a static host in this host catalog. users-welcome: Users are authorized to access Boundary. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index e7615fcc3..921c15124 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -44,6 +44,13 @@ group: description: Select users to add users to this group. actions: add-members: Add Members +host-catalog: + title: Host Catalog + title_plural: Host Catalogs + description: A host catalog is a collection of hosts and host sets. + messages: + welcome: + title: Welcome to Host Catalogs session: title: Session title_plural: Sessions @@ -60,8 +67,6 @@ orgs: Orgs org: Org projects: Projects project: Project -host-catalog: Host Catalog -host-catalogs: Host Catalogs host-set: Host Set host-sets: Host Sets host: Host @@ -79,8 +84,6 @@ descriptions: orgs: An Organization is a top-level container, and owns zero to many Projects and zero to many Authentication Methods. An Organization inherits from Scope ("is-a" Scope) allowing it to own zero to many Groups, Roles, Targets, or Host Catalogs. The lifecycle of an Organization is not tied to anything else. A Role at the Organization level can grant permissions at the Project level. project: When a Project is deleted, all resources owned by it are also deleted. The lifecycle of a Project is not tied to any resource it contains. projects: A project is a child scope of an organization and is owned by an Organization. A Project inherits from Scope ("is-a" Scope) allowing it to own zero to many Groups, Roles, Targets, or Host Catalogs. A Project also inherits from Principal ("is-a" Principal) allowing it to be associated with zero or more Roles. A Project has no additional relationships beyond those defined in Scope and Principal. A Project is deleted when the Organization it belongs to is deleted. - host-catalog: A host catalog is a permission boundary modeled as a container. - host-catalogs: A host catalog is a permission boundary modeled as a container. host-set: Host Set is abstract. A Host Set is deleted when the Host Catalog it belongs to is deleted. host-sets: A host set is a resource which provides a subset of Hosts from the set of Hosts of the Host Catalog it belongs to. A Host Set belongs to one and only one Host Catalog. A Host Set can contain zero or more Hosts. A Host Set can be contained by zero or more Targets. The lifecycle of a Host Set is not tied to the lifecycle of any Targets or Hosts. host: Host is abstract. A Host is deleted when the Host Catalog it belongs to is deleted. From d207b4f7d2016b7a184488a1f29a0f66f956fa2e Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 16:59:50 -0400 Subject: [PATCH 04/15] refactor: update org translations --- ui/core/app/controllers/scopes/scope/orgs.js | 2 +- ui/core/app/templates/scopes/scope/orgs.hbs | 2 +- ui/core/app/templates/scopes/scope/orgs/index.hbs | 10 ++++++---- ui/core/translations/en-us.yaml | 2 -- ui/core/translations/resources/en-us.yaml | 14 ++++++++++---- 5 files changed, 18 insertions(+), 12 deletions(-) diff --git a/ui/core/app/controllers/scopes/scope/orgs.js b/ui/core/app/controllers/scopes/scope/orgs.js index 9e553d5a3..d52189e5f 100644 --- a/ui/core/app/controllers/scopes/scope/orgs.js +++ b/ui/core/app/controllers/scopes/scope/orgs.js @@ -12,6 +12,6 @@ export default class ScopesScopeOrgsController extends Controller { * @type {string} */ get breadCrumb() { - return this.intl.t('resources.orgs'); + return this.intl.t('resources.org.title_plural'); } } diff --git a/ui/core/app/templates/scopes/scope/orgs.hbs b/ui/core/app/templates/scopes/scope/orgs.hbs index 35fbae66b..0f9dd522a 100644 --- a/ui/core/app/templates/scopes/scope/orgs.hbs +++ b/ui/core/app/templates/scopes/scope/orgs.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.orgs")}} +{{title (t "resources.org.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/orgs/index.hbs b/ui/core/app/templates/scopes/scope/orgs/index.hbs index 10b4f04a9..ed79b4e04 100644 --- a/ui/core/app/templates/scopes/scope/orgs/index.hbs +++ b/ui/core/app/templates/scopes/scope/orgs/index.hbs @@ -5,8 +5,10 @@ -

{{t "resources.orgs"}}

-

{{t "resources.descriptions.orgs"}}

+

{{t "resources.org.title_plural"}}

+ {{#if @model}} +

{{t "resources.org.description"}}

+ {{/if}}
@@ -39,9 +41,9 @@ {{else}} - + - {{t 'descriptions.orgs-welcome'}} + {{t 'resources.org.description'}} diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index 815f6cdc2..fea6094ff 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -23,7 +23,6 @@ titles: overview: Overview settings: Settings empty-set: No Items Yet - orgs-welcome: Welcome to Orgs projects-welcome: Welcome to Projects host-sets-welcome: Welcome to Host Sets hosts-welcome: Welcome to Hosts @@ -46,7 +45,6 @@ titles: actions: Actions descriptions: empty-set: There are no items to display yet. You may be able to add items or try back later. - orgs-welcome: Create your orgs here. projects-welcome: Projects allow you to create and manage host catalogs. To start, create a project. host-sets-welcome: Configure a static host set in this host catalog. hosts-welcome: Configure a static host in this host catalog. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 921c15124..534ac93ac 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -59,12 +59,20 @@ session: none: title: No Sessions description: There are no active sessions within the current scope. +org: + title: Organization + title_plural: Organizations + description: An organization is a type of scope used to organize projects and IAM resources. Organizations contain projects and is a child scope of global. + messages: + welcome: + title: Welcome to Organizations + none: + title: No Sessions + description: There are no active sessions within the current scope. user: User users: Users role: Role roles: Roles -orgs: Orgs -org: Org projects: Projects project: Project host-set: Host Set @@ -80,8 +88,6 @@ descriptions: roles: A role is a collection of capabilities granted to any Principal the Role is assigned to. A Role belongs to one and only one Scope. A Role owns zero or more Direct Grants. The lifecycle of a Role is not tied to the lifecycle of any Principal. grants: A grant represents a set of capabilities granted to a role. It couples a set of Actions to either a set of Resource Types or an individual Resource. A Direct Grant belongs exclusively to one and only one Role. However, equivalent Direct Grants may exist across different Roles. A Direct Grant references one or more Actions and either one or more Resource types or one specific Resource. A Direct Grant is deleted when the Role it belongs to is deleted. A Direct Grant is also deleted if it is associated with a specific Resource and that Resource itself is deleted. The lifecycle of a Direct Grant is not tied to the lifecycle of any Action or Resource Type. principals: A principal is any entity which can be assigned capabilities. Principal is abstract. User, Group, and Project are concrete Principals. A Principal can be assigned to zero or more Roles. - org: When an Organization is deleted, all resources owned by it are also deleted. - orgs: An Organization is a top-level container, and owns zero to many Projects and zero to many Authentication Methods. An Organization inherits from Scope ("is-a" Scope) allowing it to own zero to many Groups, Roles, Targets, or Host Catalogs. The lifecycle of an Organization is not tied to anything else. A Role at the Organization level can grant permissions at the Project level. project: When a Project is deleted, all resources owned by it are also deleted. The lifecycle of a Project is not tied to any resource it contains. projects: A project is a child scope of an organization and is owned by an Organization. A Project inherits from Scope ("is-a" Scope) allowing it to own zero to many Groups, Roles, Targets, or Host Catalogs. A Project also inherits from Principal ("is-a" Principal) allowing it to be associated with zero or more Roles. A Project has no additional relationships beyond those defined in Scope and Principal. A Project is deleted when the Organization it belongs to is deleted. host-set: Host Set is abstract. A Host Set is deleted when the Host Catalog it belongs to is deleted. From a94d32b30818a078cc1edfbb4a84d30f0044a79a Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 17:11:30 -0400 Subject: [PATCH 05/15] refactor: update project translations --- ui/core/app/controllers/scopes/scope/projects.js | 2 +- ui/core/app/templates/scopes/scope.hbs | 2 +- ui/core/app/templates/scopes/scope/projects.hbs | 2 +- .../app/templates/scopes/scope/projects/index.hbs | 10 ++++++---- .../scopes/scope/projects/project/index.hbs | 4 ++-- ui/core/translations/en-us.yaml | 2 -- ui/core/translations/resources/en-us.yaml | 14 +++++++------- 7 files changed, 18 insertions(+), 18 deletions(-) diff --git a/ui/core/app/controllers/scopes/scope/projects.js b/ui/core/app/controllers/scopes/scope/projects.js index af28cf813..fb93923df 100644 --- a/ui/core/app/controllers/scopes/scope/projects.js +++ b/ui/core/app/controllers/scopes/scope/projects.js @@ -12,6 +12,6 @@ export default class ScopesScopeProjectsController extends Controller { * @type {string} */ get breadCrumb() { - return this.intl.t('resources.projects'); + return this.intl.t('resources.project.title_plural'); } } diff --git a/ui/core/app/templates/scopes/scope.hbs b/ui/core/app/templates/scopes/scope.hbs index 0692adaa0..1cf097811 100644 --- a/ui/core/app/templates/scopes/scope.hbs +++ b/ui/core/app/templates/scopes/scope.hbs @@ -5,7 +5,7 @@ - {{t "resources.projects"}} + {{t "resources.project.title_plural"}} diff --git a/ui/core/app/templates/scopes/scope/projects.hbs b/ui/core/app/templates/scopes/scope/projects.hbs index 1f709c7f7..dd40ba6c8 100644 --- a/ui/core/app/templates/scopes/scope/projects.hbs +++ b/ui/core/app/templates/scopes/scope/projects.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.projects")}} +{{title (t "resources.project.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/projects/index.hbs b/ui/core/app/templates/scopes/scope/projects/index.hbs index 9c5ae805a..0d05ddf30 100644 --- a/ui/core/app/templates/scopes/scope/projects/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/index.hbs @@ -5,8 +5,10 @@ -

{{t "resources.projects"}}

-

{{t "resources.descriptions.projects"}}

+

{{t "resources.project.title_plural"}}

+ {{#if @model}} +

{{t "resources.project.description"}}

+ {{/if}}
@@ -39,9 +41,9 @@ {{else}} - + - {{t 'descriptions.projects-welcome'}} + {{t 'resources.project.description'}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/index.hbs index 243ef1276..3990c70e8 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/index.hbs @@ -5,8 +5,8 @@ -

{{t "resources.project"}}

-

{{t "resources.descriptions.project"}}

+

{{t "resources.project.title"}}

+

{{t "resources.project.description"}}

diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index fea6094ff..500c14ff4 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -23,7 +23,6 @@ titles: overview: Overview settings: Settings empty-set: No Items Yet - projects-welcome: Welcome to Projects host-sets-welcome: Welcome to Host Sets hosts-welcome: Welcome to Hosts users-welcome: Welcome to Users @@ -45,7 +44,6 @@ titles: actions: Actions descriptions: empty-set: There are no items to display yet. You may be able to add items or try back later. - projects-welcome: Projects allow you to create and manage host catalogs. To start, create a project. host-sets-welcome: Configure a static host set in this host catalog. hosts-welcome: Configure a static host in this host catalog. users-welcome: Users are authorized to access Boundary. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 534ac93ac..22c7be5aa 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -66,15 +66,17 @@ org: messages: welcome: title: Welcome to Organizations - none: - title: No Sessions - description: There are no active sessions within the current scope. +project: + title: Project + title_plural: Projects + description: A project is a type of scope used to organize resources such as by targets and host catalogs. + messages: + welcome: + title: Welcome to Projects user: User users: Users role: Role roles: Roles -projects: Projects -project: Project host-set: Host Set host-sets: Host Sets host: Host @@ -88,8 +90,6 @@ descriptions: roles: A role is a collection of capabilities granted to any Principal the Role is assigned to. A Role belongs to one and only one Scope. A Role owns zero or more Direct Grants. The lifecycle of a Role is not tied to the lifecycle of any Principal. grants: A grant represents a set of capabilities granted to a role. It couples a set of Actions to either a set of Resource Types or an individual Resource. A Direct Grant belongs exclusively to one and only one Role. However, equivalent Direct Grants may exist across different Roles. A Direct Grant references one or more Actions and either one or more Resource types or one specific Resource. A Direct Grant is deleted when the Role it belongs to is deleted. A Direct Grant is also deleted if it is associated with a specific Resource and that Resource itself is deleted. The lifecycle of a Direct Grant is not tied to the lifecycle of any Action or Resource Type. principals: A principal is any entity which can be assigned capabilities. Principal is abstract. User, Group, and Project are concrete Principals. A Principal can be assigned to zero or more Roles. - project: When a Project is deleted, all resources owned by it are also deleted. The lifecycle of a Project is not tied to any resource it contains. - projects: A project is a child scope of an organization and is owned by an Organization. A Project inherits from Scope ("is-a" Scope) allowing it to own zero to many Groups, Roles, Targets, or Host Catalogs. A Project also inherits from Principal ("is-a" Principal) allowing it to be associated with zero or more Roles. A Project has no additional relationships beyond those defined in Scope and Principal. A Project is deleted when the Organization it belongs to is deleted. host-set: Host Set is abstract. A Host Set is deleted when the Host Catalog it belongs to is deleted. host-sets: A host set is a resource which provides a subset of Hosts from the set of Hosts of the Host Catalog it belongs to. A Host Set belongs to one and only one Host Catalog. A Host Set can contain zero or more Hosts. A Host Set can be contained by zero or more Targets. The lifecycle of a Host Set is not tied to the lifecycle of any Targets or Hosts. host: Host is abstract. A Host is deleted when the Host Catalog it belongs to is deleted. From 1c7dbb2a51ca869e1389832b11be3aab783e1fa8 Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 17:18:20 -0400 Subject: [PATCH 06/15] refactor: update user translations --- ui/core/app/controllers/scopes/scope/users.js | 2 +- ui/core/app/templates/scopes/scope.hbs | 2 +- ui/core/app/templates/scopes/scope/users.hbs | 2 +- ui/core/app/templates/scopes/scope/users/index.hbs | 10 ++++++---- .../app/templates/scopes/scope/users/user/index.hbs | 4 ++-- ui/core/translations/en-us.yaml | 2 -- ui/core/translations/resources/en-us.yaml | 11 +++++++---- 7 files changed, 18 insertions(+), 15 deletions(-) diff --git a/ui/core/app/controllers/scopes/scope/users.js b/ui/core/app/controllers/scopes/scope/users.js index c88b342fc..72e7bd537 100644 --- a/ui/core/app/controllers/scopes/scope/users.js +++ b/ui/core/app/controllers/scopes/scope/users.js @@ -13,6 +13,6 @@ export default class ScopesScopeUsersController extends Controller { * @type {string} */ get breadCrumb() { - return this.intl.t('resources.users'); + return this.intl.t('resources.user.title_plural'); } } diff --git a/ui/core/app/templates/scopes/scope.hbs b/ui/core/app/templates/scopes/scope.hbs index 1cf097811..5c94400c2 100644 --- a/ui/core/app/templates/scopes/scope.hbs +++ b/ui/core/app/templates/scopes/scope.hbs @@ -11,7 +11,7 @@ - {{t "resources.users"}} + {{t "resources.user.title_plural"}} {{t "resources.group.title_plural"}} diff --git a/ui/core/app/templates/scopes/scope/users.hbs b/ui/core/app/templates/scopes/scope/users.hbs index 67ccbeb9e..f6ecdfa99 100644 --- a/ui/core/app/templates/scopes/scope/users.hbs +++ b/ui/core/app/templates/scopes/scope/users.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.users")}} +{{title (t "resources.user.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/users/index.hbs b/ui/core/app/templates/scopes/scope/users/index.hbs index 8ecec771c..26458d273 100644 --- a/ui/core/app/templates/scopes/scope/users/index.hbs +++ b/ui/core/app/templates/scopes/scope/users/index.hbs @@ -5,8 +5,10 @@ -

{{t "resources.users"}}

-

{{t "resources.descriptions.users"}}

+

{{t "resources.user.title_plural"}}

+ {{#if @model}} +

{{t "resources.user.description"}}

+ {{/if}}
@@ -49,9 +51,9 @@ {{else}} - + - {{t 'descriptions.users-welcome'}} + {{t 'resources.user.description'}} diff --git a/ui/core/app/templates/scopes/scope/users/user/index.hbs b/ui/core/app/templates/scopes/scope/users/user/index.hbs index a57e6f8eb..198efa389 100644 --- a/ui/core/app/templates/scopes/scope/users/user/index.hbs +++ b/ui/core/app/templates/scopes/scope/users/user/index.hbs @@ -5,8 +5,8 @@ -

{{t "resources.user"}}

-

{{t "resources.descriptions.user"}}

+

{{t "resources.user.title"}}

+

{{t "resources.user.description"}}

diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index 500c14ff4..a158daeb8 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -25,7 +25,6 @@ titles: empty-set: No Items Yet host-sets-welcome: Welcome to Host Sets hosts-welcome: Welcome to Hosts - users-welcome: Welcome to Users roles-welcome: Welcome to Roles targets-welcome: Create your first Target target-host-sets-welcome: No Host Sets Associated @@ -46,7 +45,6 @@ descriptions: empty-set: There are no items to display yet. You may be able to add items or try back later. host-sets-welcome: Configure a static host set in this host catalog. hosts-welcome: Configure a static host in this host catalog. - users-welcome: Users are authorized to access Boundary. roles-welcome: Roles are collections of capabilities that can be granted to user and/or groups. targets-welcome: Targets provide Users the means to connect to and interact networked services. A Target contains a collection of Hosts and a collection of Credentials. target-host-sets-welcome: Add Host Sets to this target to provide access. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 22c7be5aa..a0c4df6c7 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -73,8 +73,13 @@ project: messages: welcome: title: Welcome to Projects -user: User -users: Users +user: + title: User + title_plural: Users + description: Users are entities authorized to access Boundary. Users may be assigned to roles as principals, thus receiving role grants. + messages: + welcome: + title: Welcome to Users role: Role roles: Roles host-set: Host Set @@ -84,8 +89,6 @@ hosts: Hosts target: Target targets: Targets descriptions: - user: A User inherits from Principal ("is-a" Principal) allowing it to be associated with zero or more Roles. - users: A user is any entity authorized to access Boundary using authentication credentials specific to one of the configured Authentication Methods. A User is owned by one and only one Organization. A User is associated with zero or one Authentication Methods. A User not associated with an Authentication Method can not log in to the system. A User can belong to zero or more Groups. A User is deleted when the Organization it belongs to is deleted. The lifecycle of a User is not tied to the lifecycle of any Authentication Method, Group or Role, but rather to its Organization only. role: A Role can be assigned to zero or more Principals. A Principal assigned a Role receives all capabilities granted by any Direct Grant owned by the Role. A Role is deleted when the Scope it belongs to is deleted. All Direct Grants owned by a Role are deleted when the Role is deleted. roles: A role is a collection of capabilities granted to any Principal the Role is assigned to. A Role belongs to one and only one Scope. A Role owns zero or more Direct Grants. The lifecycle of a Role is not tied to the lifecycle of any Principal. grants: A grant represents a set of capabilities granted to a role. It couples a set of Actions to either a set of Resource Types or an individual Resource. A Direct Grant belongs exclusively to one and only one Role. However, equivalent Direct Grants may exist across different Roles. A Direct Grant references one or more Actions and either one or more Resource types or one specific Resource. A Direct Grant is deleted when the Role it belongs to is deleted. A Direct Grant is also deleted if it is associated with a specific Resource and that Resource itself is deleted. The lifecycle of a Direct Grant is not tied to the lifecycle of any Action or Resource Type. From 8d578e3af9c65cc3ae79cd434db8beb52590487d Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 18:27:14 -0400 Subject: [PATCH 07/15] refactor: Update role, grants, & permissions translations --- .../form/role/add-principals/index.hbs | 6 +-- .../app/components/form/role/grants/index.hbs | 2 +- ui/core/app/controllers/scopes/scope/roles.js | 2 +- .../scopes/scope/roles/role/add-principals.js | 2 +- ui/core/app/templates/scopes/scope.hbs | 2 +- ui/core/app/templates/scopes/scope/roles.hbs | 2 +- .../templates/scopes/scope/roles/index.hbs | 10 +++-- .../scopes/scope/roles/role/-actions.hbs | 4 +- .../scopes/scope/roles/role/-header.hbs | 4 +- .../scopes/scope/roles/role/-navigation.hbs | 4 +- .../scope/roles/role/add-principals.hbs | 2 +- .../roles/role/add-principals/-header.hbs | 3 +- .../scopes/scope/roles/role/grants.hbs | 2 +- .../scope/roles/role/grants/-header.hbs | 4 +- .../scopes/scope/roles/role/principals.hbs | 12 ++++-- .../scope/roles/role/principals/-header.hbs | 4 +- ui/core/translations/en-us.yaml | 9 ---- ui/core/translations/resources/en-us.yaml | 41 ++++++++++++++++--- 18 files changed, 71 insertions(+), 44 deletions(-) diff --git a/ui/core/app/components/form/role/add-principals/index.hbs b/ui/core/app/components/form/role/add-principals/index.hbs index 29e1a460c..0787766ab 100644 --- a/ui/core/app/components/form/role/add-principals/index.hbs +++ b/ui/core/app/components/form/role/add-principals/index.hbs @@ -31,7 +31,7 @@ {{principal.name}} - {{t (concat 'resources.' principal.constructor.modelName)}} + {{t (concat 'resources.role.principal.types.' principal.constructor.modelName)}} {{/each}} @@ -43,9 +43,9 @@ {{#unless this.hasAvailablePrincipals}} - + - {{t "descriptions.no-principals-available"}} + {{t "resources.role.principal.messages.none.description"}} diff --git a/ui/core/app/components/form/role/grants/index.hbs b/ui/core/app/components/form/role/grants/index.hbs index d4fc71207..8b5e97f28 100644 --- a/ui/core/app/components/form/role/grants/index.hbs +++ b/ui/core/app/components/form/role/grants/index.hbs @@ -14,7 +14,7 @@ @value={{this.newGrantString}} as |input|> - {{t "titles.new-grant"}} + {{t "resources.role.grant.actions.create"}} diff --git a/ui/core/app/controllers/scopes/scope/roles.js b/ui/core/app/controllers/scopes/scope/roles.js index bbd84249e..ec27b87ca 100644 --- a/ui/core/app/controllers/scopes/scope/roles.js +++ b/ui/core/app/controllers/scopes/scope/roles.js @@ -13,6 +13,6 @@ export default class ScopesScopeRolesController extends Controller { * @type {string} */ get breadCrumb() { - return this.intl.t('resources.roles'); + return this.intl.t('resources.role.title_plural'); } } diff --git a/ui/core/app/controllers/scopes/scope/roles/role/add-principals.js b/ui/core/app/controllers/scopes/scope/roles/role/add-principals.js index 1d64b6362..48dc430b0 100644 --- a/ui/core/app/controllers/scopes/scope/roles/role/add-principals.js +++ b/ui/core/app/controllers/scopes/scope/roles/role/add-principals.js @@ -13,6 +13,6 @@ export default class ScopesScopeRolesRoleAddPrincipalsController extends Control * @type {string} */ get breadCrumb() { - return this.intl.t('actions.add-principals'); + return this.intl.t('resources.role.principal.actions.add-principals'); } } diff --git a/ui/core/app/templates/scopes/scope.hbs b/ui/core/app/templates/scopes/scope.hbs index 5c94400c2..04b437e4d 100644 --- a/ui/core/app/templates/scopes/scope.hbs +++ b/ui/core/app/templates/scopes/scope.hbs @@ -17,7 +17,7 @@ {{t "resources.group.title_plural"}}
- {{t "resources.roles"}} + {{t "resources.role.title_plural"}} {{t "resources.auth-method.title_plural"}} diff --git a/ui/core/app/templates/scopes/scope/roles.hbs b/ui/core/app/templates/scopes/scope/roles.hbs index 6d511b7f7..05a8f7a37 100644 --- a/ui/core/app/templates/scopes/scope/roles.hbs +++ b/ui/core/app/templates/scopes/scope/roles.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.roles")}} +{{title (t "resources.role.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/roles/index.hbs b/ui/core/app/templates/scopes/scope/roles/index.hbs index cf9ae52ca..588970e37 100644 --- a/ui/core/app/templates/scopes/scope/roles/index.hbs +++ b/ui/core/app/templates/scopes/scope/roles/index.hbs @@ -5,8 +5,10 @@ -

{{t "resources.roles"}}

-

{{t "resources.descriptions.roles"}}

+

{{t "resources.role.title_plural"}}

+ {{#if @model}} +

{{t "resources.role.description"}}

+ {{/if}}
@@ -49,9 +51,9 @@ {{else}} - + - {{t 'descriptions.roles-welcome'}} + {{t 'resources.role.description'}} diff --git a/ui/core/app/templates/scopes/scope/roles/role/-actions.hbs b/ui/core/app/templates/scopes/scope/roles/role/-actions.hbs index 576a6a8fb..073f082db 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/-actions.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/-actions.hbs @@ -1,12 +1,12 @@ - {{t 'actions.add-principals'}} + {{t 'resources.role.principal.actions.add-principals'}} - {{t 'actions.delete-role'}} + {{t 'resources.role.actions.delete'}} diff --git a/ui/core/app/templates/scopes/scope/roles/role/-header.hbs b/ui/core/app/templates/scopes/scope/roles/role/-header.hbs index 96ed6300a..93f645dfa 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/-header.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/-header.hbs @@ -1,2 +1,2 @@ -

{{t "resources.role"}}

-

{{t "resources.descriptions.role"}}

+

{{t "resources.role.title"}}

+

{{t "resources.role.description"}}

diff --git a/ui/core/app/templates/scopes/scope/roles/role/-navigation.hbs b/ui/core/app/templates/scopes/scope/roles/role/-navigation.hbs index 5498f5733..023542087 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/-navigation.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/-navigation.hbs @@ -3,9 +3,9 @@ {{t 'titles.settings'}}
- {{t 'titles.principals'}} + {{t 'resources.role.principal.title_plural'}} - {{t 'titles.grants'}} + {{t 'resources.role.grant.title_plural'}} diff --git a/ui/core/app/templates/scopes/scope/roles/role/add-principals.hbs b/ui/core/app/templates/scopes/scope/roles/role/add-principals.hbs index 5110dbec0..afe17ef59 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/add-principals.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/add-principals.hbs @@ -1,4 +1,4 @@ -{{title (t "actions.add-principals")}} +{{title (t "resources.role.principal.actions.add-principals")}} {{t "actions.add-principals"}} \ No newline at end of file +

{{t "resources.role.principal.messages.add-principals.title"}}

+

{{t "resources.role.principal.messages.add-principals.description"}}

\ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/roles/role/grants.hbs b/ui/core/app/templates/scopes/scope/roles/role/grants.hbs index edb0faf13..9551c3614 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/grants.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/grants.hbs @@ -1,4 +1,4 @@ -{{title (t 'titles.grants')}} +{{title (t 'resources.role.grant.title_plural')}} {{t "resources.role"}} -

{{t "resources.descriptions.grants"}}

+

{{t "resources.role.title"}}

+

{{t "resources.role.grant.description"}}

diff --git a/ui/core/app/templates/scopes/scope/roles/role/principals.hbs b/ui/core/app/templates/scopes/scope/roles/role/principals.hbs index 2acc62cd0..5d6b375fd 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/principals.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/principals.hbs @@ -1,4 +1,4 @@ -{{title (t 'titles.principals')}} +{{title (t 'resources.role.principal.title_plural')}} {{#if @model}} @@ -18,7 +18,7 @@ {{principal.model.displayName}} - {{t (concat 'resources.' principal.type)}} + {{t (concat 'resources.role.principal.types.' principal.type)}} {{principal.model.id}} @@ -47,10 +47,14 @@ {{else}} - + - {{t "descriptions.role-principals-welcome"}} + {{t "resources.role.principal.messages.welcome.description"}} + + + {{t 'resources.role.principal.actions.add-principals'}} + diff --git a/ui/core/app/templates/scopes/scope/roles/role/principals/-header.hbs b/ui/core/app/templates/scopes/scope/roles/role/principals/-header.hbs index a549d9a8b..9d7156902 100644 --- a/ui/core/app/templates/scopes/scope/roles/role/principals/-header.hbs +++ b/ui/core/app/templates/scopes/scope/roles/role/principals/-header.hbs @@ -1,2 +1,2 @@ -

{{t "resources.role"}}

-

{{t "resources.descriptions.principals"}}

+

{{t "resources.role.title"}}

+

{{t "resources.role.principal.description"}}

diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index a158daeb8..6561047d6 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -25,31 +25,22 @@ titles: empty-set: No Items Yet host-sets-welcome: Welcome to Host Sets hosts-welcome: Welcome to Hosts - roles-welcome: Welcome to Roles targets-welcome: Create your first Target target-host-sets-welcome: No Host Sets Associated - grants: Permissions - new-grant: New Grant - principals: Principals host-sets: Host Sets hosts: Hosts targets: Targets global: Global no-host-set-hosts: No Hosts Available no-host-sets-for-target: No Host Sets Available - role-principals-welcome: No Principals Associated - no-principals-available: No Principals Available no-available-users: No Users Available actions: Actions descriptions: empty-set: There are no items to display yet. You may be able to add items or try back later. host-sets-welcome: Configure a static host set in this host catalog. hosts-welcome: Configure a static host in this host catalog. - roles-welcome: Roles are collections of capabilities that can be granted to user and/or groups. targets-welcome: Targets provide Users the means to connect to and interact networked services. A Target contains a collection of Hosts and a collection of Credentials. target-host-sets-welcome: Add Host Sets to this target to provide access. no-host-set-hosts: Before associating hosts with this host set, create hosts within the host catalog. no-host-sets-for-target: No host sets are available to add to this target. - role-principals-welcome: No principals are available in this role. - no-principals-available: Principals are not available for assignment. no-available-users: No users are available to add to this group. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index a0c4df6c7..1c1287707 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -80,8 +80,41 @@ user: messages: welcome: title: Welcome to Users -role: Role -roles: Roles +role: + title: Role + title_plural: Roles + description: Roles are collections of capability grants and the principals (users and groups) assigned to them. + messages: + welcome: + title: Welcome to Roles + actions: + create: Create Role + delete: Delete Role + principal: + title: Principal + title_plural: Principals + description: Principals are the users and groups assigned to a role and bounded by a role’s grants. + messages: + welcome: + title: Welcome to Principals + description: Principals are not assigned in this role. + none: + title: No Principals Available + description: Principals are not available for assignment. + add-principals: + title: Add Principals + description: Select users and groups to assign to this role. + types: + user: User + group: Group + actions: + add-principals: Add Principals + grant: + title: Grant + title_plural: Grants + description: Grants are permissions which allow roles to take actions and access resources + actions: + create: New Grant host-set: Host Set host-sets: Host Sets host: Host @@ -89,10 +122,6 @@ hosts: Hosts target: Target targets: Targets descriptions: - role: A Role can be assigned to zero or more Principals. A Principal assigned a Role receives all capabilities granted by any Direct Grant owned by the Role. A Role is deleted when the Scope it belongs to is deleted. All Direct Grants owned by a Role are deleted when the Role is deleted. - roles: A role is a collection of capabilities granted to any Principal the Role is assigned to. A Role belongs to one and only one Scope. A Role owns zero or more Direct Grants. The lifecycle of a Role is not tied to the lifecycle of any Principal. - grants: A grant represents a set of capabilities granted to a role. It couples a set of Actions to either a set of Resource Types or an individual Resource. A Direct Grant belongs exclusively to one and only one Role. However, equivalent Direct Grants may exist across different Roles. A Direct Grant references one or more Actions and either one or more Resource types or one specific Resource. A Direct Grant is deleted when the Role it belongs to is deleted. A Direct Grant is also deleted if it is associated with a specific Resource and that Resource itself is deleted. The lifecycle of a Direct Grant is not tied to the lifecycle of any Action or Resource Type. - principals: A principal is any entity which can be assigned capabilities. Principal is abstract. User, Group, and Project are concrete Principals. A Principal can be assigned to zero or more Roles. host-set: Host Set is abstract. A Host Set is deleted when the Host Catalog it belongs to is deleted. host-sets: A host set is a resource which provides a subset of Hosts from the set of Hosts of the Host Catalog it belongs to. A Host Set belongs to one and only one Host Catalog. A Host Set can contain zero or more Hosts. A Host Set can be contained by zero or more Targets. The lifecycle of a Host Set is not tied to the lifecycle of any Targets or Hosts. host: Host is abstract. A Host is deleted when the Host Catalog it belongs to is deleted. From f81d509ca7dace11dc75fce44745d2ba006a3669 Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Fri, 25 Sep 2020 19:07:56 -0400 Subject: [PATCH 08/15] feature: enable form edit mode across all resource forms --- ui/core/app/components/form/account/password/index.hbs | 4 ++++ ui/core/app/components/form/auth-method/index.hbs | 4 ++++ ui/core/app/components/form/group/index.hbs | 4 ++++ ui/core/app/components/form/host-catalog/index.hbs | 4 ++++ ui/core/app/components/form/host-set/index.hbs | 4 ++++ ui/core/app/components/form/host/index.hbs | 2 ++ ui/core/app/components/form/org/index.hbs | 4 ++++ ui/core/app/components/form/project/index.hbs | 4 ++++ ui/core/app/components/form/role/index.hbs | 4 ++++ ui/core/app/components/form/target/index.hbs | 4 ++++ ui/core/app/components/form/user/index.hbs | 4 ++++ ui/core/app/templates/scopes/scope/groups/group/index.hbs | 2 +- ui/core/translations/actions/en-us.yaml | 1 + 13 files changed, 44 insertions(+), 1 deletion(-) diff --git a/ui/core/app/components/form/account/password/index.hbs b/ui/core/app/components/form/account/password/index.hbs index 492e1c658..33e8a3759 100644 --- a/ui/core/app/components/form/account/password/index.hbs +++ b/ui/core/app/components/form/account/password/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -33,6 +35,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -85,6 +88,7 @@ diff --git a/ui/core/app/components/form/auth-method/index.hbs b/ui/core/app/components/form/auth-method/index.hbs index df59e01d8..ffa39a264 100644 --- a/ui/core/app/components/form/auth-method/index.hbs +++ b/ui/core/app/components/form/auth-method/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -33,6 +35,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -48,6 +51,7 @@ diff --git a/ui/core/app/components/form/group/index.hbs b/ui/core/app/components/form/group/index.hbs index 0bcc6df4c..0e024b1fb 100644 --- a/ui/core/app/components/form/group/index.hbs +++ b/ui/core/app/components/form/group/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -11,6 +12,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} readonly={{false}} as |field|> @@ -28,6 +30,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -43,6 +46,7 @@ diff --git a/ui/core/app/components/form/host-catalog/index.hbs b/ui/core/app/components/form/host-catalog/index.hbs index 0bcc6df4c..0e024b1fb 100644 --- a/ui/core/app/components/form/host-catalog/index.hbs +++ b/ui/core/app/components/form/host-catalog/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -11,6 +12,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} readonly={{false}} as |field|> @@ -28,6 +30,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -43,6 +46,7 @@ diff --git a/ui/core/app/components/form/host-set/index.hbs b/ui/core/app/components/form/host-set/index.hbs index 82f093d2c..208fe8e0b 100644 --- a/ui/core/app/components/form/host-set/index.hbs +++ b/ui/core/app/components/form/host-set/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -17,6 +18,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} readonly={{false}} as |field|> @@ -34,6 +36,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -49,6 +52,7 @@ diff --git a/ui/core/app/components/form/host/index.hbs b/ui/core/app/components/form/host/index.hbs index af2ddf471..2cc0526a2 100644 --- a/ui/core/app/components/form/host/index.hbs +++ b/ui/core/app/components/form/host/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -69,6 +70,7 @@ diff --git a/ui/core/app/components/form/org/index.hbs b/ui/core/app/components/form/org/index.hbs index 0bcc6df4c..0e024b1fb 100644 --- a/ui/core/app/components/form/org/index.hbs +++ b/ui/core/app/components/form/org/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -11,6 +12,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} readonly={{false}} as |field|> @@ -28,6 +30,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -43,6 +46,7 @@ diff --git a/ui/core/app/components/form/project/index.hbs b/ui/core/app/components/form/project/index.hbs index 0bcc6df4c..0e024b1fb 100644 --- a/ui/core/app/components/form/project/index.hbs +++ b/ui/core/app/components/form/project/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -11,6 +12,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} readonly={{false}} as |field|> @@ -28,6 +30,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -43,6 +46,7 @@ diff --git a/ui/core/app/components/form/role/index.hbs b/ui/core/app/components/form/role/index.hbs index a35279612..ed1330e4c 100644 --- a/ui/core/app/components/form/role/index.hbs +++ b/ui/core/app/components/form/role/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -11,6 +12,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} @helperText={{t "form.name.help"}} readonly={{false}} @@ -29,6 +31,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} @helperText={{t "form.description.help"}} disabled={{@model.isSaving}} @@ -45,6 +48,7 @@ diff --git a/ui/core/app/components/form/target/index.hbs b/ui/core/app/components/form/target/index.hbs index f061923bf..cb03dac6a 100644 --- a/ui/core/app/components/form/target/index.hbs +++ b/ui/core/app/components/form/target/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -17,6 +18,7 @@ @type="text" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} @helperText={{t "form.name.help"}} as |field|> @@ -34,6 +36,7 @@ @type="text" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} @helperText={{t "form.description.help"}} as |field|> @@ -69,6 +72,7 @@ diff --git a/ui/core/app/components/form/user/index.hbs b/ui/core/app/components/form/user/index.hbs index 0bcc6df4c..0e024b1fb 100644 --- a/ui/core/app/components/form/user/index.hbs +++ b/ui/core/app/components/form/user/index.hbs @@ -3,6 +3,7 @@ @cancel={{@cancel}} @disabled={{@model.isSaving}} @error={{@model.errors.base}} + @showEditToggle={{if @model.isNew false true}} as |form| > @@ -11,6 +12,7 @@ @type="name" @value={{@model.name}} @label={{t "form.name.label"}} + @helperText={{t "form.name.help"}} @error={{@model.errors.name}} readonly={{false}} as |field|> @@ -28,6 +30,7 @@ @type="description" @value={{@model.description}} @label={{t "form.description.label"}} + @helperText={{t "form.description.help"}} @error={{@model.errors.description}} disabled={{@model.isSaving}} readonly={{false}} @@ -43,6 +46,7 @@ diff --git a/ui/core/app/templates/scopes/scope/groups/group/index.hbs b/ui/core/app/templates/scopes/scope/groups/group/index.hbs index 1fb27689d..cf2d36c97 100644 --- a/ui/core/app/templates/scopes/scope/groups/group/index.hbs +++ b/ui/core/app/templates/scopes/scope/groups/group/index.hbs @@ -1,4 +1,4 @@ - Date: Fri, 25 Sep 2020 19:08:38 -0400 Subject: [PATCH 09/15] chore: add missing default_port help text --- ui/core/translations/form/en-us.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/ui/core/translations/form/en-us.yaml b/ui/core/translations/form/en-us.yaml index 1c271aaa9..79e48056e 100644 --- a/ui/core/translations/form/en-us.yaml +++ b/ui/core/translations/form/en-us.yaml @@ -21,6 +21,7 @@ address: help: An IP, host name, or other routable address default_port: label: Default Port + help: The default port on which to connect current_password: label: Current Password new_password: From 2648cca9195da55fa260832422a7b66e12ebf18e Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 20:55:08 -0400 Subject: [PATCH 10/15] refactor: Update host catalog, host sets, and host translatio --- .../form/host-set/add-hosts/index.hbs | 4 +- .../app/components/form/host-set/index.hbs | 2 +- ui/core/app/components/form/host/index.hbs | 2 +- .../host-catalogs/host-catalog/host-sets.js | 2 +- .../host-catalogs/host-catalog/hosts.js | 2 +- .../host-catalogs/host-catalog/-actions.hbs | 6 +-- .../host-catalog/-navigation.hbs | 4 +- .../host-catalogs/host-catalog/host-sets.hbs | 2 +- .../host-catalog/host-sets/-actions.hbs | 4 +- .../host-catalog/host-sets/-header.hbs | 4 +- .../host-catalog/host-sets/-navigation.hbs | 2 +- .../host-sets/host-set/add-hosts.hbs | 2 +- .../host-sets/host-set/add-hosts/-header.hbs | 2 +- .../host-catalog/host-sets/host-set/hosts.hbs | 4 +- .../host-catalog/host-sets/index.hbs | 8 ++-- .../host-catalogs/host-catalog/hosts.hbs | 2 +- .../host-catalog/hosts/-actions.hbs | 2 +- .../host-catalog/hosts/-header.hbs | 4 +- .../host-catalog/hosts/index.hbs | 8 ++-- .../projects/project/host-catalogs/index.hbs | 2 +- ui/core/translations/en-us.yaml | 14 ------ ui/core/translations/resources/en-us.yaml | 45 +++++++++++++++---- 22 files changed, 73 insertions(+), 54 deletions(-) diff --git a/ui/core/app/components/form/host-set/add-hosts/index.hbs b/ui/core/app/components/form/host-set/add-hosts/index.hbs index b743efe0b..09be10a5b 100644 --- a/ui/core/app/components/form/host-set/add-hosts/index.hbs +++ b/ui/core/app/components/form/host-set/add-hosts/index.hbs @@ -43,9 +43,9 @@ {{#unless this.hasAvailableHosts}} - + - {{t "descriptions.no-host-set-hosts"}} + {{t "resources.host-set.messages.add-hosts.description"}} diff --git a/ui/core/app/components/form/host-set/index.hbs b/ui/core/app/components/form/host-set/index.hbs index 82f093d2c..24e7c84da 100644 --- a/ui/core/app/components/form/host-set/index.hbs +++ b/ui/core/app/components/form/host-set/index.hbs @@ -7,7 +7,7 @@ > diff --git a/ui/core/app/components/form/host/index.hbs b/ui/core/app/components/form/host/index.hbs index af2ddf471..2cc1d3157 100644 --- a/ui/core/app/components/form/host/index.hbs +++ b/ui/core/app/components/form/host/index.hbs @@ -7,7 +7,7 @@ > diff --git a/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.js b/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.js index 381afcab6..2ec9620d3 100644 --- a/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.js +++ b/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.js @@ -13,6 +13,6 @@ export default class ScopesScopeProjectsProjectHostCatalogsHostCatalogHostSetsCo * @type {string} */ get breadCrumb() { - return this.intl.t('resources.host-sets'); + return this.intl.t('resources.host-set.title_plural'); } } diff --git a/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.js b/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.js index 04a32f97f..589649129 100644 --- a/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.js +++ b/ui/core/app/controllers/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.js @@ -13,6 +13,6 @@ export default class ScopesScopeProjectsProjectHostCatalogsHostCatalogHostsContr * @type {string} */ get breadCrumb() { - return this.intl.t('resources.hosts'); + return this.intl.t('resources.host.title_plural'); } } diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-actions.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-actions.hbs index 1313c2f9a..557d572ba 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-actions.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-actions.hbs @@ -3,13 +3,13 @@ @route="scopes.scope.projects.project.host-catalogs.host-catalog.hosts.new" @model={{@model}} > - {{t "actions.add-host"}} + {{t "resources.host.actions.add"}} - {{t "actions.add-host-set"}} + {{t "resources.host-set.actions.add"}} - {{t 'actions.delete-host-catalog'}} + {{t 'resources.host-catalog.actions.delete'}} \ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-navigation.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-navigation.hbs index 0e02c6c14..5be44792b 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-navigation.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/-navigation.hbs @@ -3,9 +3,9 @@ {{t 'titles.details'}} - {{t 'titles.host-sets'}} + {{t 'resources.host-set.title_plural'}} - {{t 'titles.hosts'}} + {{t 'resources.host.title_plural'}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.hbs index 49966461b..37ecd2d33 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.host-sets")}} +{{title (t "resources.host-set.title_plural")}} {{outlet}} \ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-actions.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-actions.hbs index ec81ba648..0b6331854 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-actions.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-actions.hbs @@ -1,12 +1,12 @@ - {{t 'actions.add-hosts'}} + {{t 'resources.host-set.actions.add-hosts'}} - {{t 'actions.delete-host-set'}} + {{t 'resources.host-set.actions.delete'}} \ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-header.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-header.hbs index 05fa412e3..9cc76e026 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-header.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-header.hbs @@ -1,2 +1,2 @@ -

{{t "resources.host-set"}}

-

{{t "resources.descriptions.host-set"}}

\ No newline at end of file +

{{t "resources.host-set.title"}}

+

{{t "resources.host-set.description"}}

\ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-navigation.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-navigation.hbs index 8e2795027..93590ba90 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-navigation.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/-navigation.hbs @@ -3,6 +3,6 @@ {{t 'titles.details'}} - {{t 'resources.hosts'}} + {{t 'resources.host.title_plural'}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts.hbs index 3b3070bf7..b185f9550 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts.hbs @@ -1,4 +1,4 @@ -{{title (t "actions.add-hosts")}} +{{title (t "resources.host-set.actions.add-hosts")}} {{t "actions.add-hosts"}} +

{{t "resources.host-set.actions.add-hosts"}}

diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs index 6a89c2bc1..ae7c6ec90 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs @@ -52,9 +52,9 @@ {{#unless @model.hosts}} - + - {{t "descriptions.no-host-set-hosts"}} + {{t "resources.host.messages.none.description"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/index.hbs index be027d78c..0b0b90663 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/index.hbs @@ -21,7 +21,9 @@

{{hostSet.description}}

- {{hostSet.type}} + + {{t (concat 'resources.host-set.types.' hostSet.type)}} + {{hostSet.id}} @@ -34,9 +36,9 @@ {{else}} - + - {{t "descriptions.host-sets-welcome"}} + {{t "resources.host-set.description"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.hbs index 863e34ea9..aff384fe4 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.hosts")}} +{{title (t "resources.host.title_plural")}} {{outlet}} \ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-actions.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-actions.hbs index cef4c03c0..d01333c17 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-actions.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-actions.hbs @@ -4,6 +4,6 @@ @disabled={{@model.canSave}} {{on "click" (route-action "delete" @model)}} > - {{t 'actions.delete-host'}} + {{t 'resources.host.actions.delete'}} \ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-header.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-header.hbs index d9eea7635..5896f2a8c 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-header.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/-header.hbs @@ -1,2 +1,2 @@ -

{{t "resources.host"}}

-

{{t "resources.descriptions.host"}}

\ No newline at end of file +

{{t "resources.host.title"}}

+

{{t "resources.host.description"}}

\ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/index.hbs index 98bc8c2b9..3f1c23860 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/hosts/index.hbs @@ -22,7 +22,9 @@

{{host.description}}

- {{host.type}} + + {{t (concat 'resources.host.types.' host.type)}} + {{host.id}} @@ -38,9 +40,9 @@ {{else}} - + - {{t "descriptions.hosts-welcome"}} + {{t "resources.host.description"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs index e19459843..578a59c4a 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/index.hbs @@ -43,7 +43,7 @@ - {{hostCatalog.type}} + {{t (concat 'resources.host-catalog.types.' hostCatalog.type)}} diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index 6561047d6..f7f1be5d6 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -5,15 +5,9 @@ auth: no-scopes: No scopes were found. To authenticate, ask your administrator to create an scope and grant you access. choose-org: Choose a scope to authenticate. authenticating-with-org: "You're authenticating with {name}." -host-set: - types: - static: Static target: types: tcp: TCP -host: - types: - static: Static titles: iam: IAM new: New @@ -23,24 +17,16 @@ titles: overview: Overview settings: Settings empty-set: No Items Yet - host-sets-welcome: Welcome to Host Sets - hosts-welcome: Welcome to Hosts targets-welcome: Create your first Target target-host-sets-welcome: No Host Sets Associated - host-sets: Host Sets - hosts: Hosts targets: Targets global: Global - no-host-set-hosts: No Hosts Available no-host-sets-for-target: No Host Sets Available no-available-users: No Users Available actions: Actions descriptions: empty-set: There are no items to display yet. You may be able to add items or try back later. - host-sets-welcome: Configure a static host set in this host catalog. - hosts-welcome: Configure a static host in this host catalog. targets-welcome: Targets provide Users the means to connect to and interact networked services. A Target contains a collection of Hosts and a collection of Credentials. target-host-sets-welcome: Add Host Sets to this target to provide access. - no-host-set-hosts: Before associating hosts with this host set, create hosts within the host catalog. no-host-sets-for-target: No host sets are available to add to this target. no-available-users: No users are available to add to this group. diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 1c1287707..87ad8d7a7 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -51,6 +51,43 @@ host-catalog: messages: welcome: title: Welcome to Host Catalogs + actions: + delete: Delete Host Catalog + types: + static: Static +host-set: + title: Host Set + title_plural: Host Sets + description: A host set is a collection of hosts within a host catalog. + actions: + add: Add Host Set + create: New Host Set + delete: Delete Host Set + add-hosts: Add Hosts + messages: + welcome: + title: Welcome to Host Sets + add-hosts: + title: No Hosts Available + description: No hosts available in this scope for association. + types: + static: Static +host: + title: Host + title_plural: Hosts + description: A host is a resource that may be accessed by a Boundary target. + messages: + welcome: + title: Welcome to Hosts + none: + title: No Hosts + description: No hosts available in this scope. + actions: + add: Add Host + create: New Host + delete: Delete Host + types: + static: Static session: title: Session title_plural: Sessions @@ -115,16 +152,8 @@ role: description: Grants are permissions which allow roles to take actions and access resources actions: create: New Grant -host-set: Host Set -host-sets: Host Sets -host: Host -hosts: Hosts target: Target targets: Targets descriptions: - host-set: Host Set is abstract. A Host Set is deleted when the Host Catalog it belongs to is deleted. - host-sets: A host set is a resource which provides a subset of Hosts from the set of Hosts of the Host Catalog it belongs to. A Host Set belongs to one and only one Host Catalog. A Host Set can contain zero or more Hosts. A Host Set can be contained by zero or more Targets. The lifecycle of a Host Set is not tied to the lifecycle of any Targets or Hosts. - host: Host is abstract. A Host is deleted when the Host Catalog it belongs to is deleted. - hosts: A host is a computing element with a network address reachable from Boundary. A Host belongs to one and only one Host Catalog. A Host can be contained by zero or more Host Sets. The lifecycle of a Host is not tied to the lifecycle of any Host Sets. target: Target is abstract. A Target is deleted when the Scope it belongs to is deleted. targets: A target is a networked service a User can connect to and interact with through Boundary. A Target does not directly contain any secrets. A Target contains a collection of Hosts. A Target belongs to one and only one Scope. A Target can contain zero or more Host Sets. The lifecycle of a Target is not tied to the lifecycle of any Host Set. From 2e6745033913762cf0b8f40d6ef8a104a7d25dbb Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 21:21:27 -0400 Subject: [PATCH 11/15] refactor: Update target translations --- .../form/target/add-host-sets/index.hbs | 98 +++++++++++-------- .../form/target/add-host-sets/index.js | 10 ++ ui/core/app/components/form/target/index.hbs | 2 +- .../scopes/scope/projects/project/targets.js | 2 +- .../project/targets/target/add-host-sets.js | 2 +- .../project/targets/target/host-sets.js | 2 +- .../scope/projects/project/_sidebar.hbs | 2 +- .../scopes/scope/projects/project/targets.hbs | 2 +- .../scope/projects/project/targets/index.hbs | 12 ++- .../project/targets/target/-actions.hbs | 4 +- .../project/targets/target/-header.hbs | 4 +- .../project/targets/target/-navigation.hbs | 2 +- .../project/targets/target/add-host-sets.hbs | 6 +- .../targets/target/add-host-sets/-header.hbs | 3 +- .../project/targets/target/host-sets.hbs | 8 +- ui/core/translations/en-us.yaml | 14 +-- ui/core/translations/resources/en-us.yaml | 29 +++++- 17 files changed, 119 insertions(+), 83 deletions(-) diff --git a/ui/core/app/components/form/target/add-host-sets/index.hbs b/ui/core/app/components/form/target/add-host-sets/index.hbs index 5ad080dee..fa02412bb 100644 --- a/ui/core/app/components/form/target/add-host-sets/index.hbs +++ b/ui/core/app/components/form/target/add-host-sets/index.hbs @@ -1,44 +1,60 @@ - +{{#if this.hasAvailableHostSets}} + - + - - - - {{t 'form.id.label'}} - {{t 'form.name.label'}} - {{t 'form.type.label'}} - {{t 'resources.host-catalog.title_plural'}} - - - - {{#each this.filteredHostSets as |hostSet|}} - - - - - {{hostSet.name}} - - {{hostSet.type}} - - - {{hostSet.host_catalog_id}} - - - {{/each}} - - + + + + {{t 'form.id.label'}} + {{t 'form.name.label'}} + {{t 'form.type.label'}} + {{t 'resources.host-catalog.title_plural'}} + + + + {{#each this.filteredHostSets as |hostSet|}} + + + + + {{hostSet.name}} + + {{t (concat 'resources.host-set.types.' hostSet.type)}} + + + {{hostSet.host_catalog_id}} + + + {{/each}} + + - + +{{/if}} + +{{#unless this.hasAvailableHostSets}} + + + + {{t "resources.target.host-set.messages.none.description"}} + + + + {{t "actions.back"}} + + + +{{/unless}} \ No newline at end of file diff --git a/ui/core/app/components/form/target/add-host-sets/index.js b/ui/core/app/components/form/target/add-host-sets/index.js index 317ac2ba6..c65b7a620 100644 --- a/ui/core/app/components/form/target/add-host-sets/index.js +++ b/ui/core/app/components/form/target/add-host-sets/index.js @@ -11,6 +11,16 @@ export default class FormTargetAddHostSetsComponent extends Component { */ selectedHostSetIDs = A(); + /** + * Checks for unassigned hostsets. + * @param {[HostSetModel]} filteredHostSets + * @type {boolean} + */ + @computed('filteredHostSets') + get hasAvailableHostSets() { + return this.filteredHostSets.length > 0; + } + /** * Host sets not already added to the target. * @type {[HostSetModel]} diff --git a/ui/core/app/components/form/target/index.hbs b/ui/core/app/components/form/target/index.hbs index f061923bf..c1a4bebf6 100644 --- a/ui/core/app/components/form/target/index.hbs +++ b/ui/core/app/components/form/target/index.hbs @@ -7,7 +7,7 @@ > diff --git a/ui/core/app/controllers/scopes/scope/projects/project/targets.js b/ui/core/app/controllers/scopes/scope/projects/project/targets.js index 5d11f3566..9c51e3de1 100644 --- a/ui/core/app/controllers/scopes/scope/projects/project/targets.js +++ b/ui/core/app/controllers/scopes/scope/projects/project/targets.js @@ -13,6 +13,6 @@ export default class ScopesScopeProjectsProjectTargetsController extends Control * @type {string} */ get breadCrumb() { - return this.intl.t('resources.targets'); + return this.intl.t('resources.target.title_plural'); } } diff --git a/ui/core/app/controllers/scopes/scope/projects/project/targets/target/add-host-sets.js b/ui/core/app/controllers/scopes/scope/projects/project/targets/target/add-host-sets.js index db7181061..8a4cb606e 100644 --- a/ui/core/app/controllers/scopes/scope/projects/project/targets/target/add-host-sets.js +++ b/ui/core/app/controllers/scopes/scope/projects/project/targets/target/add-host-sets.js @@ -12,6 +12,6 @@ export default class ScopesScopeProjectsProjectTargetsTargetAddHostSetsControlle * @type {string} */ get breadCrumb() { - return this.intl.t('actions.add-host-sets'); + return this.intl.t('resources.target.actions.add-host-sets'); } } diff --git a/ui/core/app/controllers/scopes/scope/projects/project/targets/target/host-sets.js b/ui/core/app/controllers/scopes/scope/projects/project/targets/target/host-sets.js index 92d1dfc1f..92a90208b 100644 --- a/ui/core/app/controllers/scopes/scope/projects/project/targets/target/host-sets.js +++ b/ui/core/app/controllers/scopes/scope/projects/project/targets/target/host-sets.js @@ -13,6 +13,6 @@ export default class ScopesScopeProjectsProjectTargetsTargetHostSetsController e * @type {string} */ get breadCrumb() { - return this.intl.t('resources.host-sets'); + return this.intl.t('resources.host-set.title_plural'); } } diff --git a/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs b/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs index 30441e047..b9d440b7c 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/_sidebar.hbs @@ -3,7 +3,7 @@ {{t "resources.session.title_plural"}} - {{t "resources.targets"}} + {{t "resources.target.title_plural"}} {{t "resources.host-catalog.title_plural"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets.hbs index 744cee2b2..8b5774916 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets.hbs @@ -1,3 +1,3 @@ -{{title (t "resources.targets")}} +{{title (t "resources.target.title_plural")}} {{outlet}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/index.hbs index 987d342d1..d6e45da25 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/index.hbs @@ -5,8 +5,10 @@ -

{{t "resources.targets"}}

-

{{t "resources.descriptions.targets"}}

+

{{t "resources.target.title_plural"}}

+ {{#if @model}} +

{{t "resources.target.description"}}

+ {{/if}}
@@ -44,7 +46,7 @@ {{#if target.type}} - {{t (concat "target.types." target.type)}} + {{t (concat "resources.target.types." target.type)}} {{/if}} @@ -59,9 +61,9 @@ {{else}} - + - {{t "descriptions.targets-welcome"}} + {{t "resources.target.description"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/target/-actions.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/target/-actions.hbs index 4e62a8047..40c0949d0 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/target/-actions.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/target/-actions.hbs @@ -1,12 +1,12 @@ - {{t 'actions.add-host-sets'}} + {{t 'resources.target.actions.add-host-sets'}} - {{t 'actions.delete-target'}} + {{t 'resources.target.actions.delete'}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/target/-header.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/target/-header.hbs index 0dc39d88d..5de87dc3d 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/target/-header.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/target/-header.hbs @@ -1,2 +1,2 @@ -

{{t "resources.target"}}

-

{{t "resources.descriptions.target"}}

+

{{t "resources.target.title"}}

+

{{t "resources.target.description"}}

diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/target/-navigation.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/target/-navigation.hbs index b486f4ca8..a31f1590c 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/target/-navigation.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/target/-navigation.hbs @@ -3,6 +3,6 @@ {{t 'titles.details'}}
- {{t 'titles.host-sets'}} + {{t 'resources.host-set.title_plural'}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets.hbs index e487f20f6..15daf752a 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets.hbs @@ -1,4 +1,4 @@ -{{title (t 'actions.add-host-sets')}} +{{title (t 'resources.target.actions.add-host-sets')}} {{#if @model.hostSets}} - + - {{t "descriptions.no-host-sets-for-target"}} + {{t "resources.target.host-set.messages.none.description"}} diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets/-header.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets/-header.hbs index f29bc39c7..794392a62 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets/-header.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/target/add-host-sets/-header.hbs @@ -1 +1,2 @@ -

{{t "actions.add-host-sets"}}

+

{{t "resources.target.host-set.messages.add.title"}}

+

{{t "resources.target.host-set.messages.add.description"}}

\ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/targets/target/host-sets.hbs b/ui/core/app/templates/scopes/scope/projects/project/targets/target/host-sets.hbs index acdad4643..827793ccd 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/targets/target/host-sets.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/targets/target/host-sets.hbs @@ -1,4 +1,4 @@ -{{title (t "resources.host-sets")}} +{{title (t "resources.host-set.title_plural")}} {{#if @model.hostSets}} @@ -19,7 +19,7 @@

{{hostSet.model.description}}

- {{hostSet.model.type}} + {{t (concat 'resources.host-set.types.' hostSet.model.type)}} {{hostSet.model.id}} @@ -48,9 +48,9 @@ {{else}} - + - {{t "descriptions.target-host-sets-welcome"}} + {{t "resources.target.host-set.messages.welcome.description"}} diff --git a/ui/core/translations/en-us.yaml b/ui/core/translations/en-us.yaml index f7f1be5d6..a7957c064 100644 --- a/ui/core/translations/en-us.yaml +++ b/ui/core/translations/en-us.yaml @@ -5,9 +5,6 @@ auth: no-scopes: No scopes were found. To authenticate, ask your administrator to create an scope and grant you access. choose-org: Choose a scope to authenticate. authenticating-with-org: "You're authenticating with {name}." -target: - types: - tcp: TCP titles: iam: IAM new: New @@ -17,16 +14,7 @@ titles: overview: Overview settings: Settings empty-set: No Items Yet - targets-welcome: Create your first Target - target-host-sets-welcome: No Host Sets Associated - targets: Targets global: Global - no-host-sets-for-target: No Host Sets Available - no-available-users: No Users Available actions: Actions descriptions: - empty-set: There are no items to display yet. You may be able to add items or try back later. - targets-welcome: Targets provide Users the means to connect to and interact networked services. A Target contains a collection of Hosts and a collection of Credentials. - target-host-sets-welcome: Add Host Sets to this target to provide access. - no-host-sets-for-target: No host sets are available to add to this target. - no-available-users: No users are available to add to this group. + empty-set: There are no items to display yet. You may be able to add items or try back later. \ No newline at end of file diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 87ad8d7a7..2632275f4 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -152,8 +152,27 @@ role: description: Grants are permissions which allow roles to take actions and access resources actions: create: New Grant -target: Target -targets: Targets -descriptions: - target: Target is abstract. A Target is deleted when the Scope it belongs to is deleted. - targets: A target is a networked service a User can connect to and interact with through Boundary. A Target does not directly contain any secrets. A Target contains a collection of Hosts. A Target belongs to one and only one Scope. A Target can contain zero or more Host Sets. The lifecycle of a Target is not tied to the lifecycle of any Host Set. +target: + title: Target + title_plural: Targets + description: A target is a logical collection of host sets which may be used to initiate sessions. + messages: + welcome: + title: Welcome to Targets + actions: + create: New Target + delete: Delete Target + add-host-sets: Add Host Sets + types: + tcp: TCP + host-set: + messages: + welcome: + title: Welcome to Host Sets + description: No hosts sets in this target. + none: + title: No Host Sets Available + description: No hosts sets available to add to target. + add: + title: Add Host Sets + description: Select host sets to assign to this target. \ No newline at end of file From da10635e1e04f047912c837121f8a1a0d7b33707 Mon Sep 17 00:00:00 2001 From: Susmitha Girumala Date: Fri, 25 Sep 2020 21:30:58 -0400 Subject: [PATCH 12/15] refactor: Translation cleanup --- .../host-sets/host-set/add-hosts/-header.hbs | 3 ++- .../host-catalog/host-sets/host-set/hosts.hbs | 4 ++-- ui/core/translations/resources/en-us.yaml | 15 ++++++++++----- 3 files changed, 14 insertions(+), 8 deletions(-) diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts/-header.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts/-header.hbs index 2267ffd96..ef9992c2c 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts/-header.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/add-hosts/-header.hbs @@ -1 +1,2 @@ -

{{t "resources.host-set.actions.add-hosts"}}

+

{{t "resources.host-set.host.messages.add.title"}}

+

{{t "resources.host-set.host.messages.add.description"}}

\ No newline at end of file diff --git a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs index ae7c6ec90..abc6852da 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/host-catalogs/host-catalog/host-sets/host-set/hosts.hbs @@ -52,9 +52,9 @@ {{#unless @model.hosts}} - + - {{t "resources.host.messages.none.description"}} + {{t "resources.host-set.host.messages.none.description"}} diff --git a/ui/core/translations/resources/en-us.yaml b/ui/core/translations/resources/en-us.yaml index 2632275f4..fb595f18d 100644 --- a/ui/core/translations/resources/en-us.yaml +++ b/ui/core/translations/resources/en-us.yaml @@ -32,7 +32,7 @@ auth-method: group: title: Group title_plural: Groups - description: Groups are collections of users. Groups may be assigned to roles, thereby receiving the role's grants. + description: Groups are collections of users. Groups may be assigned to roles to receive the role’s grants. messages: welcome: title: Welcome to Groups @@ -67,9 +67,14 @@ host-set: messages: welcome: title: Welcome to Host Sets - add-hosts: - title: No Hosts Available - description: No hosts available in this scope for association. + host: + messages: + none: + title: Welcome to Hosts + description: No hosts available in this host set. + add: + title: Add Hosts + description: Select hosts that belong to this host set. types: static: Static host: @@ -149,7 +154,7 @@ role: grant: title: Grant title_plural: Grants - description: Grants are permissions which allow roles to take actions and access resources + description: Grants are permissions which allow roles to take actions and access resources. actions: create: New Grant target: From 038c50673bf1b828b788b4f69c260babd465cce3 Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Sat, 26 Sep 2020 10:20:02 -0400 Subject: [PATCH 13/15] test: update edit tests for staged edit form and remove redundant error tests --- ui/core/app/components/form/role/index.hbs | 2 -- ui/core/app/components/form/target/index.hbs | 2 -- ui/core/tests/acceptance/accounts-test.js | 4 +++ ui/core/tests/acceptance/auth-methods-test.js | 7 ++++- ui/core/tests/acceptance/groups-test.js | 26 +++--------------- .../tests/acceptance/host-catalogs-test.js | 27 +++---------------- ui/core/tests/acceptance/host-sets-test.js | 23 +++------------- ui/core/tests/acceptance/hosts-test.js | 23 +++------------- ui/core/tests/acceptance/projects-test.js | 26 +++--------------- ui/core/tests/acceptance/roles-test.js | 26 +++--------------- ui/core/tests/acceptance/targets-test.js | 25 +++-------------- ui/core/tests/acceptance/users-test.js | 26 +++--------------- 12 files changed, 35 insertions(+), 182 deletions(-) diff --git a/ui/core/app/components/form/role/index.hbs b/ui/core/app/components/form/role/index.hbs index ed1330e4c..0e024b1fb 100644 --- a/ui/core/app/components/form/role/index.hbs +++ b/ui/core/app/components/form/role/index.hbs @@ -14,7 +14,6 @@ @label={{t "form.name.label"}} @helperText={{t "form.name.help"}} @error={{@model.errors.name}} - @helperText={{t "form.name.help"}} readonly={{false}} as |field|> {{#if @model.errors.name}} @@ -33,7 +32,6 @@ @label={{t "form.description.label"}} @helperText={{t "form.description.help"}} @error={{@model.errors.description}} - @helperText={{t "form.description.help"}} disabled={{@model.isSaving}} readonly={{false}} as |field|> diff --git a/ui/core/app/components/form/target/index.hbs b/ui/core/app/components/form/target/index.hbs index cb03dac6a..d54eff947 100644 --- a/ui/core/app/components/form/target/index.hbs +++ b/ui/core/app/components/form/target/index.hbs @@ -20,7 +20,6 @@ @label={{t "form.name.label"}} @helperText={{t "form.name.help"}} @error={{@model.errors.name}} - @helperText={{t "form.name.help"}} as |field|> {{#if @model.errors.name}} @@ -38,7 +37,6 @@ @label={{t "form.description.label"}} @helperText={{t "form.description.help"}} @error={{@model.errors.description}} - @helperText={{t "form.description.help"}} as |field|> {{#if @model.errors.description}} diff --git a/ui/core/tests/acceptance/accounts-test.js b/ui/core/tests/acceptance/accounts-test.js index fce8e5cb1..4f966114d 100644 --- a/ui/core/tests/acceptance/accounts-test.js +++ b/ui/core/tests/acceptance/accounts-test.js @@ -80,6 +80,7 @@ module('Acceptance | accounts', function (hooks) { assert.expect(1); await visit(urls.account); await fillIn('[name="name"]', 'update name'); + await click('form [type="button"]'); await click('form [type="submit"]:not(:disabled)'); assert.equal(this.server.db.accounts[0].name, 'update name'); }); @@ -87,6 +88,7 @@ module('Acceptance | accounts', function (hooks) { test('can update an account and cancel changes', async function (assert) { assert.expect(1); await visit(urls.account) + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'update name'); await click('form button:not([type="submit"])'); assert.notEqual(this.server.db.accounts[0].name, 'update name'); @@ -174,6 +176,7 @@ module('Acceptance | accounts', function (hooks) { }); await visit(urls.account); await fillIn('[name="name"]', 'save account'); + await click('form [type="button"]'); await click('form [type="submit"]'); await a11yAudit(); assert.ok( @@ -228,6 +231,7 @@ module('Acceptance | accounts', function (hooks) { ); }); await visit(urls.account); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'existing account'); await click('form [type="submit"]'); await a11yAudit(); diff --git a/ui/core/tests/acceptance/auth-methods-test.js b/ui/core/tests/acceptance/auth-methods-test.js index fa46de1ed..e1507f32e 100644 --- a/ui/core/tests/acceptance/auth-methods-test.js +++ b/ui/core/tests/acceptance/auth-methods-test.js @@ -66,6 +66,7 @@ module('Acceptance | auth methods', function (hooks) { test('can update an auth method and save changes', async function (assert) { assert.expect(1); await visit(urls.authMethod); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'update name'); await click('form [type="submit"]:not(:disabled)'); assert.equal(this.server.db.authMethods[0].name, 'update name'); @@ -74,6 +75,7 @@ module('Acceptance | auth methods', function (hooks) { test('can update an auth method and cancel changes', async function (assert) { assert.expect(1); await visit(urls.authMethod) + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'update name'); await click('form button:not([type="submit"])'); assert.notEqual(this.server.db.authMethods[0].name, 'update name'); @@ -160,6 +162,7 @@ module('Acceptance | auth methods', function (hooks) { }); await visit(urls.authMethod); await fillIn('[name="name"]', 'save auth method'); + await click('form [type="button"]'); await click('form [type="submit"]'); await a11yAudit(); assert.ok( @@ -192,7 +195,7 @@ module('Acceptance | auth methods', function (hooks) { ); }); - test('saving a new auth method with invalid fields displays error messages', async function (assert) { + test('saving an existing auth method with invalid fields displays error messages', async function (assert) { assert.expect(2); this.server.patch('/auth-methods/:id', () => { return new Response( @@ -214,6 +217,7 @@ module('Acceptance | auth methods', function (hooks) { ); }); await visit(urls.authMethod); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'existing auth method'); await click('form [type="submit"]'); await a11yAudit(); @@ -251,6 +255,7 @@ module('Acceptance | auth methods', function (hooks) { ); }); await visit(urls.authMethod); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'existing auth method'); await click('form [type="submit"]'); await a11yAudit(); diff --git a/ui/core/tests/acceptance/groups-test.js b/ui/core/tests/acceptance/groups-test.js index c3d2e5add..1dfb81a7c 100644 --- a/ui/core/tests/acceptance/groups-test.js +++ b/ui/core/tests/acceptance/groups-test.js @@ -116,6 +116,7 @@ module('Acceptance | groups', function (hooks) { test('can save changes to an existing group', async function (assert) { assert.expect(2); await visit(urls.group); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated admin group'); await click('.rose-form-actions [type="submit"]'); assert.equal(currentURL(), urls.group); @@ -125,6 +126,7 @@ module('Acceptance | groups', function (hooks) { test('can cancel changes to an existing group', async function (assert) { assert.expect(1); await visit(urls.group); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated admin group'); await click('.rose-form-actions [type="button"]'); assert.notEqual(find('[name="name"]').value, 'Updated admin group'); @@ -160,6 +162,7 @@ module('Acceptance | groups', function (hooks) { ); }); await visit(urls.group); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'random string'); await click('[type="submit"]'); assert.ok( @@ -174,29 +177,6 @@ module('Acceptance | groups', function (hooks) { ); }); - test('errors are displayed when save project fails', async function (assert) { - assert.expect(1); - this.server.patch('/groups/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(urls.group); - await fillIn('[name="name"]', 'Role name'); - await click('[type="submit"]'); - assert.ok( - find('[role="alert"]').textContent.trim(), - 'Oops.', - 'Displays primary error message.' - ); - }); - test('errors are displayed when delete project fails', async function (assert) { assert.expect(1); this.server.del('/groups/:id', () => { diff --git a/ui/core/tests/acceptance/host-catalogs-test.js b/ui/core/tests/acceptance/host-catalogs-test.js index a9438517e..bcb07a0a3 100644 --- a/ui/core/tests/acceptance/host-catalogs-test.js +++ b/ui/core/tests/acceptance/host-catalogs-test.js @@ -84,6 +84,7 @@ module('Acceptance | host catalogs', function (hooks) { test('can update host catalog and save changes', async function (assert) { assert.expect(1); await visit(urls.hostCatalog); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Test Name'); await click('form [type="submit"]:not(:disabled)'); assert.equal(this.server.db.hostCatalogs[0].name, 'Test Name'); @@ -92,6 +93,7 @@ module('Acceptance | host catalogs', function (hooks) { test('can update host catalog and cancel changes', async function (assert) { assert.expect(1); await visit(urls.hostCatalog); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Test Name'); await click('form button:not([type="submit"])'); assert.notEqual(this.server.db.hostCatalogs[0].name, 'Test Name'); @@ -115,30 +117,6 @@ module('Acceptance | host catalogs', function (hooks) { assert.equal(this.server.db.hostCatalogs.length, hostCatalogsCount); }); - test('errors are displayed when save host catalog fails', async function (assert) { - assert.expect(1); - this.server.patch('/host-catalogs/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(urls.hostCatalog); - await fillIn('[name="name"]', 'random string'); - await click('form [type="submit"]'); - await a11yAudit(); - assert.ok( - find('[role="alert"]').textContent.trim(), - 'Oops.', - 'Displays primary error message.' - ); - }); - test('errors are displayed when delete host catalog fails', async function (assert) { assert.expect(1); this.server.del('/host-catalogs/:id', () => { @@ -221,6 +199,7 @@ module('Acceptance | host catalogs', function (hooks) { ); }); await visit(urls.hostCatalog); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'random string'); await click('form [type="submit"]'); await a11yAudit(); diff --git a/ui/core/tests/acceptance/host-sets-test.js b/ui/core/tests/acceptance/host-sets-test.js index 3c69e1b0e..1fdfc0f91 100644 --- a/ui/core/tests/acceptance/host-sets-test.js +++ b/ui/core/tests/acceptance/host-sets-test.js @@ -73,6 +73,7 @@ module('Acceptance | host sets', function (hooks) { test('can update a host set and save changes', async function (assert) { assert.expect(3); await visit(urls.hostSet); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated name'); await fillIn('[name="description"]', 'Updated description'); await click('.rose-form-actions [type="submit"]'); @@ -84,6 +85,7 @@ module('Acceptance | host sets', function (hooks) { test('can update a host set and cancel changes', async function (assert) { assert.expect(1); await visit(urls.hostSet); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated name'); await click('.rose-form-actions [type="button"]'); assert.notEqual(find('[name="name"]').value, 'Updated name'); @@ -120,6 +122,7 @@ module('Acceptance | host sets', function (hooks) { ); }); await visit(urls.hostSet); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'existing host'); await click('[type="submit"]'); await a11yAudit(); @@ -127,26 +130,6 @@ module('Acceptance | host sets', function (hooks) { assert.ok(find('.rose-form-error-message')); }); - test('errors are displayed when save on host set fails', async function (assert) { - assert.expect(1); - this.server.patch('/host-sets/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(urls.hostSet); - await fillIn('[name="name"]', 'save host'); - await click('form [type="submit"]'); - await a11yAudit(); - assert.ok(find('[role="alert"]')); - }); - test('errors are displayed when delete on a host set fails', async function (assert) { assert.expect(1); this.server.del('/host-sets/:id', () => { diff --git a/ui/core/tests/acceptance/hosts-test.js b/ui/core/tests/acceptance/hosts-test.js index 27881f02b..2514210fb 100644 --- a/ui/core/tests/acceptance/hosts-test.js +++ b/ui/core/tests/acceptance/hosts-test.js @@ -73,6 +73,7 @@ module('Acceptance | hosts', function (hooks) { test('can update a host and save changes', async function (assert) { assert.expect(4); await visit(urls.host); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated name'); await fillIn('[name="description"]', 'Updated description'); await fillIn('[name="address"]', '::1'); @@ -86,6 +87,7 @@ module('Acceptance | hosts', function (hooks) { test('can update a host and cancel changes', async function (assert) { assert.expect(1); await visit(urls.host); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated name'); await click('.rose-form-actions [type="button"]'); assert.notEqual(find('[name="name"]').value, 'Updated name'); @@ -122,6 +124,7 @@ module('Acceptance | hosts', function (hooks) { ); }); await visit(urls.host); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'existing host'); await click('[type="submit"]'); await a11yAudit(); @@ -129,26 +132,6 @@ module('Acceptance | hosts', function (hooks) { assert.ok(find('.rose-form-error-message')); }); - test('errors are displayed when save on host fails', async function (assert) { - assert.expect(1); - this.server.patch('/hosts/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(urls.host); - await fillIn('[name="name"]', 'save host'); - await click('form [type="submit"]'); - await a11yAudit(); - assert.ok(find('[role="alert"]')); - }); - test('errors are displayed when delete on a host fails', async function (assert) { assert.expect(1); this.server.del('/hosts/:id', () => { diff --git a/ui/core/tests/acceptance/projects-test.js b/ui/core/tests/acceptance/projects-test.js index f29002157..0483a56c8 100644 --- a/ui/core/tests/acceptance/projects-test.js +++ b/ui/core/tests/acceptance/projects-test.js @@ -117,6 +117,7 @@ module('Acceptance | projects', function (hooks) { assert.expect(3); assert.notEqual(existingProject.name, 'random string'); await visit(existingProjectURL); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'random string'); await click('.rose-form-actions [type="submit"]'); assert.equal(currentURL(), existingProjectURL); @@ -126,6 +127,7 @@ module('Acceptance | projects', function (hooks) { test('can cancel changes to existing project', async function (assert) { assert.expect(2); await visit(existingProjectURL); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'random string'); await click('.rose-form-actions [type="button"]'); assert.notEqual(existingProject.name, 'random string'); @@ -161,6 +163,7 @@ module('Acceptance | projects', function (hooks) { ); }); await visit(existingProjectURL); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'random string'); await click('[type="submit"]'); assert.ok( @@ -175,29 +178,6 @@ module('Acceptance | projects', function (hooks) { ); }); - test('errors are displayed when save project fails', async function (assert) { - assert.expect(1); - this.server.patch('/scopes/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(existingProjectURL); - await fillIn('[name="name"]', 'random string'); - await click('[type="submit"]'); - assert.ok( - find('[role="alert"]').textContent.trim(), - 'Oops.', - 'Displays primary error message.' - ); - }); - test('errors are displayed when delete project fails', async function (assert) { assert.expect(1); this.server.del('/scopes/:id', () => { diff --git a/ui/core/tests/acceptance/roles-test.js b/ui/core/tests/acceptance/roles-test.js index eee3ffa50..4060a9cd1 100644 --- a/ui/core/tests/acceptance/roles-test.js +++ b/ui/core/tests/acceptance/roles-test.js @@ -62,6 +62,7 @@ module('Acceptance | roles', function (hooks) { test('can save changes to an existing role', async function (assert) { assert.expect(2); await visit(urls.role); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated admin role'); await click('.rose-form-actions [type="submit"]'); assert.equal(currentURL(), urls.role); @@ -71,6 +72,7 @@ module('Acceptance | roles', function (hooks) { test('can cancel changes to an existing role', async function (assert) { assert.expect(1); await visit(urls.role); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated admin role'); await click('.rose-form-actions [type="button"]'); assert.notEqual(find('[name="name"]').value, 'Updated admin role'); @@ -154,6 +156,7 @@ module('Acceptance | roles', function (hooks) { ); }); await visit(urls.role); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'random string'); await click('[type="submit"]'); assert.ok( @@ -168,29 +171,6 @@ module('Acceptance | roles', function (hooks) { ); }); - test('errors are displayed when save project fails', async function (assert) { - assert.expect(1); - this.server.patch('/roles/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(urls.role); - await fillIn('[name="name"]', 'Role name'); - await click('[type="submit"]'); - assert.ok( - find('[role="alert"]').textContent.trim(), - 'Oops.', - 'Displays primary error message.' - ); - }); - test('errors are displayed when delete project fails', async function (assert) { assert.expect(1); this.server.del('/roles/:id', () => { diff --git a/ui/core/tests/acceptance/targets-test.js b/ui/core/tests/acceptance/targets-test.js index 7cf31d8c5..a269173b0 100644 --- a/ui/core/tests/acceptance/targets-test.js +++ b/ui/core/tests/acceptance/targets-test.js @@ -92,6 +92,7 @@ module('Acceptance | targets', function (hooks) { test('can update a target and save changes', async function (assert) { assert.expect(2); await visit(urls.target); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'update name'); await fillIn('[name="default_port"]', '1234'); await click('form [type="submit"]:not(:disabled)'); @@ -102,6 +103,7 @@ module('Acceptance | targets', function (hooks) { test('can update a target and cancel changes', async function (assert) { assert.expect(2); await visit(urls.target); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'update name'); await fillIn('[name="default_port"]', '1234'); await click('form button:not([type="submit"])'); @@ -167,26 +169,6 @@ module('Acceptance | targets', function (hooks) { assert.ok(find('.rose-form-error-message')); }); - test('errors are displayed when save on target fails', async function (assert) { - assert.expect(1); - this.server.patch('/targets/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(urls.target); - await fillIn('[name="name"]', 'save target'); - await click('form [type="submit"]'); - await a11yAudit(); - assert.ok(find('[role="alert"]')); - }); - test('errors are displayed when delete on a target fails', async function (assert) { assert.expect(1); this.server.del('/targets/:id', () => { @@ -228,6 +210,7 @@ module('Acceptance | targets', function (hooks) { ); }); await visit(urls.target); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'existing target'); await click('form [type="submit"]'); await a11yAudit(); @@ -245,7 +228,7 @@ module('Acceptance | targets', function (hooks) { assert.equal(findAll('tbody tr').length, targetHostSetCount); }); - test('can delete a host sets', async function (assert) { + test('can remove a host sets', async function (assert) { assert.expect(2); const targetHostSetCount = instances.target.hostSets.length; await visit(urls.targetHostSets); diff --git a/ui/core/tests/acceptance/users-test.js b/ui/core/tests/acceptance/users-test.js index 36e57926a..065f8974b 100644 --- a/ui/core/tests/acceptance/users-test.js +++ b/ui/core/tests/acceptance/users-test.js @@ -112,6 +112,7 @@ module('Acceptance | users', function (hooks) { test('can save changes to an existing user', async function (assert) { assert.expect(2); await visit(userURL); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Updated user name'); await click('.rose-form-actions [type="submit"]'); assert.equal(currentURL(), userURL); @@ -121,6 +122,7 @@ module('Acceptance | users', function (hooks) { test('can cancel changes to an existing user', async function (assert) { assert.expect(1); await visit(userURL); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'Unsaved user name'); await click('.rose-form-actions [type="button"]'); assert.notEqual(find('[name="name"]').value, 'Unsaved user name'); @@ -156,6 +158,7 @@ module('Acceptance | users', function (hooks) { ); }); await visit(userURL); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'User name'); await click('[type="submit"]'); assert.ok( @@ -170,29 +173,6 @@ module('Acceptance | users', function (hooks) { ); }); - test('errors are displayed when saving user fails', async function (assert) { - assert.expect(1); - this.server.patch('/users/:id', () => { - return new Response( - 490, - {}, - { - status: 490, - code: 'error', - message: 'Oops.', - } - ); - }); - await visit(userURL); - await fillIn('[name="name"]', 'User name'); - await click('[type="submit"]'); - assert.ok( - find('[role="alert"]').textContent.trim(), - 'Oops.', - 'Displays primary error message.' - ); - }); - test('errors are displayed when user deletion fails', async function (assert) { assert.expect(1); this.server.del('/users/:id', () => { From 8011c4e1a7c67f45c801de225de130f45ad1adce Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Sat, 26 Sep 2020 10:23:04 -0400 Subject: [PATCH 14/15] chore: fix broken translation strings in sessions table --- .../scopes/scope/projects/project/sessions/index.hbs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs b/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs index af5ee3555..a34ceb077 100644 --- a/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs +++ b/ui/core/app/templates/scopes/scope/projects/project/sessions/index.hbs @@ -17,8 +17,8 @@ {{t "form.id.label"}} - {{t "resources.user"}} - {{t "resources.target"}} + {{t "resources.user.title"}} + {{t "resources.target.title"}} {{t "form.started.label"}} {{t "form.status.label"}} {{t "titles.actions"}} From 00e6d2c0515241988584d513c8a11b54f4b6f8ed Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Sat, 26 Sep 2020 10:30:27 -0400 Subject: [PATCH 15/15] chore: fix broken translation key --- ui/core/app/components/form/host-set/add-hosts/index.hbs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/core/app/components/form/host-set/add-hosts/index.hbs b/ui/core/app/components/form/host-set/add-hosts/index.hbs index 09be10a5b..bb1cb7a91 100644 --- a/ui/core/app/components/form/host-set/add-hosts/index.hbs +++ b/ui/core/app/components/form/host-set/add-hosts/index.hbs @@ -43,9 +43,9 @@ {{#unless this.hasAvailableHosts}} - + - {{t "resources.host-set.messages.add-hosts.description"}} + {{t "resources.host-set.host.messages.add.description"}}