uni-app获取单选按钮的值
电脑版发表于:2022/1/20 20:20
页面:
<radio-group @change="radioChange" name="radio" style="margin-top: 5px;"> <view class="uni-flex uni-row"> <view class="flex-item-ispass"> <radio value="1" /><text>通过</text> </view> <view class="flex-item-ispass"> <radio value="2" /><text>失败</text> </view> <view class="flex-item-ispass"> <radio value="0" /><text>待审</text> </view> <view class="flex-item-ispass"> <radio value="-1" /><text>所有</text> </view> </view> </radio-group>
js:
radioChange(evt) { alert(evt.detail.value); },