zhaoguLaoren.vue 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. <template>
  2. <view class="fwnr-item-box">
  3. <view class="title-row-box">
  4. <text>照顾老人:</text>
  5. <view class="title-del-btn">
  6. <icon class="del-icon" v-show="false"></icon>
  7. </view>
  8. </view>
  9. <view class="form-label-radio fwnr-label-radio">
  10. <view class="phone-form-label"><text class="form-label-require"></text>身体情况</view>
  11. <view class="form-radio-group">
  12. <view v-for="item in items" :key="item.value" class="form-radio-item" @click="radioChange(item.value)"
  13. :class="{genderActive:data.shentizhuangkuang==item.value }">{{item.text}}</view>
  14. </view>
  15. </view>
  16. <view class="fwnr-label-input">
  17. <view class="fwnr-form-label"><text class="form-label-require"></text>老人人数</view>
  18. <uni-easyinput v-model="data.hetong.laoren" placeholder="请输入照顾几位老人" />
  19. </view>
  20. <laorenNianling @change="onChange"></laorenNianling>
  21. </view>
  22. </template>
  23. <script setup>
  24. import {
  25. useHetong
  26. } from "../useHetong.js"
  27. import laorenNianling from "./laorenNianling.vue"
  28. import {
  29. ref
  30. } from "vue"
  31. const {
  32. injectHetong
  33. } = useHetong();
  34. const data = injectHetong()
  35. const emits = defineEmits(['change'])
  36. const items = [{
  37. value: 1,
  38. text: '能自理'
  39. }, {
  40. value: 2,
  41. text: '半自理'
  42. }, {
  43. value: 3,
  44. text: '不能自理'
  45. }, ]
  46. function onChange() {
  47. emits('change')
  48. }
  49. function radioChange(value) {
  50. data.shentizhuangkuang = value;
  51. }
  52. </script>
  53. <style>
  54. </style>