caboose-cms 0.3.26 → 0.3.27
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
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
NDk0NDBiM2RjNGVlNTZmMjQwY2U1ZmQxODJhZGQ4ZjY2YjJiNzc1Zg==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
NmU3ZjVmMzgyNTk2MDA1Y2JjZWJjZmEwMDRlYWQxOWNhYWY0ZjBlOA==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
OTZjMzVkMWUwNDY2ZGQzMmEzOTg3MjZlNzBhN2JkNmQzNTc5ZTA5ZjY5MmJk
|
10
|
+
ZDk1NzRmNWJmMGM0Y2VmNzg1Y2Y2NTAwZmE0YTUxZjhmNDIxNTQ0MmVlOTA1
|
11
|
+
MzUzZDYxMmYxOGI2YjdmMDMwZTMxNjUxZTU4MDdlMGE2NTNkNzY=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZTdiOWFhNTQ2MTMyNDRlZmVhOTFjZWM3M2I0MTE3NDMwZGE3NTMwYTFjZTk0
|
14
|
+
MTkyMWJiZGM4MWI1ZTJlYzI3MWQ5ZTA0MWRjYmI4YzRkMTNlY2U4YzlmMjg5
|
15
|
+
NWM0MjAwMjNkNmUyN2I3OTY0NTgyNDgxMDU4MjE3ODkwMWI3NmE=
|
@@ -124,7 +124,7 @@ module Caboose
|
|
124
124
|
when "first_name", "last_name", "username", "email"
|
125
125
|
user[name.to_sym] = value
|
126
126
|
when "password"
|
127
|
-
confirm = params[:
|
127
|
+
confirm = params[:password2]
|
128
128
|
if (value != confirm)
|
129
129
|
resp.error = "Passwords do not match.";
|
130
130
|
save = false
|
@@ -1,34 +1,31 @@
|
|
1
1
|
|
2
2
|
<h1>Reset Password for <%= "#{@edituser.first_name} #{@edituser.last_name}" %></h1>
|
3
|
+
<form action='/admin/users/<%= @edituser.id %>' method='put' id='password_form'>
|
4
|
+
<input type='hidden' name='authenticity_token' value='<%= form_authenticity_token %>' />
|
3
5
|
<p><input type='password' name='password' id='password' value="" placeholder='Password' /></p>
|
4
6
|
<p><input type='password' name='password2' id='password2' value="" placeholder='Confirm password' /></p>
|
5
7
|
<div id='message'></div>
|
6
|
-
<
|
8
|
+
<p>
|
7
9
|
<input type='button' value='Back' onclick="window.location='/admin/users/<%= @edituser.id %>/edit';" />
|
8
|
-
<input type='button' value='Update Password' onclick="
|
9
|
-
</
|
10
|
+
<input type='button' value='Update Password' onclick="update_password();" />
|
11
|
+
</p>
|
10
12
|
|
11
13
|
<% content_for :caboose_js do %>
|
12
14
|
<script type="text/javascript">
|
13
|
-
var modal = false;
|
14
|
-
$(document).ready(function() {
|
15
|
-
modal = new CabooseModal(500);
|
16
|
-
});
|
17
15
|
|
18
|
-
function
|
16
|
+
function update_password()
|
19
17
|
{
|
20
18
|
$.ajax({
|
21
|
-
url: '/admin/users
|
22
|
-
type: '
|
19
|
+
url: '/admin/users/<%= @edituser.id %>',
|
20
|
+
type: 'put',
|
21
|
+
data: $('#password_form').serialize(),
|
23
22
|
success: function(resp) {
|
24
|
-
if (resp.success)
|
25
|
-
|
26
|
-
if (resp.
|
27
|
-
modal.autosize("<p class='note success'>" + resp.error + "</p>");
|
28
|
-
if (resp.redirect)
|
29
|
-
window.location = resp.redirect;
|
23
|
+
if (resp.success) $('#message').html("<p class='note success'>The password has been reset.</p>");
|
24
|
+
if (resp.error) $('#message').html("<p class='note error'>" + resp.error + "</p>");
|
25
|
+
if (resp.redirect) window.location = resp.redirect;
|
30
26
|
}
|
31
27
|
});
|
32
28
|
}
|
29
|
+
|
33
30
|
</script>
|
34
31
|
<% end %>
|
data/lib/caboose/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: caboose-cms
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.27
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- William Barry
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-01-
|
11
|
+
date: 2014-01-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|