index.vue 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. <template>
  2. <view class="content">
  3. <view class="backg3 flex" style="padding-top: 23rpx;" v-if="isWoman" @click="clickMan">
  4. <view style="margin-left: 40rpx;">
  5. <view style="color: #000000;font-size: 32rpx;font-weight: 500;">女生专区</view>
  6. <image style="width: 48rpx;height: 9rpx;margin-left: 20rpx;" src="https://mxys.chuanghai-tech.com/wmfile/20250811/5f75606616aa4c7f8c304368f8663a39.png"></image>
  7. </view>
  8. <view style="margin-left: 73rpx;">男生专区</view>
  9. </view>
  10. <view class="backg3 flex" style="padding-top: 23rpx;" v-else @click="clickMan">
  11. <view style="margin-left: 40rpx;">
  12. 女生专区
  13. </view>
  14. <view style="margin-left: 73rpx;">
  15. <view style="color: #000000;font-size: 32rpx;font-weight: 500;">男生专区</view>
  16. <image style="width: 48rpx;height: 9rpx;margin-left: 20rpx;" src="https://mxys.chuanghai-tech.com/wmfile/20250811/5f75606616aa4c7f8c304368f8663a39.png"></image>
  17. </view>
  18. </view>
  19. <view @click="toXiang" v-for="(item,index) in 3" :key="index" :class="index==0?'backg1':'backg2'">
  20. <image style="width: 289rpx;height: 319rpx;margin:31rpx 0 0 20rpx;background-color: #000;"></image>
  21. <view style="margin:31rpx 0 0 26rpx;">
  22. <view style="font-size: 32rpx;color: #000000;font-weight: 500;margin-top: 7rpx;">月度套餐</view>
  23. <view style="margin-top: 7rpx;">每月14号配送定制蛋糕</view>
  24. <view class="lijia">例假关怀</view>
  25. <view class="q_time">
  26. <view style="line-height: 30px;">时间</view>
  27. <view class="q_line"></view>
  28. <view style="width: 276rpx;margin-left: 13rpx;">2025-07-28 12:00:00 —2025-12-31 23:59:59</view>
  29. </view>
  30. <view class="jiage">¥98.00</view>
  31. </view>
  32. </view>
  33. </view>
  34. </template>
  35. <script>
  36. export default {
  37. data() {
  38. return {
  39. isWoman:true,//true是。false不是
  40. }
  41. },
  42. onLoad() {
  43. },
  44. methods:{
  45. //切换男女专区
  46. clickMan(){
  47. this.isWoman=!this.isWoman
  48. },
  49. //跳转到详情页
  50. toXiang(){
  51. uni.navigateTo({
  52. url: '/pages/qinglv/xiang'
  53. })
  54. },
  55. },
  56. }
  57. </script>
  58. <style>
  59. .content{
  60. width: 100%;
  61. height: 100%;
  62. background-color: #F2F2F2;
  63. }
  64. .backg3{
  65. display: flex;
  66. width: 750rpx;
  67. height: 100%;
  68. background-color: #FFE9CA;
  69. }
  70. .backg1{
  71. display: flex;
  72. width: 750rpx;
  73. height: 100%;
  74. margin-bottom: 20rpx;
  75. /* background-color: #FFE9CA; */
  76. background: linear-gradient(180deg, #FFE9CA 0%, #FFFFFF 28.17%, #FFFFFF 32.53%, #F2F3F5 100%);
  77. }
  78. .backg2{
  79. display: flex;
  80. margin-top: 20rpx;
  81. width: 750rpx;
  82. height: 100%;
  83. background-color: #FFFFFF;
  84. }
  85. .lijia{
  86. margin-top: 7rpx;
  87. width: 125rpx;
  88. height: 51rpx;
  89. opacity: 1;
  90. border-radius: 73rpx;
  91. border: 1rpx solid #FF8D1A;
  92. font-size: 24rpx;
  93. line-height: 51rpx;
  94. color: rgba(255, 141, 26, 1);
  95. text-align: center;
  96. }
  97. .q_time{
  98. display: flex;
  99. margin-top: 15rpx;
  100. }
  101. .q_line{
  102. margin: 12rpx 0 0 13rpx;
  103. width: 1rpx;
  104. height: 47rpx;
  105. background-color: #808080;
  106. }
  107. .jiage{
  108. margin-top: 27rpx;
  109. font-size: 40rpx;
  110. font-weight: 500;
  111. color: rgba(255, 91, 26, 1);
  112. }
  113. </style>