更新保险组件,可选展示switch
This commit is contained in:
parent
bc86fcb3df
commit
aed9276443
|
@ -9,7 +9,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="switch-container">
|
<view class="switch-container">
|
||||||
<text class="price">¥ 6.00</text>
|
<text class="price">¥ 6.00</text>
|
||||||
<view @click="changeState">
|
<view v-show="showSwitch" class="switch" @click="changeState">
|
||||||
<widget-switch :open="state" />
|
<widget-switch :open="state" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -29,6 +29,10 @@ export default {
|
||||||
WidgetSwitch,
|
WidgetSwitch,
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
|
showSwitch: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true,
|
||||||
|
},
|
||||||
insurance: {
|
insurance: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
|
@ -94,7 +98,9 @@ export default {
|
||||||
.price {
|
.price {
|
||||||
font-size: 30rpx;
|
font-size: 30rpx;
|
||||||
color: #ec7655;
|
color: #ec7655;
|
||||||
margin-right: 38rpx;
|
}
|
||||||
|
.switch {
|
||||||
|
margin-left: 38rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue