<template> <view class="model"> <view class="model-content"> <view class="model-content-1"> <view class="title">今日营收</view> <view class="total"> <view class="total-title">936.67元</view> <view> <u-icon label="" size="53" name="./../../../static/images/1.png"></u-icon> </view> </view> </view> <view class="model-content-2"> <view class="model-content-2-item"> <view>393 <text>元</text> </view> <view>今日欠费</view> </view> <view class="model-content-2-item"> <view>1485 <text>次</text> </view> <view>今日停车</view> </view> <view class="model-content-2-item"> <view>85 <text>次</text> </view> <view>今日扫码</view> </view> </view> <view class="model-content-1"> <view class="title">路段总数</view> <view class="total"> <view class="total-title red">25个</view> <view> <u-icon label="" size="53" name="./../../../static/images/2.png"></u-icon> </view> </view> </view> <view class="model-content-1"> <view class="title">泊位总数</view> <view class="total"> <view class="total-title orange">1247个</view> <view> <u-icon label="" size="53" name="./../../../static/images/3.png"></u-icon> </view> </view> </view> </view> <view class="model-line"> <view class="report-header"> <view class="report-header-left"> 营收趋势分析 </view> <view class="report-header-right"> <view class="report-header-right-item" :class="{'current': current === 1}" @click="current = 1">日 </view> <view class="report-header-right-item" :class="{'current': current === 2}" @click="current = 2">月 </view> <view class="report-header-right-item" :class="{'current': current === 3}" @click="current = 3">年 </view> </view> </view> <view class="charts-box"> <qiun-data-charts type="line" :chartData="chartData" :opts="opts" /> </view> </view> </view> </template> <script> export default { data() { return { current: 3, chartData: { categories: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12], series: [{ name: '收益', data: [0, 0, 0, 0, 0, 0, 0, 0, 227834.88, 279992.99, 284646.33, 182900.91 ] }], }, opts: { xAxis: {}, yAxis: { showTitle: true, splitNumber: 6, data: [{ title: '收益(元)', max: 300000, min: 0 }] }, legend: { show: false }, padding: [10, 0, 10, 0], dataLabel: false } } }, methods: { } } </script> <style lang="scss" scoped> .model { padding: 34rpx; font-family: SourceHanSansSC-regular; &-content { background-color: #EAE7E7; border-radius: 20rpx; padding: 22rpx 14rpx; &-1 { background-color: #fff; border-radius: 16rpx; padding: 46rpx 30rpx; margin-bottom: 24rpx; .title { color: #AEAEB2; font-size: 36rpx; } .total { display: flex; justify-content: space-between; align-items: center; &-title { color: #5756D7; font-size: 56rpx; font-family: SourceHanSansSC-bold; } .red { color: #FF3A30; } .orange { color: #FF9502; } } } &-2 { background-color: #fff; border-radius: 16rpx; padding: 52rpx 18rpx; margin-bottom: 24rpx; display: flex; justify-content: space-between; align-items: center; &-item { border-right: solid 1px #bbb; width: 33%; text-align: center; &:last-child { border-right: none; } view { font-size: 34rpx; color: #AEAEB2; &:first-child { font-size: 46rpx; color: #000; font-family: SourceHanSansSC-bold; font-weight: 600; margin-bottom: 20rpx; text { font-size: 34rpx; } } } } } } &-line { margin-top: 50rpx; .report-header { display: flex; align-items: center; &-left { border-left: solid 4px #EC0D0D; padding-left: 10rpx; color: #101010; font-size: 30rpx; margin-right: 40rpx; } &-right { display: flex; &-item { width: 100rpx; height: 60rpx; line-height: 60rpx; text-align: center; border: solid 1px #008CFF; border-right: none; &:last-child { border-radius: 0 8rpx 8rpx 0; border-right: solid 1px #008CFF; } &:first-child { border-radius: 8rpx 0 0 8rpx; } } .current { background-color: #008CFF; color: #fff; } } } .charts-box { margin-top: 30rpx; width: 100%; height: 700rpx; } } } </style>