conjur-asset-ui 1.3.0 → 1.3.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +3 -1
  3. data/.jshintrc +41 -0
  4. data/Gemfile +3 -1
  5. data/README.md +34 -0
  6. data/Rakefile +69 -1
  7. data/bower.json +93 -0
  8. data/conjur-asset-ui.gemspec +1 -1
  9. data/features/navigation_bar.feature +31 -0
  10. data/features/step_definitions/custom_step.rb +32 -0
  11. data/features/support/env.rb +38 -0
  12. data/features/support/hooks.rb +30 -0
  13. data/features/support/world.rb +17 -0
  14. data/gulpfile.js +140 -0
  15. data/lib/conjur/command/ui.rb +1 -1
  16. data/lib/conjur/webserver/server.rb +14 -9
  17. data/lib/conjur-asset-ui-version.rb +1 -1
  18. data/package.json +47 -0
  19. data/preprocessor.js +7 -0
  20. data/public/_client_libs.html +2 -15
  21. data/public/css/styles.less +170 -4
  22. data/public/index.html.erb +5 -7
  23. data/public/js/init.js +183 -97
  24. data/public/js/lib/sorted-set.no-require.js +3 -28
  25. data/public/js/models/groupRecord.js +12 -11
  26. data/public/js/models/hostRecord.js +6 -7
  27. data/public/js/models/layerRecord.js +12 -11
  28. data/public/js/models/namespace.js +2 -0
  29. data/public/js/models/policyList.js +3 -1
  30. data/public/js/models/policyRecord.js +6 -7
  31. data/public/js/models/record.js +24 -23
  32. data/public/js/models/resourceList.js +28 -10
  33. data/public/js/models/userList.js +7 -2
  34. data/public/js/models/userRecord.js +7 -8
  35. data/public/js/models/variableList.js +18 -7
  36. data/public/js/models/variableRecord.js +13 -12
  37. data/public/js/routers.js +72 -26
  38. data/public/js/views/annotations.js +38 -27
  39. data/public/js/views/audit.js +23 -17
  40. data/public/js/views/chart.js +471 -0
  41. data/public/js/views/dashboard.js +94 -58
  42. data/public/js/views/generic.js +16 -9
  43. data/public/js/views/group.js +94 -55
  44. data/public/js/views/groups.js +3 -7
  45. data/public/js/views/host.js +75 -44
  46. data/public/js/views/hosts.js +2 -6
  47. data/public/js/views/layer.js +127 -82
  48. data/public/js/views/layers.js +2 -6
  49. data/public/js/views/mixins/search.js +12 -5
  50. data/public/js/views/mixins/tabs.js +95 -55
  51. data/public/js/views/navSearch.js +16 -5
  52. data/public/js/views/owned.js +14 -8
  53. data/public/js/views/permissions.js +244 -178
  54. data/public/js/views/policies.js +2 -4
  55. data/public/js/views/policy.js +65 -38
  56. data/public/js/views/resource.js +49 -34
  57. data/public/js/views/role.js +52 -37
  58. data/public/js/views/searchResults.js +205 -138
  59. data/public/js/views/time.js +26 -13
  60. data/public/js/views/user.js +178 -55
  61. data/public/js/views/users.js +2 -7
  62. data/public/js/views/variable.js +226 -45
  63. data/public/js/views/variables.js +4 -8
  64. metadata +20 -20
  65. data/public/_client_code.html +0 -42
  66. data/public/css/bootstrap.css +0 -7
  67. data/public/fonts/glyphicons-halflings-regular.eot +0 -0
  68. data/public/fonts/glyphicons-halflings-regular.svg +0 -229
  69. data/public/fonts/glyphicons-halflings-regular.ttf +0 -0
  70. data/public/fonts/glyphicons-halflings-regular.woff +0 -0
  71. data/public/js/lib/JSXTransformer.js +0 -10862
  72. data/public/js/lib/async.js +0 -958
  73. data/public/js/lib/backbone.js +0 -2
  74. data/public/js/lib/bootstrap.js +0 -6
  75. data/public/js/lib/less.js +0 -16
  76. data/public/js/lib/moment.js +0 -7768
  77. data/public/js/lib/react-bootstrap.js +0 -5346
  78. data/public/js/lib/react-bootstrap.min.js +0 -4
  79. data/public/js/lib/underscore-min.js +0 -6
  80. data/public/js/lib/underscore.string.min.js +0 -1
  81. data/public/js/main.js +0 -57
