recordselect 3.5.0 → 3.6.0

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,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 152f8baeb870b2d1b71c7e85845071fe73c227e8
4
- data.tar.gz: b674c62e25aacc9caa4da6726a414135997f8775
3
+ metadata.gz: fc636c8898948d4b510ad51b1a697ce7038df040
4
+ data.tar.gz: 79e542bbaf5385bd27d6154ef51bd152e6433193
5
5
  SHA512:
6
- metadata.gz: af47dde90a1cd81d8c5cd2e14bb3404de33c792e7cc95a0935d80c509834dbaddc11d3ef7e28cbcc3e3df6484b9ec25943b5be94199b58a3a21f666f804eb8d4
7
- data.tar.gz: 8fb2273ba1e26e6da299f3f4f97ce75f83d1481aa6fc99ea102c1cfe8bb1e087c717bc320a691e0576ed8396280c8add1cd6f65ced61b80e9e37e668e1c6c110
6
+ metadata.gz: e981fd913751ad385e6d12bd778a1c2ab72b2070a6d93136269c908e0e14bb045723f7d0d65547221341928ea8eaeda838bddd8c894eac435c67c1d965cabfe3
7
+ data.tar.gz: cc319878a0539d8cccb4800d41516b40c3336372d95cb02e4392fea95b749956b8e4c4842610692852b4901b2d606d8b775635bb176711e8ef76e61f79776c3f
data/README CHANGED
@@ -1,7 +1,7 @@
1
1
  RecordSelect
2
2
  ============
3
3
 
4
- (c) 2007 - Lance Ivy
4
+ (c) 2007 - 2016 Sergio Cambra, Lance Ivy
5
5
 
6
6
  RecordSelect is a Rails widget to help you pick one record out of many. I designed it as a more usable and performant alternative to generating a massive dropdown list. It relies on AJAX for the cooler uses (all the provided view helpers rely on JavaScript?) but can also function in a pure-http fashion (although multi-select support is provided in a pure-JavaScript implementation).
7
7
 
@@ -10,6 +10,6 @@ Please see the ActionView::Helpers::RecordSelectHelpers for the most common API.
10
10
  = DEPENDENCIES
11
11
  This depends on the excellent Paginator gem by Bruce Williams. This simple gem is available at paginator.rubyforge.org.
12
12
 
13
-
14
- If you would like to use jquery:
15
- uncomment line #RecordSelect::Config.js_framework = :jquery in init.rb
13
+ It should autoselect js framework, but you can select :jquery or :prototype framework with config/initializer file:
14
+ RecordSelect::Config.js_framework = :jquery
15
+ RecordSelect::Config.js_framework = :prototype
@@ -1,7 +1,7 @@
1
1
  <%
2
2
  controller ||= params[:controller]
3
3
 
4
- pagination_url_params = params.merge(:controller => controller, :action => :browse, :search => params[:search], :update => 1)
4
+ pagination_url_params = params.permit(:search).permit(*permit_rs_browse_params).merge(:controller => controller, :action => :browse, :search => params[:search], :update => 1)
5
5
  prev_url = url_for(pagination_url_params.merge(:page => page.prev.number)) if page.prev?
6
6
  next_url = url_for(pagination_url_params.merge(:page => page.next.number)) if page.next?
7
7
  -%>
@@ -1,4 +1,4 @@
1
- <% url_options = params.merge(:controller => controller, :action => :browse, :page => 1, :update => 1) -%>
1
+ <% url_options = params.permit(:search).permit(*permit_rs_browse_params).merge(:controller => controller, :action => :browse, :page => 1, :update => 1) -%>
2
2
  <%= form_tag url_options, {:method => :get, :remote => true, :id => record_select_search_id} -%>
3
3
  <%= text_field_tag 'search', params[:search], :autocomplete => 'off', :class => 'text-input' %>
4
4
  <%= submit_tag 'search', :class => "search_submit" %>
@@ -1,4 +1,9 @@
1
1
  module RecordSelectHelper
2
+ # If you use :params option, define this helper in your controller helpers
3
+ # to return array with those params, so _list partial permits them
4
+ def permit_rs_browse_params
5
+ end
6
+
2
7
  # Adds a link on the page that toggles a RecordSelect widget from the given controller.
3
8
  #
4
9
  # *Options*
@@ -1,7 +1,7 @@
1
1
  module RecordSelect
2
2
  module Version
3
3
  MAJOR = 3
4
- MINOR = 5
4
+ MINOR = 6
5
5
  PATCH = 0
6
6
 
7
7
  STRING = [MAJOR, MINOR, PATCH].compact.join('.')
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: recordselect
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.5.0
4
+ version: 3.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sergio Cambra
@@ -10,50 +10,50 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-06-07 00:00:00.000000000 Z
13
+ date: 2016-09-29 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: shoulda
17
17
  requirement: !ruby/object:Gem::Requirement
18
18
  requirements:
19
- - - '>='
19
+ - - ">="
20
20
  - !ruby/object:Gem::Version
21
21
  version: '0'
22
22
  type: :development
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
- - - '>='
26
+ - - ">="
27
27
  - !ruby/object:Gem::Version
28
28
  version: '0'
29
29
  - !ruby/object:Gem::Dependency
30
30
  name: bundler
31
31
  requirement: !ruby/object:Gem::Requirement
32
32
  requirements:
33
- - - ~>
33
+ - - "~>"
34
34
  - !ruby/object:Gem::Version
35
35
  version: 1.0.0
36
36
  type: :development
37
37
  prerelease: false
38
38
  version_requirements: !ruby/object:Gem::Requirement
39
39
  requirements:
40
- - - ~>
40
+ - - "~>"
41
41
  - !ruby/object:Gem::Version
42
42
  version: 1.0.0
43
43
  - !ruby/object:Gem::Dependency
44
44
  name: rails
45
45
  requirement: !ruby/object:Gem::Requirement
46
46
  requirements:
47
- - - '>='
47
+ - - ">="
48
48
  - !ruby/object:Gem::Version
49
- version: 3.1.3
49
+ version: 4.0.0
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: 3.1.3
56
+ version: 4.0.0
57
57
  description: RecordSelect is a Rails widget to help you pick one record out of many.
58
58
  I designed it as a more usable and performant alternative to generating a massive
59
59
  dropdown list
@@ -103,17 +103,17 @@ require_paths:
103
103
  - lib
104
104
  required_ruby_version: !ruby/object:Gem::Requirement
105
105
  requirements:
106
- - - '>='
106
+ - - ">="
107
107
  - !ruby/object:Gem::Version
108
108
  version: 1.9.1
109
109
  required_rubygems_version: !ruby/object:Gem::Requirement
110
110
  requirements:
111
- - - '>='
111
+ - - ">="
112
112
  - !ruby/object:Gem::Version
113
113
  version: '0'
114
114
  requirements: []
115
115
  rubyforge_project:
116
- rubygems_version: 2.4.8
116
+ rubygems_version: 2.5.1
117
117
  signing_key:
118
118
  specification_version: 4
119
119
  summary: RecordSelect widget as a replacement for massive drop down lists