lundi 30 novembre 2020

How to disable checkbox of same row alone angular

I have a table where I have columns named Nobill and Bill. Both columns contain checkbox as values. What I need is that when I click the first checkbox of (first column value) Nobill column the same row value of Bill column should get disabled and this should be vice versa.

I already found out the solution by simply adding [disabled]="list.nobillChecked" to the no bill checkbox html and [disabled]="list.billChecked" to the bill checkbox html . This actually will help me do it. But I wanted a another way to do it. A different way to the exact same thing.

Stackblitz link: https://stackblitz.com/edit/angular-ivy-ak1fov?file=src%2Fapp%2Fapp.component.html

Note: Kindly comment if you have any doubts




Aucun commentaire:

Enregistrer un commentaire