index.vue 2.69 KB
Newer Older
Marcus's avatar
Marcus committed
1 2 3
<template>
  <div>
    <el-descriptions border v-if="order.orderId">
Marcus's avatar
Marcus committed
4 5 6 7
      <el-descriptions-item :label="$t('唛头')">{{ order.marks }}</el-descriptions-item>
      <el-descriptions-item :label="$t('已到箱数/总箱数')">{{ order.sumNum }}/{{ order.costVO.totalNum }}</el-descriptions-item>
      <el-descriptions-item :label="$t('订单状态')"><dict-tag :type="DICT_TYPE.ORDER_STATUS" :value="order.status" :class="{red: order.status === 1, green: order.status === 5 || order.status === 2}" /></el-descriptions-item>
      <el-descriptions-item :label="$t('运输方式')">
Marcus's avatar
Marcus committed
8 9
        <dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="order.logisticsInfoDto.transportId"></dict-tag>
      </el-descriptions-item>
Marcus's avatar
Marcus committed
10 11 12 13 14 15 16 17 18 19 20
      <el-descriptions-item :label="$t('始发地')">{{ order.logisticsInfoDto.startTitleZh || '' }}<span v-if="order.isExternalWarehouse" style="color: red">{{ $t('(外部仓)') }}</span></el-descriptions-item>
      <el-descriptions-item :label="$t('目的地')">{{ order.logisticsInfoDto.destTitleZh || '' }}</el-descriptions-item>
      <el-descriptions-item :label="$t('发货人姓名')">{{ order.consignorVO && order.consignorVO.name || ''}}</el-descriptions-item>
      <el-descriptions-item :label="$t('发货人公司')">{{ order.consignorVO && order.consignorVO.company || '' }}</el-descriptions-item>
      <el-descriptions-item :label="$t('发货人电话')">{{ order.consignorVO && (order.consignorVO.countryCode + order.consignorVO.phone) || '' }}</el-descriptions-item>
      <el-descriptions-item :label="$t('收货人姓名')">{{ order.consigneeVO && order.consigneeVO.name || ''}}</el-descriptions-item>
      <el-descriptions-item :label="$t('收货人公司')">{{ order.consigneeVO && order.consigneeVO.company || '' }}</el-descriptions-item>
      <el-descriptions-item :label="$t('收货人电话')">{{ order.consigneeVO &&(order.consigneeVO.countryCode + order.consigneeVO.phone) || '' }}</el-descriptions-item>
      <el-descriptions-item :label="$t('送货时间')">{{ order.deliveryDate || '' }}</el-descriptions-item>
      <el-descriptions-item :label="$t('入仓类型')">{{ getDictDataLabel(DICT_TYPE.ECW_WAREHOUSING_TYPE, order.warehouseType) }}</el-descriptions-item>
      <el-descriptions-item :label="$t('订单号')">{{ order.orderNo }}</el-descriptions-item>
Marcus's avatar
Marcus committed
21 22 23 24 25
    </el-descriptions>
  </div>
</template>

<script>
Marcus's avatar
Marcus committed
26
import {DICT_TYPE, getDictDataLabel} from "@/utils/dict"
Marcus's avatar
Marcus committed
27

Marcus's avatar
Marcus committed
28 29
export default {
  name: "orderBaseInfo",
Marcus's avatar
Marcus committed
30

Marcus's avatar
Marcus committed
31 32
  props: {
    order: Object
Marcus's avatar
Marcus committed
33 34 35 36
  },

  data () {
    return {
Marcus's avatar
Marcus committed
37 38
      DICT_TYPE,
      getDictDataLabel
Marcus's avatar
Marcus committed
39
    }
Marcus's avatar
Marcus committed
40 41 42 43
  }
}
</script>

Marcus's avatar
Marcus committed
44 45 46 47 48 49 50 51
<style scoped lang="scss">
@import "src/assets/styles/element-variables";
.red{
  color: $--color-danger;
}
.green{
  color: $--color-success;
}
Marcus's avatar
Marcus committed
52
</style>