<template>
  <view class="flex-col page">
    <view class="flex-col group_4">
      <view class="flex-row section_2">
        <view class="flex-row group_5">
          <text class="text_2">发货单号：</text>
          <text class="text_3">9847583947839743-1</text>
        </view>
        <text class="text_4">评级中</text>
      </view>
      <view class="section_3 flex-col">
        <view class="justify-between" @click="$url('/packages/sonpingDetail/viewDetail')">
          <view class="flex-row">
            <text class="text_5">明细：</text>
            <text class="text_6">共3件</text>
          </view>
          <image
            src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497780150582913.png"
            class="image_6"
          />
        </view>
        <view class="justify-between group_8" @click="$url('/packages/sonpingDetail/expenseDetail')">
          <view class="flex-row">
            <text class="text_7">费用：</text>
            <text class="text_8">暂无</text>
          </view>
          <image
            src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497780230366393.png"
            class="image_6"
          />
        </view>
        <view class="flex-col group_10" @click="$url('/packages/address/address')">
          <view class="justify-between">
            <view class="flex-row lf-flex">
              <view class="text_9">收货人：</view>
              <view class="text_10">李丽丽</view>
              <view class="text_11">15273936409</view>
            </view>
            <image
              src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497780269942998.png"
              class="image_6"
            />
          </view>
          <view class="text_12">北京北京市海淀区钻石大厦C座</view>
        </view>
      </view>
      <view class="section_3 flex-col">
        <view class="flex-col group_13" @click="$url('/packages/sonpingDetail/ratingTrajectory?id='+ id)">
          <view class="flex-row">
            <image
              src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497775960694116.png"
              class="image_10"
            />
            <text class="text_13">收货确认，您的包裹已收到，请耐心等待</text>
            <image
              src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497780327296781.png"
              class="image_6 image_11"
            />
          </view>
          <text class="text_14">2022-03-12 16:46</text>
        </view>
        <view class="flex-row group_15">
          <image
            src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497777959592422.png"
            class="image_12"
          />
          <text class="text_15">温馨提示：如需发票，请在订单完成后一个月内到官网申请</text>
        </view>
      </view>
      <view class="flex-col section_4">
        <text class="text_16">送评信息</text>
        <view class="justify-between group_16" @click="$url('/packages/sonpingDetail/ratingTrajectory?id='+ id)">
          <view class="flex-row">
            <text class="text_17">寄送藏品：</text>
            <text class="text_18">{{ details.order.express_type }}{{ details.order.express_numb }}</text>
          </view>
          <image
            src="https://codefun-proj-user-res-1256085488.cos.ap-guangzhou.myqcloud.com/62677e395a7e3f03107ffc5f/62677e4a35a7e10011e93a80/16509497780290849398.png"
            class="image_6"
          />
        </view>
        <view class="flex-row group_18">
          <text class="text_19">送评公司：</text>
          <text class="text_20">{{ details.order.express_type }}</text>
        </view>
        <view class="flex-row group_19">
          <text class="text_21">送评人：</text>
          <text class="text_22">{{ details.order.owner }}</text>
        </view>
        <view class="flex-row group_20">
          <text class="text_23">联系方式：</text>
          <text class="text_24">{{ details.order.tel }}</text>
        </view>
        <view class="flex-row group_21">
          <text class="text_25">是否快评：</text>
          <text class="text_26">{{ ['否','是'][details.order.is_fast] }}</text>
        </view>
        <view class="flex-row group_22">
          <text class="text_27">保价：</text>
          <text class="text_28">¥？？？？</text>
        </view>
        <view class="flex-col group_23">
          <view class="flex-col">
            <view class="flex-row">
              <text class="text_29">打包照片</text>
              <text class="text_30">送评前请拍照，可确保权益</text>
            </view>
            <view class="flex-row equal-division">
              <image
				mode="aspectFill"
                :src="item"
                class="equal-division-item image_14"
				v-for="(item, index) in showImages"
				:key="index"
				@click="previewImage(index)"
              />
            </view>
          </view>
          <view class="flex-col group_26">
            <view class="flex-col items-center text-wrapper" @click="$url('/packages/address/address?is_select=1')">
              <text>更改地址</text>
            </view>
            <view class="section_5"> </view>
          </view>
        </view>
      </view>
    </view>
  </view>
</template>

<script>
	import { gradingDetail } from '@/service/grading.js'
	
  export default {
    data() {
      return {
		  address: {},
		  id: '',
		  details: {}
	  };
    },
	watch: {
		address(){
			console.log("监听到改变，调取接口。。。。");
		}
	},
	computed: {
		showImages(){
			if(this.details.order && this.details.order.images){
				return this.details.order.images.split(',');
			}else{
				return []
			}
		}
	},
	onLoad(options){
		this.id = options.id;
		this.getGradingDetail();
	},
	methods: {
		async getGradingDetail(){
			let res = await gradingDetail(this.id);
			console.log("res", res);
			this.details = res.data.datas;
		},
		previewImage(current){
			uni.previewImage({
				urls: this.showImages,
				current: current
			})
		}
	}
  };
</script>

<style scoped lang="css">
  .section_3 {
    margin-top: 30rpx;
    padding: 40rpx 30rpx 40rpx 32rpx;
    background-color: rgb(255, 255, 255);
  }
  .image_6 {
    margin: 10rpx 0 8rpx;
    width: 16rpx;
    height: 26rpx;
  }
  .equal-division-item {
    margin-left: 28rpx;
    /* flex: 1 1 210rpx; */
    width: 80px;
    height: 80px;
  }
  .page {
    background-color: #f6f6f6;
    width: 100%;
    overflow-y: auto;
    height: 100%;
  }
  .group_4 {
    padding-top: 2rpx;
    flex: 1 1 auto;
    overflow-y: auto;
  }
  .section_2 {
    padding: 40rpx 32rpx;
    background-color: rgb(255, 255, 255);
  }
  .section_4 {
    margin-top: 30rpx;
    padding: 40rpx 30rpx 16rpx 32rpx;
    background-color: rgb(255, 255, 255);
  }
  .group_5 {
    flex: 1 1 auto;
  }
  .text_4 {
    margin-left: 40rpx;
    color: rgb(172, 205, 35);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .group_8 {
    margin-top: 50rpx;
  }
  .group_10 {
    margin-top: 50rpx;
  }
  .group_13 {
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .group_15 {
    margin-top: 40rpx;
    color: rgb(153, 153, 153);
    font-size: 24rpx;
    font-weight: 500;
    line-height: 34rpx;
    white-space: nowrap;
  }
  .text_16 {
    color: rgb(51, 51, 51);
    font-size: 36rpx;
    font-weight: 600;
    line-height: 50rpx;
    white-space: nowrap;
  }
  .group_16 {
    margin-top: 40rpx;
  }
  .group_18 {
    margin-top: 50rpx;
  }
  .group_19 {
    margin-top: 50rpx;
  }
  .group_20 {
    margin-top: 50rpx;
  }
  .group_21 {
    margin-top: 50rpx;
  }
  .group_22 {
    margin-top: 50rpx;
  }
  .group_23 {
    margin-top: 50rpx;
  }
  .text_2 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_3 {
    margin-left: 10rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_12 {
    margin-top: 10rpx;
    align-self: center;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
	width: 100%;
	box-sizing: border-box;
	padding-left: 160rpx;
	padding-right: 32rpx;
  }
  .text_14 {
    margin-left: 66rpx;
  }
  .image_12 {
    width: 30rpx;
    height: 30rpx;
  }
  .text_15 {
    margin-left: 10rpx;
    margin-right: 24rpx;
  }
  .text_19 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_20 {
    margin-left: 10rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
	overflow:hidden;
	text-overflow:ellipsis;
	width: 522rpx;
	display: inline-block;
  }
  .text_21 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_22 {
    margin-left: 42rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_23 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_24 {
    margin-left: 10rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_25 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_26 {
    margin-left: 10rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_27 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_28 {
    margin-left: 74rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .group_26 {
    margin-top: 40rpx;
    padding: 0 2rpx;
    color: rgb(153, 153, 153);
    font-size: 28rpx;
    font-weight: 500;
    line-height: 40rpx;
    white-space: nowrap;
  }
  .text_5 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_6 {
    margin-left: 74rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_7 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_8 {
    margin-left: 74rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .image_10 {
    width: 56rpx;
    height: 56rpx;
  }
  .text_13 {
    margin-left: 10rpx;
	display: inline-block;
	width: 586rpx;
	white-space:nowrap;
	overflow:hidden;
	text-overflow:ellipsis;
  }
  .image_11 {
    margin-top: 10rpx;
    margin-bottom: 0;
    margin-left: 30rpx;
    margin-right: 0;
  }
  .text_17 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_18 {
    margin-left: 10rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .equal-division {
    margin-top: 20rpx;
  }
  .text-wrapper {
    padding: 10rpx 0;
    align-self: flex-end;
    border-radius: 32rpx;
    width: 160rpx;
    border: solid 2rpx rgb(153, 153, 153);
  }
  .section_5 {
    margin-top: 40rpx;
    align-self: center;
    border-radius: 4rpx;
    width: 196rpx;
    height: 8rpx;
  }
  .text_9 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_10 {
    margin-left: 42rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
	max-width: 280rpx;
	overflow:hidden;
	text-overflow:ellipsis;
  }
  .text_11 {
    margin-left: 30rpx;
    color: rgb(51, 51, 51);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_29 {
    color: rgb(119, 119, 119);
    font-size: 32rpx;
    font-weight: 500;
    line-height: 44rpx;
    white-space: nowrap;
  }
  .text_30 {
    margin-left: 20rpx;
    margin-top: 8rpx;
    color: rgb(153, 153, 153);
    font-size: 24rpx;
    font-weight: 500;
    line-height: 34rpx;
    white-space: nowrap;
  }
  .image_14 {
    margin-left: 0;
  }
</style>