@@ -1,61 +1,100 @@
1
1
  /** @jsx React.DOM */
2
+ /* global conjur, React, ReactBootstrap, _ */
2
3
 
3
- var Group = React.createClass({
4
- mixins: [conjur.views.mixins.Tab],
5
- render: function() {
6
- var members = this.props.data.members.map(function (member) {
7
- return <li className="list-group-item list-group-item-noborder">
8
- <RoleLink id={member.member} />
9
- </li>
10
- }.bind(this));
11
- var resourceId = [ conjur.app.configuration.account, 'group', this.props.data.group.id ].join(':')
12
- var group = this.props.data.group;
13
-
14
-
15
- // TODO: refactor (common code should go to mixins)
16
- // TODO: memberships
17
- // TODO: controls for members management
18
- var overview_tab =
19
- <TabPane key="overview" tab="Overview">
4
+ (function(conjur, React, ReactBootstrap, _) {
5
+ 'use strict';
6
+
7
+ var TabbedArea = ReactBootstrap.TabbedArea,
8
+ TabPane = ReactBootstrap.TabPane,
9
+ Tab = conjur.views.mixins.Tab,
10
+ AuditBox = window.AuditBox,
11
+ RoleLink = conjur.views.RoleLink;
12
+
13
+ this.Group = React.createClass({
14
+ mixins: [Tab],
15
+
16
+ render: function() {
17
+ var data = this.props.data;
18
+
19
+ var members = data.members.map(function(member) {
20
+ return (
21
+ <li className="list-group-item list-group-item-noborder">
22
+ <RoleLink id={member.member} />
23
+ </li>
24
+ );
25
+ });
26
+
27
+ var resourceId = [
28
+ conjur.app.configuration.account,
29
+ 'group',
30
+ data.group.id
31
+ ].join(':');
32
+
33
+ var group = data.group;
34
+
35
+ // TODO: refactor (common code should go to mixins)
36
+ // TODO: memberships
37
+ // TODO: controls for members management
38
+ var overviewTab =(
39
+ <TabPane key="overview" tab="Overview">
20
40
  <dl className="dl-horizontal">
21
41
  <dt>Created by</dt>
22
- <dd><RoleLink id={group.userid}/></dd>
42
+ <dd><RoleLink id={group.userid} /></dd>
43
+
23
44
  <dt>Owner</dt>
24
- <dd><RoleLink id={this.props.data.group.ownerid}/></dd>
45
+ <dd><RoleLink id={data.group.ownerid} /></dd>
25
46
  </dl>
26
- </TabPane>;
27
- var members_tab =
28
- <TabPane key="members" tab={get_tabname("Members",members)}>
29
- <ul className="list-group">
30
- {members}
31
- </ul>
32
- </TabPane>;
33
- var owned_tab = this.owned_tab();
34
- var memberships_tab = this.memberships_tab(group.roleid);
35
- var permissions_tab = this.permissions_tab(group.roleid);
36
- var annotations_tab = this.annotations_tab();
37
-
38
- var audit_tab =
39
- <TabPane key="audit" tab="Recent Activity">
40
- <div className="audit auditGroup">
41
- <AuditBox roles={[resourceId]} resources={[resourceId]} tabview={true}/>
42
- </div>
43
- </TabPane>;
44
-
45
- <TabPane key="annotations" tab={get_tabname("Annotations",this.props.data.annotations)}>
46
- <AnnotationsBox annotations={this.props.data.annotations}/>
47
- </TabPane>;
48
-
49
- var tabs = _.compact([overview_tab, members_tab, owned_tab, memberships_tab,
50
- permissions_tab, annotations_tab, audit_tab]);
51
-
52
- return (
53
- <div className="group">
54
- <h2>Group {this.props.data.group.id}</h2>
55
- <TabbedArea defaultActiveKey="overview">
56
- {tabs}
57
- </TabbedArea>
58
- </div>
59
- );
60
- }
61
- });
47
+ </TabPane>
48
+ );
49
+
50
+ var membersTab = (
51
+ <TabPane key="members" tab={conjur.utils.getTabname('Members', members)}>
52
+ <ul className="list-group">
53
+ {members}
54
+ </ul>
55
+ </TabPane>
56
+ );
57
+
58
+ var ownedTab = this.ownedTab(),
59
+ membershipsTab = this.membershipsTab(group.roleid),
60
+ permissionsTab = this.permissionsTab(group.roleid),
61
+ annotationsTab = this.annotationsTab();
62
+
63
+ var auditTab = (
64
+ <TabPane key="audit" tab="Recent Activity">
65
+ <div className="audit auditGroup">
66
+ <AuditBox roles={[resourceId]}
67
+ resources={[resourceId]}
68
+ tabview={true} />
69
+ </div>
70
+ </TabPane>
71
+ );
72
+
73
+ var tabs = _.compact([
74
+ overviewTab,
75
+ membersTab,
76
+ ownedTab,
77
+ membershipsTab,
78
+ permissionsTab,
79
+ annotationsTab,
80
+ auditTab
81
+ ]);
82
+
83
+ return (
84
+ <div className="group">
85
+ <h2>Group {data.group.id}</h2>
86
+ <TabbedArea defaultActiveKey="overview">
87
+ {tabs}
88
+ </TabbedArea>
89
+ </div>
90
+ );
91
+ }
92
+ });
93
+
94
+ }).bind(conjur.views)
95
+ (
96
+ conjur,
97
+ React,
98
+ ReactBootstrap,
99
+ _
100
+ );
@@ -1,22 +1,18 @@
1
1
  /** @jsx React.DOM */
