Browse files

inclusão da máscara de inteiros no plugin regex mask

  • Loading branch information...
1 parent 6ff0568 commit 3bb526b26e33e6b1ded4fb598324130e970c7b93 rlafitte.fa7@gmail.com committed Jan 31, 2011
Showing with 5 additions and 0 deletions.
  1. +2 −0 regex-mask-plugin.js
  2. +3 −0 xsdForm-ui.js
View
2 regex-mask-plugin.js
@@ -6,6 +6,8 @@
mask = /^((\d{1,3}(\.\d{3})*(((\.\d{0,2}))|((\,\d*)?)))|(\d+(\,\d*)?))$/;
} else if (mask == 'float-enus') {
mask = /^((\d{1,3}(\,\d{3})*(((\,\d{0,2}))|((\.\d*)?)))|(\d+(\.\d*)?))$/;
+ } else if (mask == 'integer') {
+ mask = /^\d+$/;
} else {
try {
mask.test("");
View
3 xsdForm-ui.js
@@ -232,4 +232,7 @@ function generateXsdFormUI() {
});
$('input.xsdForm__float.inflated').regexMask('float-ptbr');
+ $('input.xsdForm__integer').regexMask('integer');
+
+
}

0 comments on commit 3bb526b

Please sign in to comment.