学员端小程序
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.

221 lines
4.4 KiB

  1. <template>
  2. <view class="step1">
  3. <view class="card">
  4. <view class="dateBox">
  5. <view class="month-row">
  6. <view class="month">2032.08</view>
  7. <view class="arrow">
  8. <u-icon name="arrow-down" :size="12" :color="'#1989FA'"></u-icon>
  9. </view>
  10. </view>
  11. <view class="date_row">
  12. <view class="icon left">
  13. <u-icon name="arrow-left" :size="12" :color="'#fff'"></u-icon>
  14. </view>
  15. <view class="dateArr">
  16. <view class="date" v-for="(item,index) in dateArr" :key="index" :class="{active: index==1}">
  17. <view class="week">{{ item.week }}</view>
  18. <view class="num">{{ item.num }}</view>
  19. </view>
  20. </view>
  21. <view class="icon right">
  22. <u-icon name="arrow-right" :size="12" :color="'#fff'"></u-icon>
  23. </view>
  24. </view>
  25. </view>
  26. </view>
  27. <view class="card">
  28. <view class="timeCon">
  29. <view class="h2">上午</view>
  30. <view class="time_box">
  31. <view class="time_item">
  32. <view class="lab">已过期</view>
  33. <view class="time">06:00-07:00</view>
  34. </view>
  35. <view class="time_item">
  36. <view class="lab">已约满</view>
  37. <view class="time">06:00-07:00</view>
  38. </view>
  39. <view class="time_item">
  40. <view class="lab">可预约</view>
  41. <view class="time">06:00-07:00</view>
  42. </view>
  43. </view>
  44. <view class="h2">下午</view>
  45. <view class="time_box">
  46. <view class="time_item">
  47. <view class="lab">已过期</view>
  48. <view class="time">06:00-07:00</view>
  49. </view>
  50. <view class="time_item">
  51. <view class="lab">已约满</view>
  52. <view class="time">06:00-07:00</view>
  53. </view>
  54. <view class="time_item">
  55. <view class="lab">可预约</view>
  56. <view class="time">06:00-07:00</view>
  57. </view>
  58. </view>
  59. </view>
  60. </view>
  61. <view class="btn" @click="changeStep(2)">下一步</view>
  62. </view>
  63. </template>
  64. <script>
  65. export default {
  66. data() {
  67. return {
  68. dateArr: [
  69. {week: '一', num: '08'},
  70. {week: '二', num: '09'},
  71. {week: '三', num: '10'},
  72. {week: '四', num: '11'},
  73. {week: '五', num: '12'},
  74. ]
  75. }
  76. },
  77. methods: {
  78. changeStep(val) {
  79. this.$emit('changeStep', val)
  80. }
  81. }
  82. }
  83. </script>
  84. <style lang="scss" scoped>
  85. .card {
  86. width: 100%;
  87. overflow: hidden;
  88. .dateBox {
  89. padding: 36rpx 0 40rpx 0;
  90. .month-row {
  91. display: flex;
  92. justify-content: center;
  93. align-items: center;
  94. margin-bottom: 36rpx;
  95. .month {
  96. font-size: 32rpx;
  97. color: $themC;
  98. }
  99. .arrow {
  100. margin-left: 6rpx;
  101. }
  102. }
  103. .date_row {
  104. width: 100%;
  105. height: 100rpx;
  106. position: relative;
  107. .icon {
  108. width: 40rpx;
  109. height: 40rpx;
  110. background: rgba(51,51,51,0.18);
  111. backdrop-filter: blur(4rpx);
  112. position: absolute;
  113. top: 50%;
  114. transform: translateY(-50%);
  115. display: flex;
  116. align-items: center;
  117. justify-content: center;
  118. border-radius: 50%;
  119. &.left {
  120. left: 16rpx;
  121. }
  122. &.right {
  123. right: 16rpx;
  124. }
  125. }
  126. .dateArr {
  127. display: flex;
  128. padding: 0 70rpx;
  129. justify-content: space-between;
  130. .date {
  131. width: 74rpx;
  132. height: 100rpx;
  133. border-radius: 16rpx;
  134. display: flex;
  135. flex-direction: column;
  136. align-items: center;
  137. justify-content: center;
  138. font-size: 28rpx;
  139. color: #333;
  140. &.active {
  141. background: rgba(25,137,250,0.1);
  142. border: 2rpx solid #1989FA;
  143. color: $themC;
  144. }
  145. .week {
  146. }
  147. .num {
  148. margin-top: 4rpx;
  149. }
  150. }
  151. }
  152. }
  153. }
  154. }
  155. .card {
  156. .timeCon {
  157. padding: 0 24rpx 40rpx 24rpx;
  158. }
  159. .h2 {
  160. line-height: 90rpx;
  161. font-weight: 500;
  162. color: #333;
  163. }
  164. .time_box {
  165. display: flex;
  166. flex-wrap: wrap;
  167. justify-content: space-between;
  168. .time_item {
  169. width: 30%;
  170. height: 120rpx;
  171. background: #F8F8F8;
  172. border-radius: 12rpx;
  173. display: flex;
  174. flex-direction: column;
  175. justify-content: center;
  176. align-items: center;
  177. border-radius: 12rpx;
  178. color: #333;
  179. &.active {
  180. background: rgba(25,137,250,0.1);
  181. border: 2rpx solid #1989FA;
  182. color: $themC;
  183. }
  184. &.disable {
  185. opacity: 0.5;
  186. }
  187. .lab {
  188. font-size: 28rpx;
  189. font-weight: 500;
  190. }
  191. .time {
  192. font-size: 24rpx;
  193. margin-top: 4rpx;
  194. }
  195. }
  196. }
  197. }
  198. .btn {
  199. width: 47%;
  200. height: 72rpx;
  201. background: #1989FA;
  202. border-radius: 8rpx;
  203. font-size: 28rpx;
  204. color: #fff;
  205. text-align: center;
  206. line-height: 72rpx;
  207. margin: 108rpx auto 50rpx auto;
  208. }
  209. </style>