Browse Source

statistics page

邹能昇 3 months ago
parent
commit
8acd4e044e

+ 13 - 0
nova-werun/pages/home/statistics/index.js

@@ -15,6 +15,8 @@ Page({
             contentpadding: 0, //顶部padding高度
 
             active: 0,
+            //
+            day:'7'
     },
 
     /**
@@ -92,4 +94,15 @@ Page({
     onChange(event) {
         this.setData({ active: event.detail });
       },
+      changeday(){
+          if(this.data.day=='7'){
+              this.setData({
+                  day:'30'
+              })
+          }else{
+            this.setData({
+                day:'7'
+            })
+          }
+      }
 })

+ 15 - 0
nova-werun/pages/home/statistics/index.less

@@ -2,6 +2,7 @@
 .all{
     width: 100vw;
     padding-top: 20rpx;
+    overflow-y: scroll;
     .number{
         width: 100%;
         height: 150rpx;
@@ -161,6 +162,7 @@
     padding-top: 20rpx;
     padding-left: 30rpx;
     padding-right: 30rpx;
+    overflow-y: scroll;
     .card1{
         width: 100%;
         height: 360rpx;
@@ -308,6 +310,19 @@
                     justify-content: center;
                     align-items: center;
                 }
+                .card3-bu2{
+                    width: 88rpx;
+                    height: 45rpx;
+                    font-size: 28rpx;
+                    border-radius: 20rpx;
+                    margin-left: 10rpx;
+                    border: solid black 2px;
+                    display: flex;
+                    justify-content: center;
+                    align-items: center;
+                    background-color: orange;
+                    color: white;
+                }
             }
         }
         .card3-midin{

+ 2 - 2
nova-werun/pages/home/statistics/index.wxml

@@ -105,8 +105,8 @@
                 生涯合计
             </view>
             <view class="card3-title2">
-                <view class="card3-bu">7天</view>
-                <view class="card3-bu">30天</view>
+                <view class="{{day=='7'?'card3-bu2':'card3-bu'}}" bindtap="changeday">7天</view>
+                <view class="{{day=='30'?'card3-bu2':'card3-bu'}}" bindtap="changeday">30天</view>
             </view>
         </view>
         <view class="card3-midin">

File diff suppressed because it is too large
+ 0 - 0
nova-werun/pages/home/statistics/index.wxss


Some files were not shown because too many files changed in this diff