浏览代码

Update updateStatus()'s doc

nghuuphuoc 11 年之前
父节点
当前提交
2ac6764abf

+ 2 - 2
README.md

@@ -372,7 +372,7 @@ Ensure that the ```validate``` method is already called after calling this one.
 Parameter     | Description
 Parameter     | Description
 --------------|------------
 --------------|------------
 field         | The field name or field element
 field         | The field name or field element
-status        | Can be ```not_validated```, ```validating```, ```invalid``` or ```valid```
+status        | Can be ```NOT_VALIDATED```, ```VALIDATING```, ```INVALID``` or ```VALID```
 validatorName | The validator name. If ```null```, the method updates validity result for all validators
 validatorName | The validator name. If ```null```, the method updates validity result for all validators
 
 
 This method is useful when you want to use BootstrapValidator with other plugins such as [Date Picker](http://eternicode.github.io/bootstrap-datepicker/),
 This method is useful when you want to use BootstrapValidator with other plugins such as [Date Picker](http://eternicode.github.io/bootstrap-datepicker/),
@@ -432,7 +432,7 @@ $(document).ready(function() {
                 .data('bootstrapValidator')
                 .data('bootstrapValidator')
                 // Mark the field as not validated,
                 // Mark the field as not validated,
                 // so it'll be re-validated when the user change date
                 // so it'll be re-validated when the user change date
-                .updateStatus('datetimePicker', 'not_validated', null)
+                .updateStatus('datetimePicker', 'NOT_VALIDATED', null)
                 // Validate the field
                 // Validate the field
                 .validateField('datetimePicker');
                 .validateField('datetimePicker');
         });
         });

+ 1 - 1
demo/date.html

@@ -147,7 +147,7 @@ $(document).ready(function() {
             // Validate the date when user change it
             // Validate the date when user change it
             $('#defaultForm')
             $('#defaultForm')
                 .data('bootstrapValidator')                                 // Get the bootstrapValidator instance
                 .data('bootstrapValidator')                                 // Get the bootstrapValidator instance
-                .updateStatus('datetimePicker', 'not_validated', null)      // Mark the field as not validated, so it'll be re-validated when the user change date
+                .updateStatus('datetimePicker', 'NOT_VALIDATED', null)      // Mark the field as not validated, so it'll be re-validated when the user change date
                 .validateField('datetimePicker');                           // Validate the field
                 .validateField('datetimePicker');                           // Validate the field
         });
         });
 });
 });

+ 1 - 1
dist/css/bootstrapValidator.min.css

@@ -3,7 +3,7 @@
  *
  *
  * A jQuery plugin to validate form fields. Use with Bootstrap 3
  * A jQuery plugin to validate form fields. Use with Bootstrap 3
  *
  *
- * @version     v0.3.1
+ * @version     v0.3.2-dev
  * @author      https://twitter.com/nghuuphuoc
  * @author      https://twitter.com/nghuuphuoc
  * @copyright   (c) 2013 - 2014 Nguyen Huu Phuoc
  * @copyright   (c) 2013 - 2014 Nguyen Huu Phuoc
  * @license     MIT
  * @license     MIT

+ 2 - 2
dist/js/bootstrapValidator.js

@@ -3,7 +3,7 @@
  *
  *
  * A jQuery plugin to validate form fields. Use with Bootstrap 3
  * A jQuery plugin to validate form fields. Use with Bootstrap 3
  *
  *
- * @version     v0.3.1
+ * @version     v0.3.2-dev
  * @author      https://twitter.com/nghuuphuoc
  * @author      https://twitter.com/nghuuphuoc
  * @copyright   (c) 2013 - 2014 Nguyen Huu Phuoc
  * @copyright   (c) 2013 - 2014 Nguyen Huu Phuoc
  * @license     MIT
  * @license     MIT
@@ -397,7 +397,7 @@
          *
          *
          * @param {String|jQuery} field The field name or field element
          * @param {String|jQuery} field The field name or field element
          * @param {String} status The status
          * @param {String} status The status
-         * Can be 'not_validated', 'validating', 'invalid' or 'valid'
+         * Can be 'NOT_VALIDATED', 'VALIDATING', 'INVALID' or 'VALID'
          * @param {String|null} validatorName The validator name. If null, the method updates validity result for all validators
          * @param {String|null} validatorName The validator name. If null, the method updates validity result for all validators
          * @return {BootstrapValidator}
          * @return {BootstrapValidator}
          */
          */

+ 1 - 1
dist/js/bootstrapValidator.min.js

@@ -3,7 +3,7 @@
  *
  *
  * A jQuery plugin to validate form fields. Use with Bootstrap 3
  * A jQuery plugin to validate form fields. Use with Bootstrap 3
  *
  *
- * @version     v0.3.1
+ * @version     v0.3.2-dev
  * @author      https://twitter.com/nghuuphuoc
  * @author      https://twitter.com/nghuuphuoc
  * @copyright   (c) 2013 - 2014 Nguyen Huu Phuoc
  * @copyright   (c) 2013 - 2014 Nguyen Huu Phuoc
  * @license     MIT
  * @license     MIT

+ 1 - 1
package.json

@@ -1,6 +1,6 @@
 {
 {
     "name": "bootstrapValidator",
     "name": "bootstrapValidator",
-    "version": "0.3.1",
+    "version": "0.3.2-dev",
     "description": "A jQuery plugin to validate form fields. Use with Bootstrap 3",
     "description": "A jQuery plugin to validate form fields. Use with Bootstrap 3",
     "keywords": ["jQuery", "plugin", "validator", "Bootstrap"],
     "keywords": ["jQuery", "plugin", "validator", "Bootstrap"],
     "author": {
     "author": {

+ 1 - 1
src/js/bootstrapValidator.js

@@ -396,7 +396,7 @@
          *
          *
          * @param {String|jQuery} field The field name or field element
          * @param {String|jQuery} field The field name or field element
          * @param {String} status The status
          * @param {String} status The status
-         * Can be 'not_validated', 'validating', 'invalid' or 'valid'
+         * Can be 'NOT_VALIDATED', 'VALIDATING', 'INVALID' or 'VALID'
          * @param {String|null} validatorName The validator name. If null, the method updates validity result for all validators
          * @param {String|null} validatorName The validator name. If null, the method updates validity result for all validators
          * @return {BootstrapValidator}
          * @return {BootstrapValidator}
          */
          */