card-mod-account 0.11.1 → 0.11.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/set/self/signin.rb +13 -20
- metadata +16 -11
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b83f29edd97e19f1ffa148f41b57c67f5009f421cf3266c6bf811a56231a1984
|
4
|
+
data.tar.gz: 0baee78e9eef9589305298abc04aca8f8714dfbfe8781e21b83f752fd9f74cae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f1782318b47b6e0d66830c9420e9116b3fd6bade7d3bc1366df2c8072dc87a0ce89048303afa0828ed4912f6a79676621d512ffde2f3e9e3231e9902e8144a9c
|
7
|
+
data.tar.gz: 5e2efc3bdec486d61f0ac557adc0cd9bc8ca5eb6db0f905e49a8f98d0dad61a8c68f10bd58ee7888a3a80dc235872b327794bbf0ac6ff69c6ff8eb8a83a24a4d
|
data/set/self/signin.rb
CHANGED
@@ -47,10 +47,6 @@ def recaptcha_on?
|
|
47
47
|
false
|
48
48
|
end
|
49
49
|
|
50
|
-
def i18n_signin key
|
51
|
-
I18n.t key, scope: "mod.card-mod-account.set.self.signin"
|
52
|
-
end
|
53
|
-
|
54
50
|
def authenticate_or_abort email, pword
|
55
51
|
abort_unless email, :email_missing
|
56
52
|
abort_unless pword, :password_missing
|
@@ -69,19 +65,19 @@ def failed_signin email
|
|
69
65
|
end
|
70
66
|
|
71
67
|
def abort_unless value, error_key
|
72
|
-
abort :failure,
|
68
|
+
abort :failure, tr(error_key) unless value
|
73
69
|
end
|
74
70
|
|
75
71
|
def signin_error_message account
|
76
72
|
case
|
77
|
-
when account.nil? then
|
78
|
-
when !account.active? then
|
79
|
-
else
|
73
|
+
when account.nil? then tr :error_unknown_email
|
74
|
+
when !account.active? then tr :error_not_active
|
75
|
+
else tr :error_wrong_password
|
80
76
|
end
|
81
77
|
end
|
82
78
|
|
83
79
|
def error_on field, error_key
|
84
|
-
errors.add field,
|
80
|
+
errors.add field, tr(error_key)
|
85
81
|
end
|
86
82
|
|
87
83
|
def account_for email
|
@@ -135,7 +131,7 @@ format :html do
|
|
135
131
|
|
136
132
|
# FIXME: need a generic solution for this
|
137
133
|
view :title do
|
138
|
-
voo.title ||=
|
134
|
+
voo.title ||= tr :sign_in_title
|
139
135
|
super()
|
140
136
|
end
|
141
137
|
|
@@ -150,7 +146,7 @@ format :html do
|
|
150
146
|
|
151
147
|
view :reset_password_success do
|
152
148
|
# 'Check your email for a link to reset your password'
|
153
|
-
frame {
|
149
|
+
frame { tr :check_email }
|
154
150
|
end
|
155
151
|
|
156
152
|
view :signin_buttons do
|
@@ -166,14 +162,14 @@ format :html do
|
|
166
162
|
end
|
167
163
|
|
168
164
|
def reset_password_voo
|
169
|
-
voo.title ||=
|
165
|
+
voo.title ||= tr :forgot_password
|
170
166
|
voo.edit_structure = [signin_field(:email)]
|
171
167
|
voo.hide :help
|
172
168
|
end
|
173
169
|
|
174
170
|
view :edit_buttons do
|
175
|
-
|
176
|
-
|
171
|
+
button_tag tr(:reset_my_password),
|
172
|
+
situation: "primary", class: "_close-modal-on-success"
|
177
173
|
end
|
178
174
|
|
179
175
|
def signin_success
|
@@ -181,18 +177,15 @@ format :html do
|
|
181
177
|
end
|
182
178
|
|
183
179
|
def signin_button
|
184
|
-
|
185
|
-
button_tag text, situation: "primary"
|
180
|
+
button_tag tr(:sign_in), situation: "primary"
|
186
181
|
end
|
187
182
|
|
188
183
|
def signup_link
|
189
|
-
|
190
|
-
subformat(Card[:account_links]).render! :sign_up, title: text
|
184
|
+
subformat(Card[:account_links]).render! :sign_up, title: tr(:or_sign_up)
|
191
185
|
end
|
192
186
|
|
193
187
|
def reset_password_link
|
194
|
-
|
195
|
-
link = link_to_view :edit, text, path: { slot: { hide: :bridge_link } }
|
188
|
+
link = link_to_view :edit, tr(:reset_password), path: { slot: { hide: :bridge_link } }
|
196
189
|
# FIXME: inline styling
|
197
190
|
raw("<div style='float:right'>#{link}</div>")
|
198
191
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: card-mod-account
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.11.
|
4
|
+
version: 0.11.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ethan McCutchen
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2021-03-
|
13
|
+
date: 2021-03-15 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: card
|
@@ -18,56 +18,56 @@ dependencies:
|
|
18
18
|
requirements:
|
19
19
|
- - '='
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: 1.101.
|
21
|
+
version: 1.101.2
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
26
|
- - '='
|
27
27
|
- !ruby/object:Gem::Version
|
28
|
-
version: 1.101.
|
28
|
+
version: 1.101.2
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: card-mod-email
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
33
|
- - '='
|
34
34
|
- !ruby/object:Gem::Version
|
35
|
-
version: 0.11.
|
35
|
+
version: 0.11.2
|
36
36
|
type: :runtime
|
37
37
|
prerelease: false
|
38
38
|
version_requirements: !ruby/object:Gem::Requirement
|
39
39
|
requirements:
|
40
40
|
- - '='
|
41
41
|
- !ruby/object:Gem::Version
|
42
|
-
version: 0.11.
|
42
|
+
version: 0.11.2
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: card-mod-permissions
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
47
|
- - '='
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: 0.11.
|
49
|
+
version: 0.11.2
|
50
50
|
type: :runtime
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
54
|
- - '='
|
55
55
|
- !ruby/object:Gem::Version
|
56
|
-
version: 0.11.
|
56
|
+
version: 0.11.2
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: card-mod-list
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
61
|
- - '='
|
62
62
|
- !ruby/object:Gem::Version
|
63
|
-
version: 0.11.
|
63
|
+
version: 0.11.2
|
64
64
|
type: :runtime
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
68
|
- - '='
|
69
69
|
- !ruby/object:Gem::Version
|
70
|
-
version: 0.11.
|
70
|
+
version: 0.11.2
|
71
71
|
description: ''
|
72
72
|
email:
|
73
73
|
- info@decko.org
|
@@ -97,10 +97,15 @@ files:
|
|
97
97
|
- set/type/user.rb
|
98
98
|
- set/type/user/setup_help.haml
|
99
99
|
- set/type_plus_right/user/email.rb
|
100
|
-
homepage:
|
100
|
+
homepage: https://decko.org
|
101
101
|
licenses:
|
102
102
|
- GPL-3.0
|
103
103
|
metadata:
|
104
|
+
source_code_uri: https://github.com/decko-commons/decko
|
105
|
+
homepage_uri: https://decko.org
|
106
|
+
bug_tracker_uri: https://github.com/decko-commons/decko/issues
|
107
|
+
wiki_uri: https://decko.org
|
108
|
+
documentation_url: http://docs.decko.org/
|
104
109
|
card-mod: account
|
105
110
|
post_install_message:
|
106
111
|
rdoc_options: []
|