You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

transfer-verification.vue 4.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246
  1. <template>
  2. <view class="oderPage">
  3. <u-form :model="form" ref="myForm">
  4. <view class="from">
  5. <u-form-item prop="cardState">
  6. <view class="from_item">
  7. <text><text style="color: red">*</text>是否保留卡签:</text>
  8. <radio-group @change="radioChange" class="radios">
  9. <block v-for="(item, index) in radiolist1" :key="item.val">
  10. <view class="radio-box">
  11. <radio :value="item.val" :checked="form.serviceType == item.val" color="#13e7c1"
  12. style="transform:scale(0.75)" />
  13. <view>{{item.name}}</view>
  14. </view>
  15. </block>
  16. </radio-group>
  17. </view>
  18. </u-form-item>
  19. </view>
  20. </u-form>
  21. <button class="submit" @click="toPage()">下一步</button>
  22. </view>
  23. </template>
  24. <script setup lang="ts">
  25. import {
  26. ref,
  27. reactive
  28. } from "vue";
  29. import {
  30. onLoad
  31. } from "@dcloudio/uni-app";
  32. // 表单数据
  33. const form = reactive({
  34. serviceType: '',
  35. serviceTypeName: '保留卡签',
  36. mobile: "",
  37. code: '',
  38. });
  39. // 单选数据列表 保留卡签,卡签指向人,不保留卡签,卡签指向车
  40. const radiolist1 = reactive([{
  41. name: "保留卡签",
  42. val: 'WITHCUSTOMER',
  43. },
  44. {
  45. name: "不保留卡签",
  46. val: "WITHVEHICLE",
  47. }
  48. ]);
  49. //倒计时时常
  50. const codeDuration = ref(0);
  51. let interval = null;
  52. /* 验证码倒计时 */
  53. const codeInterval = () => {
  54. codeDuration.value = 60;
  55. interval = setInterval(() => {
  56. codeDuration.value--;
  57. if (codeDuration.value === 0) {
  58. if (interval) {
  59. clearInterval(interval);
  60. interval = null;
  61. }
  62. }
  63. }, 1000);
  64. };
  65. onLoad((option) => {
  66. form.mobile = option.mobile
  67. });
  68. // 单选
  69. const radioChange = (e : any) => {
  70. console.log(e);
  71. form.serviceType = e.detail.value
  72. };
  73. //下一步
  74. const toPage = () => {
  75. uni.$emit('queryCardlossStatus', {
  76. type: form.serviceType
  77. })
  78. uni.navigateBack()
  79. };
  80. </script>
  81. <style>
  82. page {
  83. width: 100%;
  84. height: 100%;
  85. display: flex;
  86. flex-direction: column;
  87. background-color: ##eef7f7;
  88. }
  89. </style>
  90. <style lang="scss" scoped>
  91. .radios {
  92. display: flex;
  93. }
  94. .radio-box {
  95. display: flex;
  96. align-items: center;
  97. padding-left: 40rpx;
  98. }
  99. .hint2 {
  100. display: flex;
  101. .green {
  102. font-size: 28rpx;
  103. color: #00b38b;
  104. }
  105. .grey {
  106. font-size: 24rpx;
  107. color: #000000;
  108. margin-left: 16rpx;
  109. }
  110. }
  111. .oderPage {
  112. flex: 1;
  113. width: 100%;
  114. .from1 {
  115. background-color: #fff;
  116. margin-top: 30rpx;
  117. padding: 0 30rpx;
  118. ::v-deep .uni-forms-item {
  119. border-bottom: 1rpx solid #ccc;
  120. padding: 15rpx 0;
  121. margin-bottom: 0;
  122. .uni-forms-item__label {
  123. font-size: 28rpx;
  124. height: 50rpx;
  125. }
  126. .uni-forms-item__content {
  127. display: flex;
  128. }
  129. .uni-easyinput__content-input {
  130. font-size: 28rpx;
  131. height: 50rpx;
  132. }
  133. }
  134. .btn {
  135. line-height: 38rpx;
  136. font-size: 24rpx;
  137. font-family: Microsoft YaHei;
  138. font-weight: 400;
  139. color: #ffffff;
  140. background: #00b38b;
  141. border-radius: 10rpx;
  142. padding: 10rpx 15rpx;
  143. }
  144. }
  145. .from {
  146. background-color: #fff;
  147. margin-top: 30rpx;
  148. padding: 0 30rpx;
  149. ::v-deep .u-form-item {
  150. padding: 0;
  151. line-height: normal;
  152. .u-form-item__message {
  153. margin-bottom: 12rpx;
  154. }
  155. }
  156. .from_item {
  157. display: flex;
  158. flex-wrap: nowrap;
  159. justify-content: space-between;
  160. align-items: center;
  161. height: 80rpx;
  162. border-bottom: 1rpx solid #dcdcdc;
  163. .btn {
  164. font-size: 24rpx;
  165. font-family: Microsoft YaHei;
  166. font-weight: 400;
  167. color: #ffffff;
  168. background: #00b38b;
  169. border-radius: 10rpx;
  170. padding: 10rpx 15rpx;
  171. }
  172. ::v-deep .input {
  173. text-align: left;
  174. flex: 1;
  175. background: transparent;
  176. input {
  177. text-align: left;
  178. }
  179. }
  180. }
  181. .from_item1 {
  182. display: flex;
  183. flex-wrap: nowrap;
  184. flex-direction: column;
  185. justify-content: space-between;
  186. padding: 30rpx;
  187. border-bottom: #dcdcdc 1px solid;
  188. input {
  189. text-align: right;
  190. }
  191. .textarea {
  192. background-color: #f1f1f1;
  193. width: 100%;
  194. border-radius: 20rpx;
  195. margin-top: 10rpx;
  196. text-indent: 1rem;
  197. height: 180rpx;
  198. padding: 20rpx;
  199. box-sizing: border-box;
  200. }
  201. }
  202. }
  203. }
  204. .submit {
  205. background: linear-gradient(to left, #43a1e0 0%, #13e7c1 100%);
  206. width: 670rpx;
  207. height: 80rpx;
  208. color: #fff;
  209. border-radius: 100rpx;
  210. position: fixed;
  211. left: 50%;
  212. transform: translate(-50%);
  213. bottom: 60rpx;
  214. font-size: 32rpx;
  215. }
  216. </style>