effective_datatables 4.3.14 → 4.3.15

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: af2ec322b027d0c64af201b2f7356fbad6d2584e
4
- data.tar.gz: 6f27b2d7b3c3c9424b1301c78a6b10aa91c0ef0f
3
+ metadata.gz: 7f1b5b329ca2354da5f168735977f3cb7d7aa575
4
+ data.tar.gz: 3e50ed652423c0ff92186bd9ba5069d5da8815fa
5
5
  SHA512:
6
- metadata.gz: 650a1ad46b4a2384438877d17687cc807012f2de888cdb5834bf543f4e84a709884dbca4f9bc3459654411ac35f071cdb5b7506fbcd35594ab2cc3aa13458676
7
- data.tar.gz: 1ce0b64574d75ed034999b741fcb229d81ff7a6412220ad381f051724e6c9eb741a5852e4f9cfe44ddc3fc07635472d741e9b1595bbeaa91b3c9d0887e34bd05
6
+ metadata.gz: d360e5c267b75b79a48833d53b0ccfd84b3c89ed44b887b7977fd1fc238488c5faa4ffeafd571bb6c85b5b0adba6491f67c6fa57829d0d23c4e431cb7af383c1
7
+ data.tar.gz: aae4e1ac2f63ee04a28c4824b735d9eac0ee9d5332c6e07087e87907b0b6cc498c36869d5ac84ce56f7debde2f6a6cfa6fd6d9eec8d152686d31778f267ef35a
@@ -36,7 +36,7 @@ module Effective
36
36
 
37
37
  def search_params
38
38
  params.select do |name, value|
39
- columns.key?(name) && (name != :id) && !value.kind_of?(Hash) && value.class.name != 'ActionController::Parameters'.freeze
39
+ columns.key?(name) && ![:id, :action].include?(name) && !value.kind_of?(Hash) && value.class.name != 'ActionController::Parameters'.freeze
40
40
  end
41
41
  end
42
42
  end
@@ -1,8 +1,8 @@
1
1
  - Array(datatable.array_collection? ? resource : resource.send(name)).each do |resource|
2
2
  .col-resource_item
3
- - if edit_action && EffectiveDatatables.authorized?(controller, :edit, resource)
4
- = link_to resource.to_s, effective_resource.action_path(:edit, resource), title: resource.to_s
5
- - elsif show_action && EffectiveDatatables.authorized?(controller, :show, resource)
6
- = link_to resource.to_s, effective_resource.action_path(:show, resource), title: resource.to_s
3
+ - if edit_action && EffectiveDatatables.authorized?(controller, :edit, resource) && (path = effective_resource.action_path(:edit, resource)).present?
4
+ = link_to resource.to_s, path, title: resource.to_s
5
+ - elsif show_action && EffectiveDatatables.authorized?(controller, :show, resource) && (path = effective_resource.action_path(:show, resource)).present?
6
+ = link_to resource.to_s, path, title: resource.to_s
7
7
  - else
8
8
  = resource.to_s.html_safe
@@ -1,3 +1,3 @@
1
1
  module EffectiveDatatables
2
- VERSION = '4.3.14'.freeze
2
+ VERSION = '4.3.15'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_datatables
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.14
4
+ version: 4.3.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Code and Effect
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-12-04 00:00:00.000000000 Z
11
+ date: 2018-12-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails