<template>
|
<!-- 称重历史-->
|
<view class="weigh-history"
|
v-if="list.length!==0">
|
<view class="block-main">
|
<view class="weigh-item"
|
v-for='item in list'
|
:key="item.id">
|
<view class="weigh-time">
|
<u-tag :text="item.createTime.slice(-8,-3)"
|
plain></u-tag>
|
</view>
|
<view class="item-block">
|
<view class="item">
|
<view class="concrete"
|
:style="{ backgroundImage: `url(${onlineurl}/appimg/image/banner/skin.png)`, backgroundSize: 'cover', backgroundRepeat: 'no-repeat' }">
|
皮</view>
|
<view class="num">{{ item.skin ||'' }}</view>
|
</view>
|
<view class="item">
|
<view class="concrete"
|
:style="{ backgroundImage: `url(${onlineurl}/appimg/image/banner/hair.png)`, backgroundSize: 'cover', backgroundRepeat: 'no-repeat' }">
|
毛</view>
|
<view class="num">{{ item.hair ||''}}</view>
|
</view>
|
<view class="item">
|
<view class="concrete"
|
:style="{ backgroundImage: `url(${onlineurl}/appimg/image/banner/clean.png)`, backgroundSize: 'cover', backgroundRepeat: 'no-repeat' }">
|
净</view>
|
<view class="num">{{ item.clean||'' }}</view>
|
</view>
|
</view>
|
</view>
|
</view>
|
</view>
|
</template>
|
|
<script>
|
import { onlineurl } from '@/api/request.js'
|
export default {
|
name: "weighItem",
|
props: {
|
list: {
|
type: Array,
|
default: () => []
|
}
|
},
|
data() {
|
return {
|
onlineurl,
|
};
|
}
|
}
|
</script>
|
|
<style lang="scss"
|
scoped>
|
.weigh-history {
|
width: 690rpx;
|
height: 100%;
|
min-height: 200rpx;
|
margin: vww(20) auto;
|
background: #ffffff;
|
box-shadow: 4rpx 6rpx 51rpx 0rpx rgba(73, 120, 240, 0.11);
|
border-radius: 20rpx;
|
position: relative;
|
font-size: 30rpx;
|
font-weight: 300;
|
color: #303030;
|
overflow: hidden;
|
|
.block-main {
|
width: 100%;
|
display: flex;
|
flex-direction: column;
|
padding: 20rpx;
|
box-sizing: border-box;
|
|
.weigh-item {
|
width: 100%;
|
height: vww(80);
|
@include flex;
|
flex-direction: column;
|
justify-content: space-around;
|
align-items: flex-start;
|
|
.item-block {
|
width: 100%;
|
height: vww(36);
|
@include flex;
|
justify-content: space-around;
|
|
.item {
|
min-width: vww(50);
|
height: vww(45);
|
font-size: 21rpx;
|
font-weight: 400;
|
color: #ffffff;
|
text-align: center;
|
line-height: vww(30);
|
@include flex;
|
|
.concrete {
|
width: vww(36);
|
height: vww(36);
|
}
|
|
.num {
|
font-size: 40rpx;
|
font-weight: 300;
|
color: #303030;
|
}
|
}
|
}
|
}
|
}
|
}
|
</style>
|