Angular 2: How to get the selected value from different options of a form?

前端 未结 4 831
醉酒成梦
醉酒成梦 2020-12-16 16:58

I would like to use a

component.ts

this.types = [ 'type1', 'type2', 'type3' ];
   this.order = {
      type: 'type1'          
  };  

  callType(value){
    console.log(value);
    this.order.type=value;
  }

提交回复
热议问题