<template>
	<view class="page">
		<pyh-nv ref="nv" :config="nvConfig"></pyh-nv>
		<view class="listBox" :style="{'padding-top':(pageTop+'px')}">
		<view class="content">
			
			<view class="message-list">
			<view class="titleall-box">
				<view class="titleall-left"><view class="titleall-left-line"></view>商品信息</view>
			</view>
			<view class="info-box">
				<view class="goods-list">
					<view class="goods">
						<view class="thumb">
							<image :src="Baseapi + info.orderProductInfoVoList[0].productImage" mode=""></image>
						</view>
						<view class="item">
							<view class="goods-name">
								<view class="goods-name-title">{{info.orderProductInfoVoList[0].productName}}</view>
								<view>下单时间：{{info.funeralUserOrderInfoPo.orderPlacedTime}}</view>
							</view>
							<view class="goods-price">
								<view class="min">¥{{info.orderProductInfoVoList[0].totalPrice / info.orderProductInfoVoList[0].quantityNumber}}</view>
								<view>x{{info.orderProductInfoVoList[0].quantityNumber}}</view>
							</view>
						</view>
					</view>
				</view>
			</view>
			</view>
			
			<view class="message-list">
			<view class="titleall-box">
				<view class="titleall-left"><view class="titleall-left-line"></view>费用信息</view>
			</view>
			<view class="info-box">
				<view class="info-box-list">
					<view class="serve">
						<view class="serve-title" style="font-weight: 500;color: #a8a8a8;">商品总额：</view>
						<view class="serve-right">
							<view class="serve-right-top">¥{{info.orderProductInfoVoList[0].totalPrice}}</view>
						</view>
					</view>
				</view>
				<view class="info-box-list">
					<view class="serve">
						<view class="serve-title">应付款：</view>
						<view class="serve-right">
							<view class="serve-right-top" style="font-weight: bold;color: #3d3d3d;">¥{{info.orderProductInfoVoList[0].totalPrice}}</view>
						</view>
					</view>
				</view>
			</view>
			</view>
			
			<view class="message-list">
			<view class="titleall-box">
				<view class="titleall-left"><view class="titleall-left-line"></view>订单信息</view>
			</view>
			<view class="info-box">
				<view class="info-box-list">
					<view class="serve">
						<view class="serve-title">订单编号：</view>
						<view class="serve-right">
							<view class="serve-right-top">{{info.funeralUserOrderInfoPo.orderId}}</view>
						</view>
					</view>
				</view>
			</view>
			</view>
			
		</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				Baseapi:"http://8.130.38.56:2015",
				OrderType: 0,
				nvConfig:{
					title:"商品订单详情",
					bgColor:"#ffffff",
					color:"#000000",
					fixedAssist:{
						hide:true,
					},
				},
				info:{}
			};
		},
		onPageScroll(e) {this.$refs.nv.pageScroll(e)},
		computed:{
			pageTop(){return parseInt(88*uni.getSystemInfoSync().windowWidth/750) + uni.getSystemInfoSync().statusBarHeight}
		},
		onLoad(params) {
			this.info = JSON.parse(params.info)
			console.log(this.info);
		},
		methods:{
			/**
			 * 返回点击
			 */
			onBack(){
				uni.navigateBack();
			},
			/**
			 * 订单tab点击
			 */
			onOrderTab(type){
				this.OrderType = type;
				// #ifdef H5
				uni.redirectTo({
					url: '/pages/MyOrderList/MyOrderList?type=' + type,
				})
				//#endif
			},
			/**
			 * 订单列表点击
			 */
			onOrderList(){
				uni.navigateTo({
					url: '/pages/OrderDetails/OrderDetails',
				})
			},
      /**
       * 评价点击
       */
      onEvaluate(){
			  uni.navigateTo({
          url: '/pages/MyEvaluatePush/MyEvaluatePush'
        })
      }
		}
	}
</script>

<style scoped lang="scss">
	@import 'myorderdetail.scss';
</style>
