login_sugar_generator 0.9.4
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.
- data/USAGE +32 -0
- data/login_sugar_generator.rb +79 -0
- data/templates/README +194 -0
- data/templates/_view_edit.rhtml +30 -0
- data/templates/_view_password.rhtml +21 -0
- data/templates/clock.rb +14 -0
- data/templates/controller.rb +179 -0
- data/templates/controller_test.rb +254 -0
- data/templates/create_db +7 -0
- data/templates/default_setup.zip +0 -0
- data/templates/helper.rb +41 -0
- data/templates/integration_test.rb +95 -0
- data/templates/layout.rhtml +13 -0
- data/templates/login_environment.rb +21 -0
- data/templates/login_system.rb +54 -0
- data/templates/migration_login_sugar.rb +21 -0
- data/templates/mock_clock.rb +14 -0
- data/templates/mock_notify.rb +16 -0
- data/templates/notify.rb +50 -0
- data/templates/notify_change_password.rhtml +10 -0
- data/templates/notify_delete.rhtml +5 -0
- data/templates/notify_forgot_password.rhtml +11 -0
- data/templates/notify_pending_delete.rhtml +9 -0
- data/templates/notify_signup.rhtml +12 -0
- data/templates/stylesheet.css +74 -0
- data/templates/user.rb +101 -0
- data/templates/user_model.erbsql +18 -0
- data/templates/user_test.rb +133 -0
- data/templates/users.yml +48 -0
- data/templates/view_change_password.rhtml +15 -0
- data/templates/view_edit.rhtml +19 -0
- data/templates/view_forgot_password.rhtml +19 -0
- data/templates/view_login.rhtml +24 -0
- data/templates/view_logout.rhtml +8 -0
- data/templates/view_signup.rhtml +14 -0
- data/templates/view_welcome.rhtml +10 -0
- metadata +80 -0
data/templates/users.yml
ADDED
@@ -0,0 +1,48 @@
|
|
1
|
+
# Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html
|
2
|
+
|
3
|
+
tesla:
|
4
|
+
id: 1000001
|
5
|
+
login: tesla
|
6
|
+
salted_password: ef94c16f6c124a4e84cc215c164767bfa25f6e92 # atest
|
7
|
+
salt: 7f8b036f9b647d46d22abdbfc8113f44a88f9889
|
8
|
+
email: tesla@example.com
|
9
|
+
verified: true
|
10
|
+
deleted: false
|
11
|
+
|
12
|
+
long_<%= singular_name %>:
|
13
|
+
id: 1000003
|
14
|
+
login: long_<%= singular_name %>
|
15
|
+
salted_password: c841391e1d29100a4920de7a8fbb4b0fd180c6c0 # alongtest
|
16
|
+
salt: c068e3671780f16898c0a8295ae8d82cc59713e2
|
17
|
+
email: long_<%= singular_name %>@example.com
|
18
|
+
verified: true
|
19
|
+
deleted: false
|
20
|
+
|
21
|
+
deletable_<%= singular_name %>:
|
22
|
+
id: 1000004
|
23
|
+
login: deletable_<%= singular_name %>
|
24
|
+
salted_password: c841391e1d29100a4920de7a8fbb4b0fd180c6c0 # alongtest
|
25
|
+
salt: c068e3671780f16898c0a8295ae8d82cc59713e2
|
26
|
+
email: deletable_<%= singular_name %>@example.com
|
27
|
+
verified: true
|
28
|
+
deleted: false
|
29
|
+
|
30
|
+
deleted_<%= singular_name %>:
|
31
|
+
id: 1000005
|
32
|
+
login: deleted_<%= singular_name %>
|
33
|
+
salted_password: ef94c16f6c124a4e84cc215c164767bfa25f6e92 # atest
|
34
|
+
salt: 7f8b036f9b647d46d22abdbfc8113f44a88f9889
|
35
|
+
email: deleted_<%= singular_name %>@example.com
|
36
|
+
verified: true
|
37
|
+
deleted: true
|
38
|
+
|
39
|
+
unverified_<%= singular_name %>:
|
40
|
+
id: 1000006
|
41
|
+
login: unverified_<%= singular_name %>
|
42
|
+
salted_password: ef94c16f6c124a4e84cc215c164767bfa25f6e92 # atest
|
43
|
+
salt: 7f8b036f9b647d46d22abdbfc8113f44a88f9889
|
44
|
+
email: unverified_<%= singular_name %>@example.com
|
45
|
+
verified: false
|
46
|
+
security_token: random_token_string
|
47
|
+
token_expiry: <%%= (Clock.now + 1.day) %> # for mysql, add .strftime("%y-%m-%d %H:%M:%S")
|
48
|
+
deleted: false
|
@@ -0,0 +1,15 @@
|
|
1
|
+
<div title="<%%= title_helper %>" class="form">
|
2
|
+
<%%= head_helper 'Change Password', :error => true %>
|
3
|
+
|
4
|
+
<div class="form-padding">
|
5
|
+
Enter your new password in the fields below and click 'Change Password' to have a new password sent to your email inbox.
|
6
|
+
|
7
|
+
<%%= start_form_tag_helper %>
|
8
|
+
<%%= render_partial 'password', :<%= singular_name %> => @<%= singular_name %>, :submit => false %>
|
9
|
+
<div class="button-bar">
|
10
|
+
<%%= submit_tag 'Change Password' %>
|
11
|
+
<%%= link_to 'Cancel', :action => 'welcome' %>
|
12
|
+
</div>
|
13
|
+
<%%= end_form_tag %>
|
14
|
+
</div>
|
15
|
+
</div>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<div title="<%%= title_helper %>" class="form">
|
2
|
+
<%%= head_helper 'Edit <%= class_name %>', :error => true %>
|
3
|
+
|
4
|
+
<%%= start_form_tag_helper %>
|
5
|
+
<%%= render_partial 'edit', :<%= singular_name %> => @<%= singular_name %>, :submit => true %>
|
6
|
+
<%%= end_form_tag %>
|
7
|
+
</br>
|
8
|
+
<%%= start_form_tag_helper %>
|
9
|
+
<%%= render_partial 'password', :submit => true %>
|
10
|
+
<%%= end_form_tag %>
|
11
|
+
|
12
|
+
<%%= start_form_tag_helper %>
|
13
|
+
<div class="<%= singular_name %>_delete">
|
14
|
+
<%%= hidden_field '<%= singular_name %>', 'form', :value => 'delete' %>
|
15
|
+
<%%= submit_tag 'Delete' %>
|
16
|
+
</div>
|
17
|
+
<%%= end_form_tag %>
|
18
|
+
</div>
|
19
|
+
</div>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<div title="<%%= title_helper %>" class="form">
|
2
|
+
<%%= head_helper 'Forgotten Password' %>
|
3
|
+
|
4
|
+
<div class="form-padding">
|
5
|
+
<p>
|
6
|
+
Enter your email address in the field below and click 'Reset Password'
|
7
|
+
to have instructions on how to retrieve your forgotten password emailed to you.
|
8
|
+
</p>
|
9
|
+
|
10
|
+
<%%= start_form_tag_helper %>
|
11
|
+
<%%= text_field '<%= singular_name %>', "email", :size => 30 %><br/>
|
12
|
+
|
13
|
+
<div class="button-bar">
|
14
|
+
<%%= submit_tag 'Send instructions' %>
|
15
|
+
<%%= link_to 'Cancel', :action => 'login' %>
|
16
|
+
</div>
|
17
|
+
<%%= end_form_tag %>
|
18
|
+
</div>
|
19
|
+
</div>
|
@@ -0,0 +1,24 @@
|
|
1
|
+
<div title="<%%= title_helper %>" class="form">
|
2
|
+
<%%= head_helper 'Please login' %>
|
3
|
+
|
4
|
+
<div class="form-padding">
|
5
|
+
<%%= start_form_tag_helper %>
|
6
|
+
<table>
|
7
|
+
<tr class="two_columns">
|
8
|
+
<td class="prompt"><label>Login:</label></td>
|
9
|
+
<td class="value"><%%= text_field '<%= singular_name %>', 'login', :size => 30 %></td>
|
10
|
+
</tr>
|
11
|
+
<tr class="two_columns">
|
12
|
+
<td class="prompt"><label>Password:</label></td>
|
13
|
+
<td class="value"><%%= password_field '<%= singular_name %>', 'password', :size => 30 %></td>
|
14
|
+
</tr>
|
15
|
+
</table>
|
16
|
+
|
17
|
+
<div class="button-bar">
|
18
|
+
<%%= submit_tag 'login' %>
|
19
|
+
<%%= link_to 'Register for an account', :action => 'signup' %> |
|
20
|
+
<%%= link_to 'Forgot my password', :action => 'forgot_password' %> </div>
|
21
|
+
<%%= end_form_tag %>
|
22
|
+
</div>
|
23
|
+
</div>
|
24
|
+
|
@@ -0,0 +1,14 @@
|
|
1
|
+
<div title="<%%= title_helper %>" class="form">
|
2
|
+
<%%= head_helper 'Sign Up', :error => true %>
|
3
|
+
|
4
|
+
<div class="form-padding">
|
5
|
+
<%%= start_form_tag_helper %>
|
6
|
+
<%%= render_partial 'edit', :<%= singular_name %> => @<%= singular_name %>, :submit => false %></br>
|
7
|
+
<%%= render_partial 'password', :submit => false %>
|
8
|
+
|
9
|
+
<div class="button-bar">
|
10
|
+
<%%= submit_tag 'Sign up' %>
|
11
|
+
</div>
|
12
|
+
<%%= end_form_tag %>
|
13
|
+
</div>
|
14
|
+
</div>
|
@@ -0,0 +1,10 @@
|
|
1
|
+
<div title="<%%= title_helper %>" class="memo">
|
2
|
+
<%%= head_helper 'Welcome', :notice => false, :message => false %>
|
3
|
+
<p>You are now logged into the system...</p>
|
4
|
+
<p>
|
5
|
+
Since you are here it's safe to assume the application never
|
6
|
+
called store_location, otherwise you would have been redirected
|
7
|
+
somewhere else after a successful login.
|
8
|
+
</p>
|
9
|
+
<%%= link_to 'logout', :action => 'logout' %>
|
10
|
+
</div>
|
metadata
ADDED
@@ -0,0 +1,80 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
rubygems_version: 0.8.11
|
3
|
+
specification_version: 1
|
4
|
+
name: login_sugar_generator
|
5
|
+
version: !ruby/object:Gem::Version
|
6
|
+
version: 0.9.4
|
7
|
+
date: 2007-01-29 00:00:00 -08:00
|
8
|
+
summary: A modification of the Salted Hash Login Generator that works with Rails 1.1.[456]
|
9
|
+
require_paths:
|
10
|
+
- lib
|
11
|
+
email: dav@AkuAku.org
|
12
|
+
homepage: http://AkuAku.org/
|
13
|
+
rubyforge_project:
|
14
|
+
description:
|
15
|
+
autorequire:
|
16
|
+
default_executable:
|
17
|
+
bindir: bin
|
18
|
+
has_rdoc: false
|
19
|
+
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
20
|
+
requirements:
|
21
|
+
- - ">"
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 0.0.0
|
24
|
+
version:
|
25
|
+
platform: ruby
|
26
|
+
signing_key:
|
27
|
+
cert_chain:
|
28
|
+
authors:
|
29
|
+
- Dav Yaginuma
|
30
|
+
files:
|
31
|
+
- USAGE
|
32
|
+
- login_sugar_generator.rb
|
33
|
+
- templates/_view_edit.rhtml
|
34
|
+
- templates/_view_password.rhtml
|
35
|
+
- templates/clock.rb
|
36
|
+
- templates/controller.rb
|
37
|
+
- templates/controller_test.rb
|
38
|
+
- templates/create_db
|
39
|
+
- templates/default_setup.zip
|
40
|
+
- templates/helper.rb
|
41
|
+
- templates/integration_test.rb
|
42
|
+
- templates/layout.rhtml
|
43
|
+
- templates/login_environment.rb
|
44
|
+
- templates/login_system.rb
|
45
|
+
- templates/migration_login_sugar.rb
|
46
|
+
- templates/mock_clock.rb
|
47
|
+
- templates/mock_notify.rb
|
48
|
+
- templates/notify.rb
|
49
|
+
- templates/notify_change_password.rhtml
|
50
|
+
- templates/notify_delete.rhtml
|
51
|
+
- templates/notify_forgot_password.rhtml
|
52
|
+
- templates/notify_pending_delete.rhtml
|
53
|
+
- templates/notify_signup.rhtml
|
54
|
+
- templates/README
|
55
|
+
- templates/stylesheet.css
|
56
|
+
- templates/user.rb
|
57
|
+
- templates/user_model.erbsql
|
58
|
+
- templates/user_test.rb
|
59
|
+
- templates/users.yml
|
60
|
+
- templates/view_change_password.rhtml
|
61
|
+
- templates/view_edit.rhtml
|
62
|
+
- templates/view_forgot_password.rhtml
|
63
|
+
- templates/view_login.rhtml
|
64
|
+
- templates/view_logout.rhtml
|
65
|
+
- templates/view_signup.rhtml
|
66
|
+
- templates/view_welcome.rhtml
|
67
|
+
test_files: []
|
68
|
+
|
69
|
+
rdoc_options: []
|
70
|
+
|
71
|
+
extra_rdoc_files: []
|
72
|
+
|
73
|
+
executables: []
|
74
|
+
|
75
|
+
extensions: []
|
76
|
+
|
77
|
+
requirements: []
|
78
|
+
|
79
|
+
dependencies: []
|
80
|
+
|