微信小程序选择按钮radio

美观操作按钮样式

<!--操作-->
        <view class="cu-bar padding-top">
            <view class="search-form-lg round border-orange">
                <text class="cuIcon-operation"></text>
                <input disabled="true" value=操作 />
                <view class="flex padding-right-sm">
                    <view class="margin-right-sm text-bold">正常</view>
                    <radio class="" checked="{
          
   {numType==0}}" bindtap="numType0"></radio>
                    <view class="margin-lr-sm text-bold">调整</view>
                    <radio class="red" checked="{
          
   {numType==1}}" bindtap="numType1"></radio>
                </view>
            </view>
        </view>
//领取_选择
    numType0() {
          
   
        wx.vibrateShort({
          
   
            type: light,
        })
        this.setData({
          
   
            numType: 0
        })
    },
    //调整_选择
    numType1() {
          
   
        wx.vibrateShort({
          
   
            type: light,
        })
        this.setData({
          
   
            numType: 1
        })
    },
经验分享 程序员 微信小程序 职场和发展