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

Value Get Option From Textbox #9

Open
SaravanakumarVijay opened this issue Jun 25, 2020 · 2 comments
Open

Value Get Option From Textbox #9

SaravanakumarVijay opened this issue Jun 25, 2020 · 2 comments

Comments

@SaravanakumarVijay
Copy link

Hi thanks for this repo its useful. i added this into my project and i am using like below in my angular project

<ng-numeric-input [layout]="'tel'" [class]="'form-control log-input'" [id]="'InmateID'" [entertext]="'Next'" [formControlName]="'InmateID'" [placeholder]="'Type your Inmate ID'" [ngClass]="{ ' is-invalid ': submitted && login.InmateID.errors }" >

i can get error validation message if
i left the textbox by blank. but after entered the value the validation message not hiding.

and also i am not able to read the textbox values. how to read the values entered in textbox, because i need to pass the values to server.

i attached the image too. kindly check with this and help me to solve the issues. thanks once again

Capture

@tak-bro
Copy link
Owner

tak-bro commented Jun 26, 2020

Hi @SaravanakumarVijay
Could you please check this component code?
You can read the data via [(ngModel)].

<ng-numeric-input [layout]="'tel'"
                  [entertext]="'Next'"
                  [placeholder]="'this is placeholder'"
                  [disabled]="false"
                  [(ngModel)]="data"
                  (enterpress)="onEnter()"
                  (ngModelChange)="onChange()"
                  (focus)="onInputFocus()"
                  (blur)="onInputBlur()">
</ng-numeric-input>

@SaravanakumarVijay
Copy link
Author

SaravanakumarVijay commented Jun 29, 2020

Hi thanks for your suggestions, yes i can use [(ngmodel)] key to get values of the textbox thats fine. now i am facing another problem while i using it as a password textbox.

when i using textbox as password type the placeholder value also converted into password mask. like i placed place holder as "enter your pin" but its displayed as "............" like that, please see the attached image.

I am using like this

<ng-numeric-input [layout]="'tel'" [type]="'password'" [class]="'form-control log-input password-mask'" [id]="'Pin'" [(ngModel)]="value1" [entertext]="'Next'" [formControlName]="'Pin'" [placeholder]="'Type your PIN'" [ngClass]="{ 'is-invalid ': submitted && login.Pin.errors }" >

can you help me resolve this one. thanks

Capture1

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

No branches or pull requests

2 participants