Created
March 10, 2015 07:48
-
-
Save h4/108a1488a3a456282798 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_typeCheckboxesCurrentValue: function() { | |
return this._getTypeCheckboxes() | |
.filter(function(bCheckbox) { | |
return bCheckbox.isChecked(); | |
}) | |
.map(function(bCheckbox) { | |
return bCheckbox.val(); | |
}) | |
.reduce(function(prev, cur) { | |
return cur || prev; | |
}); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_typeCheckboxesCurrentValue: function() { | |
var value; | |
for (var i = 0, bCheckbox; (bCheckbox = bCheckboxes[i]); i++) { | |
if (bCheckbox.isChecked()) { | |
value = bCheckbox.val(); | |
break; | |
} | |
} | |
return value; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment