aptible-rails 0.6.0 → 0.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/aptible/rails/controller.rb +31 -1
- data/lib/aptible/rails/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 44621b35394c6b27b73cf8d00ad4de82dab2bee4
|
|
4
|
+
data.tar.gz: 1eb6479abc4b2bc8992574ac54bf97ca8fd99244
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d4aed36b1b17b1815d38e24656d8315a3d60c9cff8307d0d0fb55789aa5288c6d2e97bbec59760854fa9a1dbe116e2f5369df6ced3c1274e2abae8e3224c816b
|
|
7
|
+
data.tar.gz: 2e053c41da75bf9d659c32b5bfba138c91c63e4f7b3e6ef576407adb3012c31ed995cd706792bdcd2050a68699d9bb2020b950c472e67104c15115aa928f7136
|
|
@@ -9,7 +9,9 @@ module Aptible
|
|
|
9
9
|
|
|
10
10
|
included do
|
|
11
11
|
helper_method :current_user, :current_organization, :user_url,
|
|
12
|
-
:organization_url, :criterion_by_handle, :auth_url
|
|
12
|
+
:organization_url, :criterion_by_handle, :auth_url,
|
|
13
|
+
:risk_criterion, :policy_criterion, :security_criterion,
|
|
14
|
+
:training_criterion, :url_helpers
|
|
13
15
|
end
|
|
14
16
|
|
|
15
17
|
def current_user
|
|
@@ -131,6 +133,34 @@ module Aptible
|
|
|
131
133
|
uri.query = params.to_query if params
|
|
132
134
|
uri.to_s
|
|
133
135
|
end
|
|
136
|
+
|
|
137
|
+
def risk_criterion
|
|
138
|
+
@risk_criterion ||=
|
|
139
|
+
criterion_by_handle(:risk_assessment).decorate
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
def security_criterion
|
|
143
|
+
@security_criterion ||=
|
|
144
|
+
criterion_by_handle(:app_security_interview).decorate
|
|
145
|
+
end
|
|
146
|
+
|
|
147
|
+
def policy_criterion
|
|
148
|
+
@policy_criterion ||= criterion_by_handle(:policy_manual).decorate
|
|
149
|
+
end
|
|
150
|
+
|
|
151
|
+
def training_criterion
|
|
152
|
+
@training_criterion ||= criterion_by_handle('training_log').decorate
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
def bootstrap_backbone
|
|
156
|
+
return unless current_user
|
|
157
|
+
|
|
158
|
+
gon.current_user = current_user.attributes
|
|
159
|
+
gon.security_officer = current_organization.security_officer.attributes
|
|
160
|
+
gon.current_organization = current_organization.attributes
|
|
161
|
+
organization_users = current_organization.users
|
|
162
|
+
gon.current_organization_users = organization_users.map(&:attributes)
|
|
163
|
+
end
|
|
134
164
|
end
|
|
135
165
|
end
|
|
136
166
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: aptible-rails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.6.
|
|
4
|
+
version: 0.6.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Frank Macreery
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2014-11-
|
|
11
|
+
date: 2014-11-14 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: gem_config
|