diff options
| author | Igor Minar | 2011-10-13 16:58:44 -0700 |
|---|---|---|
| committer | Igor Minar | 2011-10-13 17:35:00 -0700 |
| commit | d83a92c12138ab53d1a6c6eae7d0cf9300514e8c (patch) | |
| tree | be80f941e37c18e619627493f3089e73eb190f4f /src/widget/input.js | |
| parent | d0425de29e16018f670d03e2f3a27aec82430b17 (diff) | |
| download | angular.js-d83a92c12138ab53d1a6c6eae7d0cf9300514e8c.tar.bz2 | |
fix(checkbox): prefix true-value & false-value with ng:
Diffstat (limited to 'src/widget/input.js')
| -rw-r--r-- | src/widget/input.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/widget/input.js b/src/widget/input.js index 7f1a5773..ec9701e7 100644 --- a/src/widget/input.js +++ b/src/widget/input.js @@ -414,8 +414,8 @@ angularInputType('integer', numericRegexpInputType(INTEGER_REGEXP, 'INTEGER')); * * @param {string} ng:model Assignable angular expression to data-bind to. * @param {string=} name Property name of the form under which the widgets is published. - * @param {string=} true-value The value to which the expression should be set when selected. - * @param {string=} false-value The value to which the expression should be set when not selected. + * @param {string=} ng:true-value The value to which the expression should be set when selected. + * @param {string=} ng:false-value The value to which the expression should be set when not selected. * @param {string=} ng:change Angular expression to be executed when input changes due to user * interaction with the input element. * @@ -432,7 +432,7 @@ angularInputType('integer', numericRegexpInputType(INTEGER_REGEXP, 'INTEGER')); <form name="myForm"> Value1: <input type="checkbox" ng:model="value1"> <br/> Value2: <input type="checkbox" ng:model="value2" - true-value="YES" false-value="NO"> <br/> + ng:true-value="YES" ng:false-value="NO"> <br/> </form> <tt>value1 = {{value1}}</tt><br/> <tt>value2 = {{value2}}</tt><br/> @@ -453,8 +453,8 @@ angularInputType('integer', numericRegexpInputType(INTEGER_REGEXP, 'INTEGER')); */ angularInputType('checkbox', function(inputElement) { var widget = this, - trueValue = inputElement.attr('true-value'), - falseValue = inputElement.attr('false-value'); + trueValue = inputElement.attr('ng:true-value'), + falseValue = inputElement.attr('ng:false-value'); if (!isString(trueValue)) trueValue = true; if (!isString(falseValue)) falseValue = false; |
