Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep the mask in the model #34

Closed
moisespio opened this issue Jan 14, 2015 · 10 comments
Closed

Keep the mask in the model #34

moisespio opened this issue Jan 14, 2015 · 10 comments
Labels

Comments

@moisespio
Copy link

Hello folks!

Is there any way to keep the mask (with the symbols) in the model?

Thanks!

@wellermiranda
Copy link

Hi,

I want to keep the mask too.

Thanks!

@assisrafael
Copy link
Owner

Not yet.
Can you describe a few examples of this use case?

@moisespio
Copy link
Author

I'm using the phone mask in a form and I want to send a email on submit. That's why I want to keep the mask, because I want to receive a email with the formatted phone number.

@assisrafael
Copy link
Owner

We do not have plans to implement this behavior.

An alternative for your scenario is to use the angular-br-filters to apply the mask again in the model value when its necessary.

@moisespio
Copy link
Author

Thanks, this is a good alternative ;)

@wellermiranda
Copy link

@assisrafael I need to keep the mask to send it to an api, where it will be saved in a database. Do you have an alternative? Thanks :)

@assisrafael
Copy link
Owner

Maybe you can write a transformRequest property on the configuration object passed into $http. See https://docs.angularjs.org/api/ng/service/$http for more details

@assisrafael
Copy link
Owner

Feel free to reopen this issue if necessary.

@pocesar
Copy link

pocesar commented Mar 15, 2015

@wellermiranda @moisespio http://ngmodules.org/modules/angular-cleanmask

@awerlang
Copy link

@moisespio @wellermiranda @pocesar I needed an input mask that can handle model values with mask, by default, and made the following solution https://github.com/awerlang/angular-easy-masks, hope it helps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants