江西小程序管理端
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.

202 lines
4.5 KiB

1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
  1. <template>
  2. <view class="pageBgImg pad">
  3. <view class="searchBox">
  4. <searchRow placeholder="搜索学员姓名、学员手机号"></searchRow>
  5. </view>
  6. <view class="card" v-if="identity=='实操教练'">
  7. <view class="addStudent">
  8. <view class="h2">我的学员</view>
  9. <view class="btnBg" @click="$goPage('/pages/recordEntry/student/addStudent/addStudent')">手动添加</view>
  10. </view>
  11. </view>
  12. <view class="card">
  13. <view class="statistics">
  14. <view class="statisticsItem">
  15. <view class="val">260</view>
  16. <view class="lab">累计学员数量</view>
  17. </view>
  18. <view class="statisticsItem">
  19. <view class="val">260</view>
  20. <view class="lab">今日新增学员</view>
  21. </view>
  22. <view class="statisticsItem" v-if="identity=='校长'">
  23. <view class="val">260</view>
  24. <view class="lab">今日退学学员</view>
  25. </view>
  26. </view>
  27. </view>
  28. <view class="screen_row">
  29. <view class="selectItem" @click="showDatePicker=true">
  30. <view class="text ">{{screen.timer}}</view>
  31. <view class="downIcon">
  32. <u-icon name="arrow-down" :size="'28rpx'"></u-icon>
  33. </view>
  34. </view>
  35. <view class="selectItem" @click="showCar=true">
  36. <view class="text oneRowText">{{screen.car}}</view>
  37. <view class="downIcon">
  38. <u-icon name="arrow-down" :size="'28rpx'"></u-icon>
  39. </view>
  40. </view>
  41. <view class="selectItem" @click="showClass=true">
  42. <view class="text oneRowText">{{screen.className}}</view>
  43. <view class="downIcon">
  44. <u-icon name="arrow-down" :size="'28rpx'"></u-icon>
  45. </view>
  46. </view>
  47. </view>
  48. <view class="list">
  49. <view class="card" @click="$goPage('/pages/recordEntry/student/studentDetail/studentDetail')">
  50. <appointItem-student/>
  51. </view>
  52. </view>
  53. <UserTab name ='学员'></UserTab>
  54. <u-datetime-picker
  55. :show="showDatePicker"
  56. mode="date"
  57. :visibleItemCount="4"
  58. :closeOnClickOverlay="false"
  59. @confirm="confirmDatePicker"
  60. ></u-datetime-picker>
  61. <u-picker :show="showCar" :columns="carArr" keyName="lab" @confirm="confirmCar" @cancel="showCar=false"></u-picker>
  62. <u-picker :show="showClass" :columns="classArr" keyName="lab" @confirm="confirmClass" @cancel="showClass=false"></u-picker>
  63. </view>
  64. </template>
  65. <script>
  66. export default {
  67. data() {
  68. return {
  69. screen: {
  70. timer: '报名时间',
  71. car: '全部车型',
  72. className: '全部班型'
  73. },
  74. showDatePicker: false,
  75. showCar: false,
  76. showClass: false,
  77. carArr: [
  78. [
  79. {lab: 'C1',id: 1},
  80. {lab: 'C2',id: 2},
  81. ]
  82. ],
  83. classArr: [
  84. [
  85. {lab: '普通班型',id: 1},
  86. {lab: 'C2vip',id: 2},
  87. ]
  88. ],
  89. }
  90. },
  91. onShow() {
  92. uni.hideTabBar();
  93. },
  94. methods: {
  95. confirmDatePicker(val) {
  96. this.showDatePicker = false
  97. console.log(val)
  98. console.log(uni.$u.date(val.value, 'yyyy-mm-dd'))
  99. this.screen.timer = uni.$u.date(val.value, 'yyyy-mm-dd')
  100. console.log(this.screen.timer)
  101. },
  102. confirmCar(val) {
  103. let item = val.value[0]
  104. this.screen.car = item.lab
  105. this.showCar = false
  106. },
  107. confirmClass(val) {
  108. let item = val.value[0]
  109. this.screen.className = item.lab
  110. this.showClass = false
  111. }
  112. }
  113. }
  114. </script>
  115. <style lang="scss" scoped>
  116. .card {
  117. padding: 0 28rpx;
  118. margin-bottom: 24rpx;
  119. }
  120. .searchBox {
  121. padding: 140rpx 0 24rpx 0;
  122. }
  123. .addStudent {
  124. height: 108rpx;
  125. background: #FFFFFF;
  126. border-radius: 16rpx;
  127. display: flex;
  128. align-items: center;
  129. justify-content: space-between;
  130. .h2 {
  131. font-size: 32rpx;
  132. font-weight: 500;
  133. }
  134. .btnBg {
  135. width: 192rpx;
  136. }
  137. }
  138. .statistics {
  139. display: flex;
  140. height: 200rpx;
  141. .statisticsItem {
  142. display: flex;
  143. align-items: center;
  144. justify-content: center;
  145. flex-direction: column;
  146. flex: 1;
  147. .val {
  148. font-weight: 600;
  149. font-size: 56rpx;
  150. color: $themC;
  151. position: relative;
  152. &::before {
  153. content: '个';
  154. position: absolute;
  155. right: -30rpx;
  156. bottom: 10rpx;
  157. font-size: 24rpx;
  158. font-weight: 400;
  159. }
  160. }
  161. .lab {
  162. font-size: 28rpx;
  163. // margin-top: 20rpx;
  164. }
  165. }
  166. }
  167. .screen_row {
  168. display: flex;
  169. margin-bottom: 24rpx;
  170. width: 100%;
  171. justify-content: space-between;
  172. .selectItem {
  173. display: flex;
  174. padding: 0 16rpx;
  175. border: 2rpx solid rgba(25,137,250,0.3);
  176. height: 60rpx;
  177. border-radius: 16rpx;
  178. background-color: #FFFFFF;
  179. line-height: 60rpx;
  180. align-items: center;
  181. width: 29%;
  182. .text {
  183. color: $themC;
  184. flex: 1;
  185. text-align: center;
  186. }
  187. .downIcon {
  188. width: 24rpx;
  189. }
  190. }
  191. }
  192. </style>