actionset 0.3.3 → 0.3.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: da75dd84d025051634c3e55fb959c3df91bd074e
4
- data.tar.gz: cf129f9777e7d21cefdb14ed8f55009647f7d4fc
3
+ metadata.gz: 94c2718c8e23f7c7366d789850324fe3980bd686
4
+ data.tar.gz: a416c81e64c3f35fe254f0b4fa294eb8fa97bedf
5
5
  SHA512:
6
- metadata.gz: 068760c30b9ed5a55cfc5caac4459af2efa7d3723e80e2be2d7dfb8fa5f1451d069abde323cf76fac1a416371d86b03b744a649e3136e65fea1f5877feac5b38
7
- data.tar.gz: d47d46fa425c52a18ff2495c66cd87b144d81297c4f75356f12baea66f907a14acfd536d54739c2728c59f53c8079b40b92eb99d7280e51787053b0244ddc917
6
+ metadata.gz: 8336b7f82a1b640ae3ac99aba35c85c9067fb331329f96d0e84b49e98fa0ad9dd92c81c34d6420d77114096c82ae49699ed4d8f66bffd2750ee99718f9117fbb
7
+ data.tar.gz: 16933793296c6a5015b1dc2e48386cd3e2294bc9738d3c2674b606fbec62af476ba72e7c7417c893e5e6cec39fed41db53c8a513c8116cb60ddfe2cf001e87ae
data/CHANGELOG CHANGED
@@ -1,3 +1,6 @@
1
+ v 0.3.4
2
+ - Ensure that the sort_link_for helper method make the title param optional
3
+ - Ensure that the view helpers are properly included into the ActionView context
1
4
  v 0.3.3
2
5
  - Ensure the page link url uses a deep merge to retain any previously set paginate params
3
6
  v 0.3.2
data/lib/action_set.rb CHANGED
@@ -2,6 +2,7 @@
2
2
 
3
3
  require 'rails/railtie'
4
4
  require 'active_support/core_ext/object/blank'
5
+ require 'active_support/lazy_load_hooks'
5
6
  require 'active_set'
6
7
  require 'ostruct'
7
8
 
@@ -10,12 +11,9 @@ require_relative './action_set/instructions/entry_value'
10
11
  require_relative './action_set/helpers/helper_methods'
11
12
 
12
13
  module ActionSet
13
- class Railtie < ::Rails::Railtie
14
- initializer 'action_set.view_helpers' do
15
- ActiveSupport.on_load :action_view do
16
- include Helpers::HelperMethods
17
- end
18
- end
14
+ # Ensure that the HelperMethods are callable from the Rails view-layer
15
+ ActiveSupport.on_load :action_view do
16
+ ::ActionView::Base.send :include, Helpers::HelperMethods
19
17
  end
20
18
 
21
19
  class Filter < OpenStruct
@@ -6,7 +6,7 @@ require_relative './paginator'
6
6
  module ActionSet
7
7
  module Helpers
8
8
  module HelperMethods
9
- def sort_link_for(column, title)
9
+ def sort_link_for(column, title = nil)
10
10
  Helpers::SortLinker.new(self).render(column, title)
11
11
  end
12
12
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActionSet
4
- VERSION = '0.3.3'
4
+ VERSION = '0.3.4'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionset
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen Margheim
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-10-31 00:00:00.000000000 Z
11
+ date: 2017-11-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activeset