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

82 lines
1.6 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. <template>
  2. <view class="coachInfo">
  3. <view class="card">
  4. <view class="avatar">
  5. <image :src="FormData.photoPath" mode="" @error="handleImageError()"></image>
  6. </view>
  7. <view class="rightTxt">
  8. <view class="name_row">
  9. <view class="name">{{ FormData.coachName }}</view>
  10. <view class="tag active" v-if="vuex_userInfo.coachId==FormData.coachId">已绑定</view>
  11. <view class="tag" v-else>未绑定</view>
  12. </view>
  13. <moreRight text="预约其它教练课程"/>
  14. </view>
  15. </view>
  16. </view>
  17. </template>
  18. <script>
  19. export default {
  20. props: ['FormData'],
  21. methods: {
  22. handleImageError() {
  23. console.log('图片加载失败')
  24. this.FormData.photoPath = require('@/static/images/index/avatar.png')
  25. }
  26. }
  27. }
  28. </script>
  29. <style lang="scss" scoped>
  30. .coachInfo {
  31. .card {
  32. width: 100%;
  33. height: 180rpx;
  34. display: flex;
  35. align-items: center;
  36. padding: 0 36rpx;
  37. .avatar {
  38. width: 100rpx;
  39. height: 98rpx;
  40. border-radius: 50%;
  41. overflow: hidden;
  42. background-color: #F2F2F2;
  43. }
  44. .rightTxt {
  45. flex: 1;
  46. padding: 0 0 0 34rpx;
  47. .name_row {
  48. display: flex;
  49. align-items: center;
  50. margin-bottom: 16rpx;
  51. .name {
  52. font-size: 32rpx;
  53. color: #333;
  54. font-weight: 550;
  55. }
  56. .tag {
  57. width: 98rpx;
  58. height: 40rpx;
  59. background: #F2F2F2;
  60. border-radius: 4rpx;
  61. text-align: center;
  62. line-height: 40rpx;
  63. text-align: center;
  64. margin-left: 24rpx;
  65. color: #959595;
  66. &.active {
  67. color: $themC;
  68. background: #E8F3FE;
  69. }
  70. }
  71. }
  72. moreright {
  73. }
  74. }
  75. }
  76. }
  77. </style>