2
+ /* global conjur, React */
2
3
 
3
4
  (function(conjur, React) {
4
5
  'use strict';
5
6
 
6
7
  var GenericList = conjur.views.GenericList;
7
8
 
8
- var GroupBox = this.GroupBox = React.createClass({
9
- /*getInitialState: function() {
10
- return { currentNamespace: "", members: [] };
11
- },*/
9
+ this.GroupBox = React.createClass({
12
10
  render: function() {
13
- //<NamespaceFilter currentNamespace={this.props.currentNamespace}
14
- // namespaces={this.props.data.namespaces} />
15
11
  return (
16
12
  <div className="groupBox">
17
13
  <div className="groupList">
18
14
  <h2>Groups</h2>
19
- <GenericList data={{kind: "groups", members: this.props.data.members}} />
15
+ <GenericList data={{kind: 'groups', members: this.props.data.members}} />
20
16
  </div>
21
17
  </div>
22
18
  );
@@ -1,64 +1,95 @@
1
1
  /** @jsx React.DOM */
2
+ /* global conjur, React, ReactBootstrap, _ */
2
3
 
3
- var HostLink = React.createClass({
4
- hostId : function() {
5
- return this.props.data.split(':')[2];
6
- },
4
+ (function(conjur, React, ReactBootstrap, _) {
5
+ 'use strict';
7
6
 
8
- hostUrl: function() {
9
- return "/ui/hosts/" + encodeURIComponent(this.hostId());
10
- },
7
+ var TabbedArea = ReactBootstrap.TabbedArea,
8
+ TabPane = ReactBootstrap.TabPane,
9
+ Tab = conjur.views.mixins.Tab,
10
+ AuditBox = window.AuditBox,
11
+ RoleLink = conjur.views.RoleLink,
12
+ Time = conjur.views.Time;
11
13
 
12
- render: function() {
13
- return (
14
- <a href={this.hostUrl()}>
15
- {this.hostId()}
16
- </a>
17
- );
18
- }
19
- });
14
+ this.HostLink = React.createClass({
15
+ hostId : function() {
16
+ return this.props.data.split(':')[2];
17
+ },
20
18
 
21
- var Host = React.createClass({
22
- mixins: [conjur.views.mixins.Tab],
23
- render: function(){
24
- var host = this.props.data.host;
19
+ hostUrl: function() {
20
+ return '/ui/hosts/' + window.encodeURIComponent(this.hostId());
21
+ },
25
22
 
26
- // TODO: control for 'enroll'
27
- var overview_tab =
28
- <TabPane key="overview" tab="Overview">
23
+ render: function() {
24
+ return (
25
+ <a href={this.hostUrl()}>
26
+ {this.hostId()}
27
+ </a>
28
+ );
29
+ }
30
+ });
31
+
32
+ this.Host = React.createClass({
33
+ mixins: [Tab],
34
+
35
+ render: function() {
36
+ var host = this.props.data.host;
37
+
38
+ // TODO: control for 'enroll'
39
+ var overviewTab = (
40
+ <TabPane key="overview" tab="Overview">
29
41
  <dl className="dl-horizontal">
30
42
  <dt> Owner </dt>
31
43
  <dd> <RoleLink id={host.ownerid}/> </dd>
44
+
32
45
  <dt>Created by</dt>
33
46
  <dd><RoleLink id={host.userid}/></dd>
47
+
34
48
  <dt> Created At </dt>
35
49
  <dd> <Time timestamp={host.created_at}/> </dd>
36
50
  </dl>
37
- </TabPane>;
51
+ </TabPane>
52
+ );
38
53
 
39
- var permissions_tab = this.permissions_tab(host.roleid);
40
- var memberships_tab = this.memberships_tab(host.roleid);
41
- var annotations_tab = this.annotations_tab();
42
- var owned_tab = this.owned_tab();
54
+ var permissionsTab = this.permissionsTab(host.roleid),
55
+ membershipsTab = this.membershipsTab(host.roleid),
56
+ annotationsTab = this.annotationsTab(),
57
+ ownedTab = this.ownedTab();
43
58
 
44
- var audit_tab =
45
- <TabPane key="audit" tab="Recent Activity">
59
+ var auditTab = (
60
+ <TabPane key="audit" tab="Recent Activity">
46
61
  <div className="audit auditHost">
47
- <AuditBox roles={[host.roleid]} resources={[host.resource_identifier]} tabview={true}/>
62
+ <AuditBox roles={[host.roleid]}
63
+ resources={[host.resource_identifier]}
64
+ tabview={true} />
48
65
  </div>
49
- </TabPane>;
66
+ </TabPane>
67
+ );
68
+
69
+ var tabs = _.compact([
70
+ overviewTab,
71
+ ownedTab,
72
+ membershipsTab,
73
+ permissionsTab,
74
+ annotationsTab,
75
+ auditTab
76
+ ]);
50
77
 
51
- var tabs = _.compact([ overview_tab, owned_tab, memberships_tab,
52
- permissions_tab, annotations_tab, audit_tab
53
- ]);
78
+ return (
79
+ <div className="host">
80
+ <h2> Host {host.id} </h2>
81
+ <TabbedArea defaultActiveKey="overview">
82
+ {tabs}
83
+ </TabbedArea>
84
+ </div>
85
+ );
86
+ }
87
+ });
54
88
 
55
- return (
56
- <div className="host">
57
- <h2> Host {host.id} </h2>
58
- <TabbedArea defaultActiveKey="overview">
59
- {tabs}
60
- </TabbedArea>
61
- </div>
62
- );
63
- }
64
- })
89
+ }).bind(conjur.views)
90
+ (
91
+ conjur,
92
+ React,
93
+ ReactBootstrap,
94
+ _
95
+ );
@@ -1,17 +1,13 @@
1
1
  /** @jsx React.DOM */
2
+ /* global conjur, React */
2
3
 
3
4
  (function(conjur, React) {
4
5
  'use strict';
5
6
 
6
7
  var GenericList = conjur.views.GenericList;
7
8
 
8
- var HostBox = this.HostBox = React.createClass({
9
- /*getInitialState: function() {
10
- return { currentNamespace: "", members: [] };
11
- },*/
9
+ this.HostBox = React.createClass({
12
10
  render: function() {
13
- //<NamespaceFilter currentNamespace={this.props.currentNamespace}
14
- //namespaces={this.props.data.namespaces} />
15
11
  return (
16
12
  <div className="hostBox">
17
13
  <div className="hostList">
@@ -1,92 +1,137 @@
1
1
  /** @jsx React.DOM */
2
+ /* global conjur, React, ReactBootstrap, _ */
2
3
 
3
- var Layer = React.createClass({
4
- mixins: [conjur.views.mixins.Tab],
5
- render: function() {
6
- function abstractRole(expected) {
7
- return function(role) {
8
- var tokens = role.split(':');
9
- var kind = tokens[1];
10
- var abstractKinds = [ '@', 'layer' ];
11
- var isAbstract = abstractKinds.indexOf(kind) !== -1;
12
- return isAbstract === expected;
13
- }
14
- }
15
-
16
- var layer = this.props.data.layer;
17
-
18
- var hosts = layer.hosts.map(function (host) {
19
- return <li className="list-group-item list-group-item-noborder">
20
- <HostLink data={host} />
21
- </li>
22
- }.bind(this));
23
- var admins = this.props.data.admins.filter(abstractRole(false)).map(function (role) {
24
- return <li className="list-group-item list-group-item-noborder">
25
- <RoleLink id={role}/>
26
- </li>;
27
- }.bind(this));
28
- var users = this.props.data.users.filter(abstractRole(false)).map(function (role) {
29
- return <li className="list-group-item list-group-item-noborder">
30
- <RoleLink id={role}/>
31
- </li>;
32
- }.bind(this));
33
-
34
-
35
- // TODO: controls to add/remove admins/users/hosts
36
- var overview_tab =
37
- <TabPane key="overview" tab="Overview">
38
- <dl className="dl-horizontal">
39
- <dt>Owner</dt>
40
- <dd><RoleLink id={layer.ownerid}/></dd>
41
- <dt>Created by</dt>
42
- <dd><RoleLink id={layer.userid}/></dd>
43
- </dl>
44
- </TabPane>;
45
- var admins_tab =
46
- <TabPane key="admins" tab={get_tabname("Admins",admins)}>
47
- <ul className="list-group">
48
- {admins}
49
- </ul>
50
- </TabPane> ;
51
- var users_tab =
52
- <TabPane key="users" tab={ get_tabname("Users", users) } >
4
+ (function(conjur, React, ReactBootstrap, _) {
5
+ 'use strict';
6
+
7
+ var TabbedArea = ReactBootstrap.TabbedArea,
8
+ TabPane = ReactBootstrap.TabPane,
9
+ Tab = conjur.views.mixins.Tab,
10
+ AuditBox = window.AuditBox,
11
+ RoleLink = conjur.views.RoleLink,
12
+ HostLink = conjur.views.HostLink;
13
+
14
+ var abstractRole = function(expected) {
15
+ return function(role) {
16
+ var tokens = role.split(':'),
17
+ kind = tokens[1],
18
+ abstractKinds = ['@', 'layer'],
19
+ isAbstract = abstractKinds.indexOf(kind) !== -1;
20
+
21
+ return isAbstract === expected;
22
+ };
23
+ };
24
+
25
+ this.Layer = React.createClass({
26
+ mixins: [Tab],
27
+
28
+ render: function() {
29
+ var data = this.props.data;
30
+
31
+ var hosts = data.layer.hosts.map(function(host) {
32
+ return (
33
+ <li className="list-group-item list-group-item-noborder">
34
+ <HostLink data={host} />
35
+ </li>
36
+ );
37
+ });
38
+
39
+ var admins = data.admins.filter(abstractRole(false)).map(function(role) {
40
+ return (
41
+ <li className="list-group-item list-group-item-noborder">
42
+ <RoleLink id={role}/>
43
+ </li>
44
+ );
45
+ });
46
+
47
+ var users = data.users.filter(abstractRole(false)).map(function(role) {
48
+ return (
49
+ <li className="list-group-item list-group-item-noborder">
50
+ <RoleLink id={role}/>
51
+ </li>
52
+ );
53
+ });
54
+
55
+ // TODO: controls to add/remove admins/users/hosts
56
+ var overviewTab = (
57
+ <TabPane key="overview" tab="Overview">
58
+ <dl className="dl-horizontal">
59
+ <dt>Owner</dt>
60
+ <dd><RoleLink id={data.layer.ownerid} /></dd>
61
+
62
+ <dt>Created by</dt>
63
+ <dd><RoleLink id={data.layer.userid} /></dd>
64
+ </dl>
65
+ </TabPane>
66
+ );
67
+
68
+ var adminsTab = (
69
+ <TabPane key="admins" tab={conjur.utils.getTabname('Admins', admins)}>
70
+ <ul className="list-group">
71
+ {admins}
72
+ </ul>
73
+ </TabPane>
74
+ );
75
+
76
+ var usersTab = (
77
+ <TabPane key="users" tab={conjur.utils.getTabname('Users', users)}>
53
78
  <ul className="list-group">
54
79
  {users}
55
80
  </ul>
56
- </TabPane>;
57
- var hosts_tab =
58
- <TabPane key="hosts" tab={ get_tabname("Hosts", hosts) } >
81
+ </TabPane>
82
+ );
83
+
84
+ var hostsTab = (
85
+ <TabPane key="hosts" tab={conjur.utils.getTabname('Hosts', hosts)}>
59
86
  <ul className="list-group">
60
87
  {hosts}
61
88
  </ul>
62
- </TabPane>;
63
- var audit_tab=
64
- <TabPane key="audit" tab="Recent Activity">
89
+ </TabPane>
90
+ );
91
+
92
+ var auditTab = (
93
+ <TabPane key="audit" tab="Recent Activity">
65
94
  <div className="audit auditGroup">
66
- <AuditBox roles={[layer.roleid]} resources={[layer.resource_identifier]} tabview={true} />
95
+ <AuditBox roles={[data.layer.roleid]}
96
+ resources={[data.layer.resource_identifier]}
97
+ tabview={true} />
67
98
  </div>
68
- </TabPane>;
69
-
70
-
71
- var permissions_tab = this.permissions_tab(layer.roleid);
72
- var memberships_tab = this.memberships_tab(layer.roleid);
73
- var annotations_tab = this.annotations_tab();
74
- var owned_tab = this.owned_tab();
75
-
76
- var tabs = _.compact( [overview_tab, admins_tab, users_tab, hosts_tab,
77
- owned_tab, memberships_tab, permissions_tab,
78
- annotations_tab,
79
- audit_tab
80
- ] );
81
-
82
- return (
83
- <div className="layer">
84
- <h2>Layer {layer.id}</h2>
85
-
86
- <TabbedArea defaultActiveKey="overview">
87
- {tabs}
88
- </TabbedArea>
89
- </div>
90
- );
91
- }
92
- });
99
+ </TabPane>
100
+ );
101
+
102
+
103
+ var permissionsTab = this.permissionsTab(data.layer.roleid),
104
+ membershipsTab = this.membershipsTab(data.layer.roleid),
105
+ annotationsTab = this.annotationsTab(),
106
+ ownedTab = this.ownedTab();
107
+
108
+ var tabs = _.compact([
109
+ overviewTab,
110
+ adminsTab,
111
+ usersTab,
112
+ hostsTab,
113
+ ownedTab,
114
+ membershipsTab,
115
+ permissionsTab,
116
+ annotationsTab,
117
+ auditTab
118
+ ]);
119
+
120
+ return (
121
+ <div className="layer">
122
+ <h2>Layer {data.layer.id}</h2>
123
+ <TabbedArea defaultActiveKey="overview">
124
+ {tabs}
125
+ </TabbedArea>
126
+ </div>
127
+ );
128
+ }
129
+ });
130
+
131
+ }).bind(conjur.views)
132
+ (
133
+ conjur,
134
+ React,
135
+ ReactBootstrap,
136
+ _
137
+ );
@@ -1,17 +1,13 @@
1
1
  /** @jsx React.DOM */
2
+ /* global conjur, React */
2
3
 
3
4
  (function(conjur, React) {
4
5
  'use strict';
5
6
 
6
7
  var GenericList = conjur.views.GenericList;
7
8
 
8
- var LayerBox = this.LayerBox = React.createClass({
9
- /* getInitialState: function() {
10
- return { currentNamespace: "", members: [] };
11
- }, */
9
+ this.LayerBox = React.createClass({
12
10
  render: function() {
13
- // <NamespaceFilter currentNamespace={this.props.currentNamespace}
14
- // namespaces={this.props.data.namespaces} />
15
11
  return (
16
12
  <div className="layerBox">
17
13
  <div className="layerList">
@@ -1,15 +1,22 @@
1
+ /* global conjur */
2
+
1
3
  (function(conjur) {
2
4
  'use strict';
3
5
 
4
- conjur.views.mixins.Search = {
5
- handleSubmit: function(e) {
6
+ this.Search = {
7
+ handleSubmit: function() {
6
8
  var search = this.refs.input.getDOMNode().value;
7
9
 
8
- if (search && search.length != 0) {
9
- conjur.app.router.navigate('/ui/search/' + encodeURIComponent(search), {trigger: true});
10
+ if (search && search.length !== 0) {
11
+ conjur.app.router.navigate('/ui/search/' + window.encodeURIComponent(search),
12
+ {trigger: true});
10
13
  }
11
14
 
12
15
  return false;
13
16
  }
14
17
  };
15
- })(conjur);
18
+
19
+ }).bind(conjur.views.mixins)
20
+ (
21
+ conjur
22
+ );