diff --git a/绿纤uni-app/package.json b/绿纤uni-app/package.json index 180a97b..68383c4 100644 --- a/绿纤uni-app/package.json +++ b/绿纤uni-app/package.json @@ -1,6 +1,7 @@ { "dependencies": { "@qiun/ucharts": "^2.5.0-20230101", - "html2canvas": "^1.4.1" + "html2canvas": "^1.4.1", + "ucharts": "^0.0.0" } } diff --git a/绿纤uni-app/pages/me/me.vue b/绿纤uni-app/pages/me/me.vue index 5cd3c42..9b4e347 100644 --- a/绿纤uni-app/pages/me/me.vue +++ b/绿纤uni-app/pages/me/me.vue @@ -42,64 +42,97 @@ - - - - - 开单金额 - ¥{{ (performanceData.BillingAmount || 0).toFixed(2) }} + + + + + 开单金额 + ¥{{ (performanceData.BillingAmount || 0).toFixed(2) }} + 退卡:¥{{ (performanceData.RefundAmount || 0).toFixed(2) }} - - 退卡金额 - ¥{{ (performanceData.RefundAmount || 0).toFixed(2) }} - - - - {{ performanceData.HeadCount || 0 }} - 人头 + + + + + {{ performanceData.HeadCount || 0 }}人头 - - {{ performanceData.PersonCount || 0 }} - 人次 + + + {{ performanceData.PersonCount || 0 }}人次 - - - - 消耗金额 - ¥{{ (performanceData.ConsumeAmount || 0).toFixed(2) }} + + + + + + + 消耗金额 + ¥{{ (performanceData.ConsumeAmount || 0).toFixed(2) }} + + + + - - 手工费 - ¥{{ performanceData.LaborCost || 0 }} + + + + + 手工费 + ¥{{ performanceData.LaborCost || 0 }} + + + + - - 项目数 - {{ performanceData.ConsumeProjectCount || 0 }} + + + + + 项目数 + {{ performanceData.ConsumeProjectCount || 0 }} + + + + - - - - ¥{{ (performanceData.OrderAchievement || 0).toFixed(2) }} - 开卡业绩 + + + + 开卡业绩 + ¥{{ (performanceData.OrderAchievement || 0).toFixed(2) }} + - - ¥{{ (performanceData.ConsumeAchievement || 0).toFixed(2) }} - 消耗业绩 + + + 项目数 {{ (performanceData.ConsumeProjectCount || 0).toFixed(0) }} + - - - {{ (performanceData.ConsumeProjectCount || 0).toFixed(2) }} - 项目数 + + + + + 消耗业绩 + ¥{{ (performanceData.ConsumeAchievement || 0).toFixed(2) }} + + + + - - ¥{{ performanceData.ConsumeLaborCost || 0 }} - 手工 + + + + 手工 + ¥{{ performanceData.ConsumeLaborCost || 0 }} + + + + @@ -1558,4 +1591,139 @@ transform: scale(0.98); box-shadow: 0 1rpx 4rpx rgba(67, 160, 71, 0.3); } + +/* 优化后的业绩数据样式 */ +.performance-grid { + display: flex; + gap: 20rpx; + margin-bottom: 24rpx; + margin-top: 20rpx; +} + +.glass-card { + background: rgba(255, 255, 255, 0.65); + backdrop-filter: blur(20px) saturate(180%); + -webkit-backdrop-filter: blur(20px) saturate(180%); + border-radius: 20rpx; + border: 1px solid rgba(255, 255, 255, 0.8); + box-shadow: 0 8rpx 24rpx rgba(0, 0, 0, 0.06); + transition: all 0.3s ease; + position: relative; + overflow: hidden; +} + +.glass-card:active { + transform: scale(0.98); + box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.08); +} + + +.billing-card { + flex: 1; + /* min-width: set dynamically via flex, but we want aspect ratio */ + aspect-ratio: 1 / 1; + display: flex; + flex-direction: column; + justify-content: center; /* Center content vertically */ + padding: 24rpx; + background: linear-gradient(135deg, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0.5) 100%); +} + +.billing-main { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + flex: 1; + width: 100%; +} + +.billing-card .card-label { + font-size: 36rpx; /* ~18px */ + font-weight: bold; + color: #333333; + margin-bottom: 16rpx; +} + +.billing-value { + font-size: 56rpx; /* Increased slightly for emphasis */ + font-weight: bold; + color: #1f2937; + margin-bottom: 12rpx; + line-height: 1.1; + text-align: center; +} + +.refund-value { + font-size: 26rpx; /* ~13px */ + color: #999999; + font-style: italic; + margin-bottom: 20rpx; +} + +.billing-footer { + display: flex; + justify-content: space-around; + width: 100%; + padding-top: 20rpx; + border-top: 1px solid rgba(0,0,0,0.05); + margin-top: auto; /* Push to bottom */ +} + +.count-item { + display: flex; + align-items: center; + gap: 6rpx; +} + +.count-text { + font-size: 30rpx; /* ~15px */ + color: #666666; + line-height: 1.5; +} + +.right-column { + display: flex; + flex-direction: column; + justify-content: space-between; /* Distribute cards to match height if needed */ + gap: 20rpx; + width: 48%; /* Slightly wider to balance */ +} + +.stat-card { + padding: 24rpx 30rpx; + display: flex; + align-items: center; + justify-content: space-between; + position: relative; + height: 100%; + min-height: 140rpx; +} + +.stat-content { + position: relative; + z-index: 2; +} + +.stat-card .card-label { + font-size: 26rpx; + color: #666; + margin-bottom: 8rpx; +} + +.stat-value { + font-size: 36rpx; + font-weight: bold; + color: #1f2937; +} + +.bg-icon { + position: absolute; + right: 20rpx; + top: 50%; + transform: translateY(-50%); + opacity: 0.2; + z-index: 1; + pointer-events: none; +}