effective_datatables 4.38.1 → 4.39.1
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
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 92dbd778d7e5b63be5dfedb7137193290c21da8d1b119d7ff92e5c06474dc032
|
|
4
|
+
data.tar.gz: f044c7be5c129b36c2f437f7e7acca2fa2cecc1d1aec5e101dfa86e7debbd2d5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 79f406c3eb58b786a935addd180a35c9fec5638277aea6f5280fda9f649ec714c07bb9a15fba9e45aadcdff7a7cf128f3d01a651a8af6e70b66f388b35e32097
|
|
7
|
+
data.tar.gz: ba94caf90dca5d5f69bf38c6297e5f523cea245b14b17707783a6a3d56f8c41acdeab0bd56da8475efc17e7bb5300ff1883cfa023a2fdb846e7720e5ccb0d85a
|
|
@@ -41,11 +41,18 @@ $(document).on 'ajax:beforeSend', '.dataTables_wrapper .col-actions', (event, xh
|
|
|
41
41
|
true
|
|
42
42
|
|
|
43
43
|
# We have either completed the resource action, or fetched the inline form to load.
|
|
44
|
-
$(document).on 'ajax:success', '.dataTables_wrapper .col-actions', (event, data) ->
|
|
44
|
+
$(document).on 'ajax:success', '.dataTables_wrapper .col-actions', (event, data, status, xhr) ->
|
|
45
45
|
[data, status, xhr] = event.detail if event.detail # rails/ujs
|
|
46
46
|
|
|
47
47
|
$action = $(event.target)
|
|
48
48
|
|
|
49
|
+
# Rails UJS follows HTTP redirects inside XHR; navigate after a redirected action.
|
|
50
|
+
if typeof Turbo != 'undefined' && xhr?.responseURL && ($action.data('method') || 'get').toLowerCase() != 'get'
|
|
51
|
+
if xhr.responseURL != $action.prop('href') && (xhr.getResponseHeader('Content-Type') || '').includes('text/html')
|
|
52
|
+
Turbo.cache.clear()
|
|
53
|
+
Turbo.visit(xhr.responseURL, { action: 'replace' })
|
|
54
|
+
return true
|
|
55
|
+
|
|
49
56
|
return true if ('' + $action.data('inline')) == 'false'
|
|
50
57
|
|
|
51
58
|
if data.length > 0
|
|
@@ -103,7 +103,7 @@ module Effective
|
|
|
103
103
|
|
|
104
104
|
# Must return a string
|
|
105
105
|
def format_column(value, column, as: nil, csv: false)
|
|
106
|
-
return if value.nil? || (column[:resource] && value.blank?)
|
|
106
|
+
return if value.nil? || (column[:resource] && value != false && value.blank?)
|
|
107
107
|
|
|
108
108
|
if value.kind_of?(Array) && [:string, :text].include?(column[:as])
|
|
109
109
|
if csv
|