Merge branch 'ICU-547-hostsets-in-target' into feature-target-host-set-custom-methods
This commit is contained in:
7 files changed
+73
-44
No files matched your search
@@ -0,0 +1,19 @@
|
||||
import Controller from '@ember/controller';
|
||||
import { inject as service } from '@ember/service';
|
||||
|
||||
export default class ScopesScopeProjectsProjectTargetsTargetHostSetsController extends Controller {
|
||||
|
||||
// =services
|
||||
|
||||
@service intl;
|
||||
|
||||
// =attributes
|
||||
|
||||
/**
|
||||
* Host sets breadcrumb
|
||||
* @type {string}
|
||||
*/
|
||||
get breadCrumb() {
|
||||
return this.intl.t('resources.host-sets');
|
||||
}
|
||||
}
|
||||
@@ -1,33 +1,41 @@
|
||||
{{title (t "resources.host-sets")}}
|
||||
|
||||
<Rose::Table as |table|>
|
||||
<table.header as |header|>
|
||||
<header.row as |row|>
|
||||
<row.headerCell>{{t "form.label.name"}}</row.headerCell>
|
||||
<row.headerCell>{{t "form.label.type"}}</row.headerCell>
|
||||
<row.headerCell>{{t "form.label.id"}}</row.headerCell>
|
||||
</header.row>
|
||||
</table.header>
|
||||
<table.body as |body|>
|
||||
{{#each @model as |hostSet|}}
|
||||
<body.row as |row|>
|
||||
<row.headerCell>
|
||||
<LinkTo
|
||||
@route="scopes.scope.projects.project.targets.target.host-sets.host-set"
|
||||
@model={{hostSet}}
|
||||
>
|
||||
{{hostSet.displayName}}
|
||||
</LinkTo>
|
||||
<p>{{hostSet.description}}</p>
|
||||
</row.headerCell>
|
||||
<row.cell>
|
||||
<Rose::Badge @style="outline">{{hostSet.type}}</Rose::Badge>
|
||||
</row.cell>
|
||||
<row.cell>
|
||||
<code>{{hostSet.id}}</code>
|
||||
</row.cell>
|
||||
</body.row>
|
||||
{{/each}}
|
||||
</table.body>
|
||||
</Rose::Table>
|
||||
{{#if @model}}
|
||||
|
||||
<Rose::Table as |table|>
|
||||
<table.header as |header|>
|
||||
<header.row as |row|>
|
||||
<row.headerCell>{{t "form.label.name"}}</row.headerCell>
|
||||
<row.headerCell>{{t "form.label.type"}}</row.headerCell>
|
||||
<row.headerCell>{{t "form.label.id"}}</row.headerCell>
|
||||
</header.row>
|
||||
</table.header>
|
||||
<table.body as |body|>
|
||||
{{#each @model as |hostSet|}}
|
||||
<body.row as |row|>
|
||||
<row.headerCell>
|
||||
{{hostSet.displayName}}
|
||||
<p>{{hostSet.description}}</p>
|
||||
</row.headerCell>
|
||||
<row.cell>
|
||||
<Rose::Badge @style="outline">{{hostSet.type}}</Rose::Badge>
|
||||
</row.cell>
|
||||
<row.cell>
|
||||
<code>{{hostSet.id}}</code>
|
||||
</row.cell>
|
||||
</body.row>
|
||||
{{/each}}
|
||||
</table.body>
|
||||
</Rose::Table>
|
||||
|
||||
{{else}}
|
||||
|
||||
<Rose::Layout::Centered>
|
||||
<Rose::Message @title={{t "titles.target-host-sets-welcome"}} as |message|>
|
||||
<message.description>
|
||||
{{t "descriptions.target-host-sets-welcome"}}
|
||||
</message.description>
|
||||
</Rose::Message>
|
||||
</Rose::Layout::Centered>
|
||||
|
||||
{{/if}}
|
||||
@@ -1 +0,0 @@
|
||||
Target/host-sets
|
||||
@@ -6,7 +6,7 @@ import { random, date } from 'faker';
|
||||
*/
|
||||
export default Factory.extend({
|
||||
|
||||
protocol: 'SSH',
|
||||
protocol: 'tcp',
|
||||
name: () => random.words(),
|
||||
description: () => random.words(),
|
||||
created_time: () => date.recent(),
|
||||
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
import { module, test } from 'qunit';
|
||||
import { setupTest } from 'ember-qunit';
|
||||
|
||||
module('Unit | Controller | scopes/scope/projects/project/targets/target/host-sets', function(hooks) {
|
||||
setupTest(hooks);
|
||||
|
||||
// Replace this with your real tests.
|
||||
test('it exists', function(assert) {
|
||||
let controller = this.owner.lookup('controller:scopes/scope/projects/project/targets/target/host-sets');
|
||||
assert.ok(controller);
|
||||
});
|
||||
});
|
||||
-11
@@ -1,11 +0,0 @@
|
||||
import { module, test } from 'qunit';
|
||||
import { setupTest } from 'ember-qunit';
|
||||
|
||||
module('Unit | Route | scopes/scope/projects/project/targets/target/host-sets/index', function(hooks) {
|
||||
setupTest(hooks);
|
||||
|
||||
test('it exists', function(assert) {
|
||||
let route = this.owner.lookup('route:scopes/scope/projects/project/targets/target/host-sets/index');
|
||||
assert.ok(route);
|
||||
});
|
||||
});
|
||||
@@ -36,7 +36,7 @@ host-set:
|
||||
static: Static
|
||||
target:
|
||||
protocols:
|
||||
SSH: SSH
|
||||
tcp: TCP
|
||||
host:
|
||||
types:
|
||||
static: Static
|
||||
@@ -79,6 +79,7 @@ titles:
|
||||
groups-welcome: Welcome to Groups
|
||||
auth-methods-welcome: Welcome to Auth Methods
|
||||
targets-welcome: Create your first Target
|
||||
target-host-sets-welcome: No Host Sets Associated
|
||||
grants: Permissions
|
||||
new-grant: New Grant
|
||||
principals: Principals
|
||||
@@ -99,6 +100,7 @@ descriptions:
|
||||
groups-welcome: Groups are collections of users.
|
||||
auth-methods-welcome: Auth methods are configurations to authenticate 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.
|
||||
states:
|
||||
info: Info
|
||||
|
||||
Reference in new issue
Block a user