fixing a bug where selects would report an incorrect value
This commit is contained in:
parent
bb9f04b7e8
commit
f71af0a205
1 changed files with 5 additions and 5 deletions
|
@ -4397,10 +4397,10 @@ requires
|
||||||
};
|
};
|
||||||
|
|
||||||
that.selected = function() {
|
that.selected = function() {
|
||||||
return $.map(/*self.checked*/self.optionGroup.checked(), function(v, i) {
|
return $.map(/*self.checked*/self.optionGroup.checked(), function(v) {
|
||||||
return {
|
return {
|
||||||
id: self.options.items[i].id,
|
id: self.options.items[v].id,
|
||||||
title: self.options.items[i].title
|
title: self.options.items[v].title
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
@ -4482,10 +4482,10 @@ requires
|
||||||
}
|
}
|
||||||
|
|
||||||
that.value = function() {
|
that.value = function() {
|
||||||
return $.map(self.options.elements, function(input) {
|
return $.map(self.options.elements, function(element) {
|
||||||
var ret = null;
|
var ret = null;
|
||||||
['checked', 'selected', 'value'].forEach(function(v) {
|
['checked', 'selected', 'value'].forEach(function(v) {
|
||||||
input[v] && (ret = input[v]());
|
element[v] && (ret = element[v]());
|
||||||
});
|
});
|
||||||
return ret;
|
return ret;
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue