combo_auto_box 0.0.36 → 0.0.37
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/combo_auto_box/version.rb +1 -1
- data/vendor/assets/javascripts/combo-auto-box.js +8 -8
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c67fa564b4944481efe66c858f48aeae0badf2e9
|
4
|
+
data.tar.gz: 25236cc95db3a65da67f65774ca7e755b2074088
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c5536945ee3be76e69ad50c2fa1735ef2a3a15c5b04317f7c36098941bbf9ceb5984373d4a56096a575c66f66aba69ceb867d2b266ca2ebfb0f6ff78367042e7
|
7
|
+
data.tar.gz: 97d45c3f7fe2f9c680d8b8b6e0711bff2bf85589a258e0c888f5ac1f5b72080cac705c1e1955048e9db1358c339a780e096bdec58e00ee23fe5d5429f61b6683
|
@@ -672,7 +672,7 @@ var ComboAutoBox = {
|
|
672
672
|
}
|
673
673
|
fieldAttribute = '<input type="hidden" name="q[g]['+ predicate['attribute'] +'][c]['+ ransackId +'][a][0][name]" value="'+ predicate['attribute'] +'">';
|
674
674
|
fieldCondition = '<input type="hidden" name="q[g]['+ predicate['attribute'] +'][c]['+ ransackId +'][p]" value="'+ predicate['condition'] +'">';
|
675
|
-
fieldValue = '<input type="hidden" name="q[g]['+ predicate['attribute'] +'][c]['+ ransackId +'][v][0][value]" value="'+ getSearchableValue(selectedData) +'">';
|
675
|
+
fieldValue = '<input type="hidden" name="q[g]['+ predicate['attribute'] +'][c]['+ ransackId +'][v][0][value]" value="'+ htmlSafe(getSearchableValue(selectedData)) +'">';
|
676
676
|
var id = generateAnId('item');
|
677
677
|
$('#' + inputId).before('<div class="item" id="' + id + '">'+ htmlSafe(selectedData) +'<span class="remove_item" title="Remove Item">x</span>'+ fieldAttribute + fieldCondition + fieldValue +'</div>');
|
678
678
|
|
@@ -697,7 +697,7 @@ var ComboAutoBox = {
|
|
697
697
|
var addSearchableItem = function (inputId, selectedId, selectedData) {
|
698
698
|
if (selectedData != '') {
|
699
699
|
var id = generateAnId('item');
|
700
|
-
$('#' + inputId).before('<div class="item" id="' + id + '">'+ htmlSafe(selectedData) +'<span title="Remove Item">x</span><input type="hidden" name="'+ options.html.name +'['+ selectedId +'][]" value="'+ getSearchableValue(selectedData) +'"></div>');
|
700
|
+
$('#' + inputId).before('<div class="item" id="' + id + '">'+ htmlSafe(selectedData) +'<span title="Remove Item">x</span><input type="hidden" name="'+ options.html.name +'['+ selectedId +'][]" value="'+ htmlSafe(getSearchableValue(selectedData)) +'"></div>');
|
701
701
|
|
702
702
|
$('#' + id + ' > span').click(function() {
|
703
703
|
$(this).parent().remove();
|
@@ -747,12 +747,12 @@ var ComboAutoBox = {
|
|
747
747
|
}
|
748
748
|
|
749
749
|
var htmlSafe = function(html) {
|
750
|
-
html = html.replace(
|
751
|
-
html = html.replace(
|
752
|
-
html = html.replace(
|
753
|
-
html = html.replace(/\"
|
754
|
-
html = html.replace(/\'
|
755
|
-
html = html.replace(
|
750
|
+
html = html.replace(/\&/g, '&');
|
751
|
+
html = html.replace(/\</g, '<');
|
752
|
+
html = html.replace(/\>/g, '>');
|
753
|
+
html = html.replace(/\"/g, '"');
|
754
|
+
html = html.replace(/\'/g, ''');
|
755
|
+
html = html.replace(/\//g, '/');
|
756
756
|
|
757
757
|
return html;
|
758
758
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: combo_auto_box
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.37
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adilson Chacon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-05-
|
11
|
+
date: 2015-05-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|