普兆健康管家前端代码仓库
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.

129 lines
2.8 KiB

  1. <template>
  2. <view class="page__view">
  3. <navbar title="检测预约" leftClick @leftClick="$utils.navigateBack" color="#191919" bgColor="#FFFFFF" />
  4. <view class="main">
  5. <view class="tabs">
  6. <uv-tabs
  7. :list="tabs"
  8. :scrollable="false"
  9. lineColor="#7451DE"
  10. lineWidth="48rpx"
  11. lineHeight="4rpx"
  12. :activeStyle="{
  13. 'font-family': 'PingFang SC',
  14. 'font-weight': 500,
  15. 'font-size': '32rpx',
  16. 'line-height': 1.4,
  17. 'color': '#7451DE',
  18. }"
  19. :inactiveStyle="{
  20. 'font-family': 'PingFang SC',
  21. 'font-weight': 400,
  22. 'font-size': '32rpx',
  23. 'line-height': 1.4,
  24. 'color': '#181818',
  25. }"
  26. @click="clickTabs"
  27. ></uv-tabs>
  28. </view>
  29. <view class="list">
  30. <view class="list-item" v-for="item in list" :key="item.id">
  31. <checkupCard :data="item" @sendBack="openTrackingNoPopup(item.id)"></checkupCard>
  32. </view>
  33. </view>
  34. </view>
  35. <checkupTrackingNoPopup ref="checkupTrackingNoPopup" @submitted="getData"></checkupTrackingNoPopup>
  36. </view>
  37. </template>
  38. <script>
  39. import mixinsList from '@/mixins/list.js'
  40. import checkupCard from './checkupCard.vue'
  41. import checkupTrackingNoPopup from '@/pages_order/checkup/checkupTrackingNoPopup.vue'
  42. export default {
  43. mixins: [mixinsList],
  44. components: {
  45. checkupCard,
  46. checkupTrackingNoPopup,
  47. },
  48. data() {
  49. return {
  50. // 产品类型【选填】(0自采,1上门,2到店,3已取消)
  51. tabs: [
  52. { name: '全部' },
  53. { name: '自采' },
  54. { name: '上门' },
  55. { name: '到店' },
  56. { name: '已取消' },
  57. ],
  58. mixinsListApi: 'getSubscribeList',
  59. }
  60. },
  61. methods: {
  62. //点击tab栏
  63. clickTabs({ index }) {
  64. if (index == 0) {
  65. delete this.queryParams.type
  66. } else {
  67. this.queryParams.type = index - 1
  68. }
  69. this.getData()
  70. },
  71. openTrackingNoPopup(id) {
  72. this.$refs.checkupTrackingNoPopup.open(id)
  73. },
  74. },
  75. }
  76. </script>
  77. <style scoped lang="scss">
  78. .page__view {
  79. width: 100vw;
  80. min-height: 100vh;
  81. background-color: $uni-bg-color;
  82. position: relative;
  83. /deep/ .nav-bar__view {
  84. position: fixed;
  85. top: 0;
  86. left: 0;
  87. }
  88. }
  89. .main {
  90. width: 100vw;
  91. padding: calc(var(--status-bar-height) + 244rpx) 32rpx 40rpx 32rpx;
  92. box-sizing: border-box;
  93. .tabs {
  94. position: fixed;
  95. top: calc(var(--status-bar-height) + 120rpx);
  96. left: 0;
  97. width: 100%;
  98. height: 84rpx;
  99. background: #FFFFFF;
  100. /deep/ .uv-tabs__wrapper__nav__line {
  101. border-radius: 2rpx;
  102. }
  103. }
  104. }
  105. .list {
  106. &-item {
  107. & + & {
  108. margin-top: 40rpx;
  109. }
  110. }
  111. }
  112. </style>