simple_drilldown 0.14.2 → 0.14.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/simple_drilldown/_chart.html.erb +16 -7
- data/lib/simple_drilldown/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 84022afd7bb8dd36bfca2b285ddf9451f794848c41119745506f5cef2d700796
|
4
|
+
data.tar.gz: 79bd64686fecaf97e94ae35bbae64a19ee08a229d9643e7d22d6932d0988dc20
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 28350243c7fcbf93d18648a7b212b89d3762edff818068d2f6e6ee876841dfd1df8ce4e74910f42e2762c2c0336d661e96fbed5458ce739ac342468fb727f490
|
7
|
+
data.tar.gz: 113ca437b9d800ef894e0a8ff6cdfecec7cdc70e21fd83721b1a527fae35b703a3564fd4d975adde78806b446bd92c34388d87a79ac388d100b0f0f4f6f060e4
|
@@ -88,13 +88,22 @@
|
|
88
88
|
if (firstPoint) {
|
89
89
|
label = chart.data.labels[firstPoint.index];
|
90
90
|
console.log("Label: " + label);
|
91
|
-
new_location =
|
92
|
-
new_location =
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
91
|
+
new_location = new URL(window.location.toString());
|
92
|
+
new_location.hash = '';
|
93
|
+
params = new_location.searchParams;
|
94
|
+
dimensions = params.getAll('search[dimensions][]');
|
95
|
+
if (dimensions) {
|
96
|
+
delete(dimensions[dimensions.indexOf('<%= @dimensions[0][:url_param_name] %>')]);
|
97
|
+
if (dimensions.length > 0) {
|
98
|
+
params.set('search[dimensions][]', dimensions);
|
99
|
+
} else {
|
100
|
+
params.delete('search[dimensions][]');
|
101
|
+
}
|
102
|
+
}
|
103
|
+
params.delete('search[filter][<%= @dimensions[0][:url_param_name] %>][]');
|
104
|
+
params.set('search[filter][<%= @dimensions[0][:url_param_name] %>][]', label);
|
105
|
+
new_location.searchParams = params;
|
106
|
+
window.location = new_location.href;
|
98
107
|
}
|
99
108
|
});
|
100
109
|
<% end %>
|