signed_form-activeadmin 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/signed_form-activeadmin/version.rb +1 -1
- data/lib/signed_form-activeadmin.rb +2 -2
- data/signed_form-activeadmin.gemspec +6 -6
- data/spec/config/database.yml +5 -0
- data/{spec.rb → spec/spec.rb} +18 -20
- metadata +16 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 84cc3ed96244432d6cbb81b9fb01f6d0f91cec01
|
4
|
+
data.tar.gz: ae585fe607e734fc8808041c94cfd4575cae81e3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0d92560a520d807da3bcfa42bc6763e71fb84a1377af11ae223762469ea43d3d45740a2b5ade8554069e067effc076772f81cadc77a8df9aa586037274328877
|
7
|
+
data.tar.gz: d4c793405c297a5e451163c2f83794f927d1249c66450b9beb77025a6708f7a50271a302dc9acd5d2f7c5f069ac206316065779b3c1b999f90ec6bfe9ef3817d
|
@@ -9,11 +9,11 @@ module SignedForm
|
|
9
9
|
|
10
10
|
module ViewHelpers
|
11
11
|
module FormHelper
|
12
|
-
|
12
|
+
orig_active_admin_form_for = instance_method :active_admin_form_for
|
13
13
|
|
14
14
|
define_method :active_admin_form_for do |resource, options = {}, &block|
|
15
15
|
options[:signed] = true
|
16
|
-
orig_active_admin_form_for resource, options, &block
|
16
|
+
orig_active_admin_form_for.bind(self).call resource, options, &block
|
17
17
|
end
|
18
18
|
end
|
19
19
|
end
|
@@ -22,13 +22,13 @@ Gem::Specification.new do |s|
|
|
22
22
|
s.extra_rdoc_files = %w(README.md)
|
23
23
|
|
24
24
|
s.add_development_dependency 'rake'
|
25
|
-
s.add_development_dependency 'activemodel', '>= 3.1'
|
26
|
-
s.add_development_dependency 'actionpack', '>= 3.1'
|
27
|
-
s.add_development_dependency 'strong_parameters'
|
28
25
|
s.add_development_dependency 'minitest'
|
29
26
|
|
30
|
-
s.
|
31
|
-
s.
|
27
|
+
s.add_development_dependency 'strong_parameters'
|
28
|
+
s.add_development_dependency 'sass-rails'
|
29
|
+
s.add_development_dependency 'sqlite3'
|
32
30
|
|
33
|
-
s.
|
31
|
+
s.add_dependency 'rails', '>= 3.1'
|
32
|
+
s.add_dependency 'signed_form'
|
33
|
+
s.add_dependency 'activeadmin', '>= 0.4.0'
|
34
34
|
end
|
data/{spec.rb → spec/spec.rb}
RENAMED
@@ -1,40 +1,38 @@
|
|
1
|
-
require '
|
2
|
-
require '
|
3
|
-
|
4
|
-
|
5
|
-
extend ActiveModel::Naming
|
6
|
-
|
7
|
-
attr_accessor :name
|
1
|
+
require 'rails/all'
|
2
|
+
require 'signed_form'
|
3
|
+
require 'active_admin'
|
4
|
+
require 'signed_form-activeadmin'
|
8
5
|
|
9
|
-
|
10
|
-
|
6
|
+
module Test
|
7
|
+
class Application < ::Rails::Application
|
8
|
+
config.root = File.join __FILE__, '..'
|
9
|
+
config.logger = Logger.new STDOUT
|
10
|
+
config.active_support.deprecation = :stderr
|
11
11
|
end
|
12
12
|
end
|
13
13
|
|
14
|
-
|
14
|
+
class ApplicationController < ActionController::Base; end
|
15
15
|
|
16
|
-
|
16
|
+
Test::Application.initialize!
|
17
17
|
|
18
|
-
|
19
|
-
|
18
|
+
class User
|
19
|
+
extend ActiveModel::Naming
|
20
20
|
|
21
|
-
|
22
|
-
module FormHelper
|
23
|
-
include SignedForm::ActionView::FormHelper
|
21
|
+
attr_accessor :name
|
24
22
|
|
25
|
-
|
26
|
-
|
23
|
+
def to_key
|
24
|
+
[1]
|
27
25
|
end
|
28
26
|
end
|
29
27
|
|
30
|
-
require 'signed_form-activeadmin'
|
31
|
-
|
32
28
|
require 'minitest/autorun'
|
33
29
|
|
34
30
|
describe ActiveAdmin::ViewHelpers::FormHelper do
|
35
31
|
describe 'active_admin_form_for tag' do
|
36
32
|
include ActionView::Helpers
|
37
33
|
include ActionView::Context if defined? ActionView::Context
|
34
|
+
include SignedForm::ActionView::FormHelper
|
35
|
+
include Formtastic::Helpers::FormHelper
|
38
36
|
include ActiveAdmin::ViewHelpers::FormHelper
|
39
37
|
|
40
38
|
def polymorphic_path(*)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: signed_form-activeadmin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Christopher Schramm
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-01-
|
11
|
+
date: 2014-01-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -25,35 +25,35 @@ dependencies:
|
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
28
|
+
name: minitest
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
40
|
+
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
|
-
name:
|
42
|
+
name: strong_parameters
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '
|
47
|
+
version: '0'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '
|
54
|
+
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: sass-rails
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - ">="
|
@@ -67,7 +67,7 @@ dependencies:
|
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
70
|
+
name: sqlite3
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
73
|
- - ">="
|
@@ -81,21 +81,21 @@ dependencies:
|
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '0'
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
|
-
name:
|
84
|
+
name: rails
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
87
|
- - ">="
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: '
|
89
|
+
version: '3.1'
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
94
|
- - ">="
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: '
|
96
|
+
version: '3.1'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
|
-
name:
|
98
|
+
name: signed_form
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
101
|
- - ">="
|
@@ -138,7 +138,8 @@ files:
|
|
138
138
|
- lib/signed_form-activeadmin.rb
|
139
139
|
- lib/signed_form-activeadmin/version.rb
|
140
140
|
- signed_form-activeadmin.gemspec
|
141
|
-
- spec.
|
141
|
+
- spec/config/database.yml
|
142
|
+
- spec/spec.rb
|
142
143
|
homepage: https://github.com/cschramm/signed_form-activeadmin
|
143
144
|
licenses:
|
144
145
|
- MIT
|