Angular 4 checkbox change value

后端 未结 9 2088
臣服心动
臣服心动 2020-12-03 13:30

how could you achieve in Angular 4 that when you register in a checkbox save an \"A\" or \"B\" value. As much as I try, he is only sending me true or false, I hope someone c

9条回答
  •  爱一瞬间的悲伤
    2020-12-03 13:32

    I am guessing that this is what something you are trying to achieve.

    A
    B
    
    click(ev){
       console.log(ev.target.defaultValue);
    }
    

提交回复
热议问题