<template>
	<view>
		<view class="cmain">
			<view class="box order_detail" style="margin-top: 0px">
				<view class="item">
					<text class="label">订单状态</text>
					<text class="desc" v-if="item.isDelivery == 1">
						<text class="icon" style="color: #13ce66">&#xe830;</text>
						<text>已完成</text>
					</text>
					<text class="desc" v-else>
						<text class="icon">&#xe830;</text>
						<text>待收货</text>
					</text>
				</view>
			</view>
			<view class="box order_detail">
				<u-divider text="订单信息"></u-divider>
				<view class="item" style="padding-top: 0px">
					<text class="label">订单编号</text>
					<text class="desc">{{ item.orderNo }}</text>
				</view>
				<!-- <view class="item">
					<text class="label">申报单号</text>
					<text class="desc">{{ item.declarationNumber }}</text>
				</view> -->
				<view class="item">
					<text class="label">卖家</text>
					<text class="desc">{{ item.leaderName }}</text>
				</view>
				<view class="item">
					<text class="label">联系号码</text>
					<text class="desc">{{ item.leaderPhone }}</text>
				</view>
				<view class="item">
					<text class="label">商品名称</text>
					<text class="desc">{{ item.goodsName }}</text>
				</view>
				<!-- <view class="item">
					<text class="label">计价单位</text>
					<text class="desc">{{ item.goodsUnit }}</text>
				</view>
				<view class="item">
					<text class="label">商品量</text>
					<text class="desc">{{ item.goodsQuantity }}</text>
				</view> -->
				<view class="item">
					<text class="label">价格</text>
					<text class="desc">￥ {{ item.resalePrice }}</text>
				</view>
				<view class="item">
					<text class="label">车牌号</text>
					<text class="desc">{{ item.veNo }}</text>
				</view>
				<view class="item">
					<text class="label">互市区</text>
					<text class="desc">{{ item.tradeAreaName }}</text>
				</view>
				<view class="item">
					<text class="label">下单时间</text>
					<text class="desc">{{ item.createTime }}</text>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
export default {
	data() {
		return {
			item: {}
		};
	},
	onLoad(e) {
		if (e.id) {
			this.http.request({
				url: '/level-two-server/app/TbOrders/getDetailById',
				data: { ids: e.id },
				success: res => {
					let data = res.data.data;
					this.item = data[0];
				}
			});
		}
	},
	methods: {}
};
</script>

<style lang="scss">
page {
	background-color: $pg;
}
</style>
