dataComputed.vue 1.3 KB
<template>
	<view class="pro_income" :style="{marginTop: marginTop + 'px' }">
		<view v-show="showTitle" class="f-32 l-h-38 col-3d f-w-500 mb-20">预计收入</view>
		<view class="computed" :style="{backgroundColor: bgColor}">
			<view class="cell">
				<text class="col-9 f-24 l-h-32 f-w-400">预计收入</text>
				<text>487.50</text>
			</view>
			<text class="string">=</text>
			<view class="cell">
				<text class="col-9 f-24 l-h-32 f-w-400">今日已完单</text>
				<text>458.41</text>
			</view>
			<text class="string">+</text>
			<view class="cell">
				<text class="col-9 f-24 l-h-32 f-w-400">今日下单进行中</text>
				<text>29.09</text>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		name:"dataComputed",
		props: {
			showTitle: {
				type: Boolean,
				default: true
			},
			bgColor: {
				type: String,
				default: '#F6F7FB'
			},
			marginTop: {
				type: Number,
				default: 40
			}
		}
	}
</script>

<style lang="scss" scoped>
.pro_income{
	.computed{
		display: flex;
		align-items: center;
		padding: 0 20rpx;
		height: 120rpx;
		background: #F6F7FB;
		border-radius: 12rpx;
		.cell{
			font-weight: 500;
			color: #3d3d3d;
			font-size: 32rpx;
			line-height: 42rpx;
		}
		.string{
			color: #3d3d3d;
			font-size: 36rpx;
			line-height: 48rpx;
			font-weight: 600;
			margin: 0 30rpx;
		}
	}
}
</style>