complaint.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. <template>
  2. <view class="content">
  3. <image class="w h-150" src="/static/image/source/jubao.jpeg"></image>
  4. <view class="mgt-50 text-28 text-777 mgb-20">
  5. 请选择举报原因:(<text class="text-fc2419">*</text>)
  6. </view>
  7. <up-radio-group
  8. v-model="radiovalue1"
  9. placement="column"
  10. activeColor="#d91e0f"
  11. @change="groupChange"
  12. >
  13. <up-radio
  14. :customStyle="{marginBottom: '8rpx'}"
  15. v-for="(item, index) in radiolist1"
  16. :key="index"
  17. :label="item.name"
  18. :name="item.name"
  19. @change="radioChange"
  20. >
  21. </up-radio>
  22. <view v-if="radiovalue1 == '其他意见或建议'">
  23. <view class="pdl-50">
  24. <view class="border-top pdy-20 pdr-100 flex jc_between ai_center">
  25. <view class="w-260">具体情况说明</view>
  26. <up-input v-model="desc" class="text-24" :customStyle="{ height: '50rpx' }" fontSize="12"
  27. placeholder="请补充你的投诉内容"></up-input>
  28. </view>
  29. <view class="border-top pdy-20 pdr-100 flex jc_between ai_center">
  30. <view class="w-260">联系方式</view>
  31. <up-input v-model="tel" class="text-24" :customStyle="{ height: '50rpx' }" fontSize="12"
  32. placeholder="请填写你的联系方式"></up-input>
  33. </view>
  34. </view>
  35. </view>
  36. </up-radio-group>
  37. <view class="flex jc_around mgt-50">
  38. <view class="cancel" @click="cancelFn">取消</view>
  39. <view class="sure" @click="sureFn">确定</view>
  40. </view>
  41. </view>
  42. </template>
  43. <script setup>
  44. import { ref,reactive } from 'vue';
  45. // 基本案列数据
  46. const radiolist1 = reactive([
  47. {
  48. name: '内容粗糙或不美观',
  49. disabled: false,
  50. },
  51. {
  52. name: '广告展示频繁,影响体验',
  53. disabled: false,
  54. },
  55. {
  56. name: '其他意见或建议',
  57. disabled: false,
  58. },
  59. ]);
  60. const desc = ref()
  61. const tel = ref()
  62. const cancelFn = ()=>{
  63. uni.navigateBack()
  64. }
  65. const sureFn = ()=>{
  66. uni.showToast({
  67. title:'提交成功',
  68. icon:'none'
  69. })
  70. setTimeout(()=>{
  71. uni.navigateTo({
  72. url:'/pages/commonModule/complaintResult'
  73. })
  74. },500)
  75. }
  76. const radiovalue1 = ref('内容粗糙或不美观');
  77. const groupChange = (n) => {
  78. console.log('groupChange', n);
  79. };
  80. const radioChange = (n) => {
  81. console.log('radioChange', n);
  82. };
  83. </script>
  84. <style lang='scss' scoped>
  85. .content{
  86. margin-top: 60rpx;
  87. border-radius: 50rpx 50rpx 0 0;
  88. min-height: 100vh;
  89. padding: 50rpx 28rpx;
  90. background: linear-gradient(to bottom, #d6e6ff, #f3f4f8);
  91. }
  92. .cancel{
  93. border: 1rpx solid #999;
  94. height: 80rpx;
  95. line-height: 80rpx;
  96. width: 250rpx;
  97. text-align: center;
  98. border-radius: 12rpx;
  99. }
  100. .sure{
  101. height: 80rpx;
  102. line-height: 80rpx;
  103. width: 250rpx;
  104. text-align: center;
  105. border-radius: 12rpx;
  106. color: #fff;
  107. background: #f03433;
  108. }
  109. </style>