58 lines
1.5 KiB
Vue
58 lines
1.5 KiB
Vue
<template>
|
|
<uni-card
|
|
v-for="(item,index) in items"
|
|
:key="item.saleid"
|
|
:class="index % 2 === 0 ? 'card-even' : 'card-odd'"
|
|
:extra="item.contractcode"
|
|
:title="item.usernames"
|
|
>
|
|
<view class="context">
|
|
<view class="label">
|
|
<text>状态:</text>
|
|
<text>{{ item.stateText }}</text>
|
|
</view>
|
|
<view class="label">
|
|
<text>制单日期:</text>
|
|
<text>{{ formatDate(item.adddate) }}</text>
|
|
</view>
|
|
<view class="label">
|
|
<text>订单金额:</text>
|
|
<text>{{ item.contractmoney.toFixed(2) }}</text>
|
|
</view>
|
|
<view class="label">
|
|
<text>区域:</text>
|
|
<text>{{ item.areaName }}</text>
|
|
</view>
|
|
</view>
|
|
|
|
</uni-card>
|
|
</template>
|
|
|
|
<script setup>
|
|
import {defineOptions, defineProps} from 'vue'
|
|
import UniCard from "../../../uni_modules/uni-card/components/uni-card/uni-card.vue";
|
|
import {formatDate} from "../../../uni_modules/uni-dateformat/components/uni-dateformat/date-format";
|
|
|
|
defineOptions({
|
|
name: 'ListItem'
|
|
})
|
|
|
|
const props = defineProps(['items'])
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
.context {
|
|
display: grid;
|
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
gap: 10px;
|
|
font-size: 12px;
|
|
line-height: 20px;
|
|
|
|
.label {
|
|
display: flex;
|
|
gap: 6px;
|
|
font-size: 12px;
|
|
line-height: 20px;
|
|
}
|
|
}
|
|
</style> |