Commit 4061ceb8 authored by zs嵩's avatar zs嵩

客户反馈问题处理

parent 4ab7754d
......@@ -22,7 +22,7 @@
</el-col>
<el-col :span="12">
<el-form-item :label="$t('跟进类型')" required>
<el-select v-model="form.followType" clearable :placeholder="$t('请选择')" @change="handleFollowType" :disabled="isView">
<el-select v-model="form.followType" clearable :placeholder="$t('请选择')" @change="handleFollowType" :disabled="isView || !!offerId">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_FOLLOWUP_TYPE)" :key="dict.value" :label="isChinese ? dict.label : dict.labelEn" :value="parseInt(dict.value)" />
</el-select>
</el-form-item>
......@@ -106,7 +106,7 @@
<el-col :span="20" v-if="isView">
<el-form-item>
<div style="text-align: right">
<!-- <el-button size="mini" icon="el-icon-collection" type="primary" @click="$emit('handleCustomerFollowAdd', form)" v-has-permi="['ecw:customer:follow-add-plan']">{{ $t("增加计划") }} </el-button>-->
<!-- <el-button size="mini" icon="el-icon-collection" type="primary" @click="$emit('handleCustomerFollowAdd', form)" v-has-permi="['ecw:customer:follow-add-plan']">{{ $t("增加计划") }} </el-button>-->
<el-button size="mini" type="text" icon="el-icon-collection" @click="handleUpdate(form, true)" v-has-permi="['ecw:customer:follow-add-plan']">{{ $t("增加计划") }} </el-button>
</div>
</el-form-item>
......@@ -185,6 +185,7 @@ export default {
/**
* 如果是客户投诉跟进,则id为客户投诉id;如果是客户跟进,则id为客户id
*/
offerId: Number,
customerId: Number,
customerNumber: String,
customerService: Number
......@@ -208,7 +209,7 @@ export default {
customerFollow: {
dialogVisible: false,
form: {
followType: "3"
followType: 3
}
},
offerDialogVisible: true,
......@@ -315,7 +316,7 @@ export default {
},
handleFollowType(val) {
console.log(val)
if (val == "2") {
if (val == 2) {
this.CustomerFollowSelectOffer = true
} else {
this.form.offerId = undefined
......@@ -332,7 +333,7 @@ export default {
feedback: undefined,
followMethod: undefined,
followTime: new Date().getTime(),
followType: undefined,
followType: this.offerId ? 2 : undefined,
followUserId: this.customerService,
nextPlan: undefined,
nextTime: undefined,
......@@ -423,6 +424,7 @@ export default {
},
customerFollowClose() {
this.customerFollow.dialogVisible = false
this.$emit("close")
},
handleView(row) {
this.form = row
......
......@@ -33,6 +33,7 @@
<el-descriptions-item :label="$t('客户状态')">
{{ getDictDataLabel(DICT_TYPE.CUSTOMER_STATUS, customer.status) }}
</el-descriptions-item>
<el-descriptions-item :label="$t('客户经理')">{{ customer.customerServiceName }}</el-descriptions-item>
<el-descriptions-item :label="$t('询盘信息')">{{ customer.inquiry }}</el-descriptions-item>
<el-descriptions-item :label="$t('备注')">{{ customer.remarks }}</el-descriptions-item>
<el-descriptions-item :label="$t('图片')">
......@@ -46,7 +47,7 @@
</el-descriptions-item>
<el-descriptions-item :label="$t('推介人')">{{ customer.promoterName }}</el-descriptions-item>
<el-descriptions-item :label="$t('客户生日')">{{ parseTime(customer.birthday, "{y}-{m}-{d}") }} </el-descriptions-item>
<el-descriptions-item :label="$t('客户经理')">{{ customer.customerServiceName }}</el-descriptions-item>
<el-descriptions-item :label="$t('业绩类型')">{{ customer.isNew ? $t("新客户") : $t("老客户") }} </el-descriptions-item>
<el-descriptions-item :label="$t('资源类型')">
<dict-tag :type="DICT_TYPE.ECW_CUSTOMER_RESOURCE_TYPE" :value="customer.resourceType"></dict-tag>
</el-descriptions-item>
......@@ -70,7 +71,6 @@
<el-descriptions-item :label="$t('创建时间')">{{ parseTime(customer.createTime) }}</el-descriptions-item>
<el-descriptions-item :label="$t('最后更新人')">{{ customer.updaterName }}</el-descriptions-item>
<el-descriptions-item :label="$t('最后更新时间')">{{ customer.updateTime }}</el-descriptions-item>
<el-descriptions-item :label="$t('业绩类型')">{{ customer.isNew ? $t("新客户") : $t("老客户") }} </el-descriptions-item>
</template>
</el-descriptions>
</el-card>
......@@ -496,7 +496,13 @@
<el-descriptions-item :label="$t('业务国家')">
{{ isChinese ? customer.busiCountryNameZh : customer.busiCountryNameEn }}
</el-descriptions-item>
<el-descriptions-item :label="$t('主营类别')">{{ $l(customer, "productTypeName") }}</el-descriptions-item>
<el-descriptions-item :label="$t('主营类别')">
<div>
<div v-for="(item, index) in productTypeName" :key="index">
<b>{{ $l(item, "title") }}:</b><span>{{ item.productList || "-" }}</span>
</div>
</div>
</el-descriptions-item>
<el-descriptions-item :label="$t('年度发货量')">{{ customer.weightYearly }}</el-descriptions-item>
<el-descriptions-item :label="$t('主要竞争对手')">{{ customer.competitorNames }}</el-descriptions-item>
<el-descriptions-item :label="$t('年度发货次数')">{{ customer.numYearly }}</el-descriptions-item>
......@@ -671,21 +677,7 @@
</template>
<script>
import {
getCustomer,
getCustomerSelect,
getBrankByCustomer,
levelLogPage,
customerCreditLogPage,
infoListOrderPage,
orderStatistics,
creditLogCreate,
creditScoreStatistic,
infoListReceiptPage,
memberUserList,
deleteCustomer,
infoListStatisticsOrder
} from "@/api/ecw/customer"
import { getCustomer, getCustomerSelect, getBrankByCustomer, levelLogPage, customerCreditLogPage, infoListOrderPage, orderStatistics, creditLogCreate, creditScoreStatistic, infoListReceiptPage, memberUserList, deleteCustomer, infoListStatisticsOrder } from "@/api/ecw/customer"
import { getOfferPage as infoListOfferPage } from "@/api/ecw/offer"
import { DICT_TYPE, getDictDataLabel, getDictDatas2 } from "@/utils/dict"
import { getProductTypeList } from "@/api/ecw/productType"
......@@ -929,7 +921,8 @@ export default {
remarks: undefined,
arrivalConfirm: undefined,
weightUnit: undefined,
createTime: undefined
createTime: undefined,
productTypeList: []
},
brandAuthorizationFrom: {
pageNo: 1,
......@@ -993,6 +986,17 @@ export default {
}
},
computed: {
productTypeName() {
return this.customer.productTypeList.map((item) => {
return {
...item,
productList: this.customer.productList
.filter((i) => i.typeId === item.id)
.map((i) => this.$l(i, "title"))
.join("")
}
})
},
exportCityList() {
return this.tradeCityList.filter((item) => item.type == 2)
},
......
......@@ -17,7 +17,7 @@
<div class="title-font">
<label>{{ $t("报价单所属") }}{{ list.relation ? (list.relation == 1 ? $t("发货人") : $t("收货人")) : $t("发货人") }}</label>
</div>
<el-descriptions :column="3" border class="card" v-if="list.consignorId">
<el-descriptions :column="3" border class="card" v-if="list.consignorId" :labelStyle="{ width: '110px' }">
<el-descriptions-item :label="$t('发货人') + ':'">
{{ consignorData.contactsName || $t("") }}
</el-descriptions-item>
......@@ -39,7 +39,7 @@
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="3" border class="card" v-if="list.consigneeId">
<el-descriptions :column="3" border class="card" v-if="list.consigneeId" :labelStyle="{ width: '110px' }">
<el-descriptions-item :label="$t('收货人') + ':'">
{{ consigneeData.contactsName || $t("") }}
</el-descriptions-item>
......@@ -60,50 +60,39 @@
{{ consigneeData.socialNumber ? "(" + consigneeData.socialNumber + ")" : "" }}
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4" class="card">
</div>
</el-card>
<el-card class="card">
<div slot="header" class="card-title">{{ $t("运输") }}</div>
<div style="overflow: auto">
<el-descriptions :column="5" border class="card" v-if="list.consignorId" :labelStyle="{ width: '110px' }">
<el-descriptions-item :label="$t('始发仓')">{{ $l(list.logisticsInfoDto, "startTitle") }}</el-descriptions-item>
<el-descriptions-item :label="$t('目的仓')"> {{ $l(list.logisticsInfoDto, "destCountryTitle") }} - {{ $l(list.logisticsInfoDto, "destCityTitle") }} - {{ $l(list.logisticsInfoDto, "destTitle") }} </el-descriptions-item>
<el-descriptions-item :label="$t('运输方式')">
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="list.transportId" />
</el-descriptions-item>
<el-descriptions-item :label="$t('出货渠道')" v-if="[3, 4].indexOf(list.transportId) > -1">
{{ channelName }}
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4" class="card">
<el-descriptions-item :label="$t('始发城市')">
{{ getCity(list.departureId) }}
</el-descriptions-item>
<el-descriptions-item :label="$t('目的城市')">
{{ getCity(list.objectiveId) }}
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4" class="card">
<el-descriptions-item :label="$t('线路')">
{{ getRouterNameById(list.lineId) }}
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4" class="card">
<el-descriptions-item :label="$t('报价单状态')">
<dict-tag :type="DICT_TYPE.ECW_OFFER_STATUS" :value="list.status" />
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4" class="card" v-if="list.status == 5">
<el-descriptions-item :label="$t('输单原因')">
{{ list.reason }}
<el-descriptions-item v-if="getDictData(DICT_TYPE.ECW_TRANSPORT_TYPE, list.transportId).cssClass == 'channel'" :label="$t('出货渠道')">{{ list.channelName }}</el-descriptions-item>
<el-descriptions-item :label="$t('服务')">
<el-tag v-if="list.type && list.type.indexOf('1') > -1">
{{ $t("集运") }}
</el-tag>
<el-tag v-if="list.type && list.type.indexOf('2') > -1">
{{ $t("海外仓") }}
</el-tag>
</el-descriptions-item>
</el-descriptions>
</div>
</el-card>
<el-card class="card">
<div slot="header" class="card-title">{{ $t("商品信息") }}</div>
<div slot="header" class="card-title">{{ $t("商品") }}</div>
<div style="overflow: auto">
<el-table v-loading="loading" border :data="list.offerProdRespVOList">
<el-table v-loading="loading" border show-summary :data="list.offerProdRespVOList">
<el-table-column :label="$t('序号')" width="60px" fixed>
<template slot-scope="scope">
{{ scope.$index + 1 }}
</template>
</el-table-column>
<!-- <el-table-column :label="商品类型" align="center" prop="goodsType" /> -->
<el-table-column :label="$t('中文品名')" align="center" prop="prodTitleZh" />
<el-table-column :label="$t('英文品名')" align="center" prop="prodTitleEn" />
<el-table-column :label="$t('品牌')" width="100px">
......@@ -146,36 +135,9 @@
</el-table>
</div>
</el-card>
<el-card class="card">
<div slot="header" class="card-title">{{ $t("费用小计") }}</div>
<el-descriptions border class="card" :column="5">
<el-descriptions-item :label="$t('总件数') + ':'">
{{ list.estCostVO ? list.estCostVO.totalNum || "0" : 0 }}
</el-descriptions-item>
<el-descriptions-item :label="$t('总体积') + ':'">
{{ list.estCostVO ? list.estCostVO.totalVolume + "m³" || "0" : 0 }}
</el-descriptions-item>
<el-descriptions-item :label="$t('总重量') + ':'">
{{ list.estCostVO ? list.estCostVO.totalWeight + "kg" || "0" : 0 }}
</el-descriptions-item>
<el-descriptions-item :label="$t('总数量') + ':'">
{{ list.estCostVO ? list.estCostVO.totalQuantity || "0" : 0 }}
</el-descriptions-item>
<el-descriptions-item :label="$t('总货值(RMB)') + ':'">
{{ list.estCostVO ? list.estCostVO.totalWorth || "0" : 0 }}
</el-descriptions-item>
<!-- <el-descriptions-item :label="报价费:">
{{list.estCostVO?list.estCostVO.insuranceFee||'0':0}}
</el-descriptions-item> -->
</el-descriptions>
<!-- <el-descriptions border class="card">
<el-descriptions-item :label="佣金类型" :span="2" class="card">
<dict-selector :type="DICT_TYPE.COMMISSION_TYPE" form-type="radio" fomtter="number" :value="list.commissionType" defaultable />
</el-descriptions-item>
</el-descriptions> -->
</el-card>
<el-card class="mt-10">
<div class="card-title" slot="header">{{ $t("预计费用") }}</div>
<div class="card-title" slot="header">{{ $t("费用") }}</div>
<el-descriptions :column="5" border>
<el-descriptions-item :label="$t('保价费')"> {{ list.estCostVO ? list.estCostVO.insuranceFee : 0 }} {{ selectedRouter ? currentcyMap[selectedRouter.currencyUnit || 1] : "" }} </el-descriptions-item>
......@@ -356,7 +318,7 @@
</template>
<script>
import { DICT_TYPE, getDictDatas } from "@/utils/dict"
import { DICT_TYPE, getDictDatas, getDictData } from "@/utils/dict"
import { getOffer, deleteOffer } from "@/api/ecw/offer"
import { getProductAttrList } from "@/api/ecw/productAttr"
import { getCustomerList, getCustomer } from "@/api/ecw/customer"
......@@ -408,6 +370,9 @@ export default {
}
},
computed: {
getDictData() {
return (type, value) => getDictData(type, value) || {}
},
// 根据id获取商品名称(显示优惠列表的时候用)
getProductName() {
return (prodId) => {
......
......@@ -52,7 +52,6 @@
</el-select>
</el-form-item>
<el-form-item :label="$t('运输方式')" prop="transportId" v-show="showSearch">
<dict-selector :type="DICT_TYPE.ECW_TRANSPORT_TYPE" v-model="queryParams.transportId" multiple formatter="number" clearable @change="handleQuery" />
</el-form-item>
......@@ -193,7 +192,7 @@
</el-table>
<!-- 分页组件 -->
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize" @pagination="getList" />
<CustomerFollow ref="customerFollow" @refresh="handleQuery" v-if="customerFollowVisible" :customer-id="curData.relationId" :customerService="curData.salesmanId" :customerNumber="curData.customerNumber" :offerId="curData.offerId" />
<CustomerFollow ref="customerFollow" @refresh="handleQuery" v-if="customerFollowVisible" @close="customerFollowVisible = false" :customer-id="curData.relationId" :customerService="curData.salesmanId" :customerNumber="curData.customerNumber" :offerId="curData.offerId" />
</div>
</template>
......
......@@ -2,118 +2,97 @@
<div class="app-container" v-if="order">
<el-card class="card">
<div slot="header" class="card-title">
{{$t('订单编号')}}{{order.orderNo}}
<template v-if="order.tidanNo"> - {{order.tidanNo}}</template>
<template v-else-if="order.containerNumber"> - {{order.containerNumber}}</template>
{{ $t("订单编号") }}{{ order.orderNo }}
<template v-if="order.tidanNo"> - {{ order.tidanNo }}</template>
<template v-else-if="order.containerNumber"> - {{ order.containerNumber }}</template>
</div>
<el-row :gutter="24">
<el-col :span="12" v-if="order.consignorVO" >
<el-descriptions class="margin-top" border :title="$t('发货人')" :column="3" :labelStyle="{width:'110px'}" :contentStyle="{width:'150px'}">
<el-col :span="12" v-if="order.consignorVO">
<el-descriptions class="margin-top" border :title="$t('发货人')" :column="3" :labelStyle="{ width: '110px' }" :contentStyle="{ width: '150px' }">
<el-descriptions-item :label="$t('中文名称')">
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consignorVO.customerId}`">{{order.consignorVO.name}}</component>
</el-descriptions-item>
<el-descriptions-item :label="$t('电话')">
+{{order.consignorVO.countryCode}} {{order.consignorVO.phone}}
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consignorVO.customerId}`">{{ order.consignorVO.name }}</component>
</el-descriptions-item>
<el-descriptions-item :label="$t('电话')"> +{{ order.consignorVO.countryCode }} {{ order.consignorVO.phone }} </el-descriptions-item>
</el-descriptions>
<el-descriptions border :class="showMore?'showInfo':'hiddenInfo'" :column="3" :labelStyle="{width:'110px'}" :contentStyle="{width:'150px'}">
<el-descriptions border :class="showMore ? 'showInfo' : 'hiddenInfo'" :column="3" :labelStyle="{ width: '110px' }" :contentStyle="{ width: '150px' }">
<el-descriptions-item :label="$t('英文名称')">
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consignorVO.customerId}`">
{{order.consignorVO.nameEn}}
{{ order.consignorVO.nameEn }}
</component>
</el-descriptions-item>
<el-descriptions-item :label="$t('公司中文名称')">
{{order.consignorVO.company}}
{{ order.consignorVO.company }}
</el-descriptions-item>
<!-- v1.7新增 -->
<el-descriptions-item :label="$t('公司英文名称')">
{{order.consignorVO.companyEn}}
{{ order.consignorVO.companyEn }}
</el-descriptions-item>
<el-descriptions-item :label="$t('邮箱')">{{order.consignorVO.email}}</el-descriptions-item>
<el-descriptions-item :label="$t('邮箱')">{{ order.consignorVO.email }}</el-descriptions-item>
</el-descriptions>
</el-col>
<el-col :span="12" style="position: relative;">
<span style="color:#409EFF;position: absolute;right:40px;top:0;font-size:16px;cursor: pointer;" @click="consigneeChange">{{consigneeText}}</span>
<el-descriptions v-if="order.consigneeVO" class="margin-top" border :title="$t('收货人')" :column="3" :labelStyle="{width:'110px'}" :contentStyle="{width:'150px'}">
<el-col :span="12" style="position: relative">
<span style="color: #409eff; position: absolute; right: 40px; top: 0; font-size: 16px; cursor: pointer" @click="consigneeChange">{{ consigneeText }}</span>
<el-descriptions v-if="order.consigneeVO" class="margin-top" border :title="$t('收货人')" :column="3" :labelStyle="{ width: '110px' }" :contentStyle="{ width: '150px' }">
<el-descriptions-item :label="$t('中文名称')">
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consigneeVO.customerId}`">{{order.consigneeVO.name}}</component>
</el-descriptions-item>
<el-descriptions-item :label="$t('电话')">
+{{order.consigneeVO.countryCode}} {{order.consigneeVO.phone}}
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consigneeVO.customerId}`">{{ order.consigneeVO.name }}</component>
</el-descriptions-item>
<el-descriptions-item :label="$t('电话')"> +{{ order.consigneeVO.countryCode }} {{ order.consigneeVO.phone }} </el-descriptions-item>
<el-descriptions-item :label="$t('收货方式')">
<dict-tag :type="DICT_TYPE.ECW_HARVEST_METHOD" :value="order.consigneeVO.harvestMethod" />
</el-descriptions-item>
<el-descriptions-item :label="$t('收货地区')">
{{region}}
{{ region }}
</el-descriptions-item>
<el-descriptions-item :label="$t('收货地址')">
{{order.consigneeVO.address}}
{{ order.consigneeVO.address }}
</el-descriptions-item>
</el-descriptions>
<el-descriptions v-if="order.consigneeVO && showMore" border :column="3" :labelStyle="{width:'110px'}" :contentStyle="{width:'150px'}">
<el-descriptions v-if="order.consigneeVO && showMore" border :column="3" :labelStyle="{ width: '110px' }" :contentStyle="{ width: '150px' }">
<el-descriptions-item :label="$t('英文名称')">
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consigneeVO.customerId}`">{{order.consigneeVO.nameEn}}</component>
<component :is="hasCustomerDetailPermi ? 'router-link' : 'span'" :to="`/customer/query/${order.consigneeVO.customerId}`">{{ order.consigneeVO.nameEn }}</component>
</el-descriptions-item>
<el-descriptions-item :label="$t('公司中文名称')">
{{ order.consigneeVO.company }}
</el-descriptions-item>
<el-descriptions-item :label="$t('公司中文名称')">
{{order.consigneeVO.company}}
</el-descriptions-item>
<!-- v1.7新增 -->
<el-descriptions-item :label="$t('公司英文名称')">
{{order.consigneeVO.companyEn}}
</el-descriptions-item>
<el-descriptions-item :label="$t('邮箱')">{{order.consigneeVO.email}}</el-descriptions-item>
<!-- v1.7新增 -->
<el-descriptions-item :label="$t('公司英文名称')">
{{ order.consigneeVO.companyEn }}
</el-descriptions-item>
<el-descriptions-item :label="$t('邮箱')">{{ order.consigneeVO.email }}</el-descriptions-item>
</el-descriptions>
</el-col>
</el-row>
</el-card>
<el-card class="card">
<el-descriptions border :title="$t('运输')" :column="5" :labelStyle="{width:'110px'}" :contentStyle="{width:'150px'}">
<el-descriptions-item :label="$t('始发仓')">{{$l(order.initialLogisticsInfoDto, 'startTitle')}}</el-descriptions-item>
<el-descriptions border :title="$t('运输')" :column="5" :labelStyle="{ width: '110px' }" :contentStyle="{ width: '150px' }">
<el-descriptions-item :label="$t('始发仓')">{{ $l(order.initialLogisticsInfoDto, "startTitle") }}</el-descriptions-item>
<el-descriptions-item :label="$t('目的仓')">
{{$l(order.initialLogisticsInfoDto, 'destCountryTitle')}} -
{{$l(order.initialLogisticsInfoDto, 'destCityTitle')}} -
{{$l(order.initialLogisticsInfoDto, 'destTitle')}}
{{ $l(order.initialLogisticsInfoDto, "destCountryTitle") }} - {{ $l(order.initialLogisticsInfoDto, "destCityTitle") }} -
{{ $l(order.initialLogisticsInfoDto, "destTitle") }}
</el-descriptions-item>
<!-- <el-descriptions-item :label="$t('地址')" :span="2">{{order.logisticsInfoDto.startAddressZh}}</el-descriptions-item> -->
<el-descriptions-item :label="$t('运输方式')" >
<el-descriptions-item :label="$t('运输方式')">
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="order.transportId" />
</el-descriptions-item>
<el-descriptions-item v-if="getDictData(DICT_TYPE.ECW_TRANSPORT_TYPE, order.transportId).cssClass == 'channel'":label="$t('出货渠道')" >{{order.channelName}}</el-descriptions-item>
<el-descriptions-item :label="$t('服务')" >
<el-descriptions-item v-if="getDictData(DICT_TYPE.ECW_TRANSPORT_TYPE, order.transportId).cssClass == 'channel'" :label="$t('出货渠道')">{{ order.channelName }}</el-descriptions-item>
<el-descriptions-item :label="$t('服务')">
<el-tag v-if="order.type && order.type.indexOf('1') > -1">
{{ $t('集运') }}
{{ $t("集运") }}
</el-tag>
<el-tag v-if="order.type && order.type.indexOf('2') > -1">
{{ $t('海外仓') }}
{{ $t("海外仓") }}
</el-tag>
</el-descriptions-item>
</el-descriptions>
</el-card>
<el-card class="card">
<el-descriptions class="mr-10" border :title="$t('基础')" :column="2" :labelStyle="{width:'110px'}" :contentStyle="{width:'150px'}">
<el-descriptions-item :label="$t('唛头')">{{order.marks}}</el-descriptions-item>
<el-descriptions-item :label="$t('填单信息')">
{{order.costVO.totalNum}}{{$t('箱')}}
{{order.costVO.totalWeight}}Kg
{{order.costVO.totalVolume}}m³
{{order.costVO.totalQuantity}}{{$t('个')}}
</el-descriptions-item>
<el-descriptions-item :label="$t('仓库实测')">
{{order.sumNum}}{{$t('箱')}}
{{order.sumWeight}}Kg
{{order.sumVolume}}m³
{{order.sumQuantity}}{{$t('个')}}
</el-descriptions-item>
<el-descriptions-item :label="$t('收款数据')">
{{order.sumNum}}{{$t('箱')}}
{{order.vweight}}Kg
{{order.wvolume}}m³
{{order.sumQuantity}}{{$t('个')}}
</el-descriptions-item>
<el-descriptions class="mr-10" border :title="$t('基础')" :column="2" :labelStyle="{ width: '110px' }" :contentStyle="{ width: '150px' }">
<el-descriptions-item :label="$t('唛头')">{{ order.marks }}</el-descriptions-item>
<el-descriptions-item :label="$t('填单信息')"> {{ order.costVO.totalNum }}{{ $t("箱") }} {{ order.costVO.totalWeight }}Kg {{ order.costVO.totalVolume }}m³ {{ order.costVO.totalQuantity }}{{ $t("个") }} </el-descriptions-item>
<el-descriptions-item :label="$t('仓库实测')"> {{ order.sumNum }}{{ $t("箱") }} {{ order.sumWeight }}Kg {{ order.sumVolume }}m³ {{ order.sumQuantity }}{{ $t("个") }} </el-descriptions-item>
<el-descriptions-item :label="$t('收款数据')"> {{ order.sumNum }}{{ $t("箱") }} {{ order.vweight }}Kg {{ order.wvolume }}m³ {{ order.sumQuantity }}{{ $t("个") }} </el-descriptions-item>
<el-descriptions-item :label="$t('付款人')">
<el-link v-if="order.drawee == 3" @click.native="showDarweeDialog=true" type="primary">{{ $t('自定义') }}</el-link>
<el-link v-if="order.drawee == 3" @click.native="showDarweeDialog = true" type="primary">{{ $t("自定义") }}</el-link>
<dict-tag v-else :type="DICT_TYPE.DRAWEE" :value="order.drawee"></dict-tag>
</el-descriptions-item>
......@@ -121,38 +100,31 @@
<dict-tag :type="DICT_TYPE.ECW_CUSTOMS_TYPE" :value="order.customsType" />
</el-descriptions-item>
<el-descriptions-item :label="$t('目的港清关')" v-if="isAir">
{{['', $t('我司承接'), $t('客户自清')][order.portDestCustomsClear] || ''}}
{{ ["", $t("我司承接"), $t("客户自清")][order.portDestCustomsClear] || "" }}
</el-descriptions-item>
<el-descriptions-item :label="$t('发货方式')" v-if="isAir">
{{['', $t('多票'), $t('单票')][order.deliveryWay] || ''}}
{{ ["", $t("多票"), $t("单票")][order.deliveryWay] || "" }}
</el-descriptions-item>
<el-descriptions-item :label="$t('是否控货')">
<dict-tag :type="DICT_TYPE.INFRA_BOOLEAN_STRING" :value="order.isCargoControl" />
</el-descriptions-item>
<el-descriptions-item :label="$t('关联报价单')">
<router-link v-if="offerData" :to="{path: '/offer/detail',query: {offerId: offerData.offerId}}" class="link-type">
<router-link v-if="offerData" :to="{ path: '/offer/detail', query: { offerId: offerData.offerId } }" class="link-type">
<span>{{ offerData.number }}</span>
</router-link>
<span v-else>/</span>
</el-descriptions-item>
<el-descriptions-item :label="$t('特殊要求')">
<template v-if="order.packageType">
<dict-tag v-for="packageType in order.packageType.split(',').filter(item => !!item)" class="mr-10" :key="packageType" :type="DICT_TYPE.ORDER_SPECIAL_NEEDS" :value="packageType" />
<dict-tag v-for="packageType in order.packageType.split(',').filter((item) => !!item)" class="mr-10" :key="packageType" :type="DICT_TYPE.ORDER_SPECIAL_NEEDS" :value="packageType" />
</template>
</el-descriptions-item>
<el-descriptions-item :label="$t('特殊要求备注')">
{{order.packageRemarks}}
</el-descriptions-item>
<el-descriptions-item :label="$t('到仓数据')">
{{order.checkNum}}{{$t('箱')}}
{{order.checkWeight}}Kg
{{order.checkVolume}}m³
{{order.checkQuantity}}{{$t('个')}}
</el-descriptions-item>
<el-descriptions-item :label="$t('提货数据')">
{{order.pickNum}} {{$t('箱')}} {{order.pickRatio}}%
{{ order.packageRemarks }}
</el-descriptions-item>
<el-descriptions-item :label="$t('送货时间')" v-if="!order.isExternalWarehouse">{{order.deliveryDate}}</el-descriptions-item>
<el-descriptions-item :label="$t('到仓数据')"> {{ order.checkNum }}{{ $t("箱") }} {{ order.checkWeight }}Kg {{ order.checkVolume }}m³ {{ order.checkQuantity }}{{ $t("个") }} </el-descriptions-item>
<el-descriptions-item :label="$t('提货数据')"> {{ order.pickNum }} {{ $t("箱") }} {{ order.pickRatio }}% </el-descriptions-item>
<el-descriptions-item :label="$t('送货时间')" v-if="!order.isExternalWarehouse">{{ order.deliveryDate }}</el-descriptions-item>
<el-descriptions-item :label="$t('入仓类型')">
<dict-tag :type="DICT_TYPE.ECW_WAREHOUSING_TYPE" :value="order.warehouseType" />
......@@ -161,46 +133,41 @@
<!--海运隐藏下面字段-->
<template v-if="order.transportId != 1 && order.transportId != 2">
<el-descriptions-item :label="$t('清关证书')">
{{order.isSingleTicketTransport? this.$t(''):this.$t('')}}
{{ order.isSingleTicketTransport ? this.$t("") : this.$t("") }}
</el-descriptions-item>
<el-descriptions-item :label="$t('清关证书备注')">
{{ order.customsClearCertRemarks }}
</el-descriptions-item>
<el-descriptions-item :label="$t('是否拆包')">
{{order.isUnpack? this.$t(''):this.$t('')}}
{{ order.isUnpack ? this.$t("") : this.$t("") }}
</el-descriptions-item>
<el-descriptions-item :label="$t('单票立刻转运')">
{{order.isSingleTicketTransport? this.$t(''):this.$t('')}}
{{ order.isSingleTicketTransport ? this.$t("") : this.$t("") }}
</el-descriptions-item>
</template>
<el-descriptions-item :label="$t('代收货款')">
<dict-tag :type="DICT_TYPE.INFRA_BOOLEAN_STRING" :value="order.isCollection" />
<template v-if="order.isCollection == 1">({{order.collectionProxy}}{{currencyMap[order.collectionProxyCurrency]}})</template>
<template v-if="order.isCollection == 1">({{ order.collectionProxy }}{{ currencyMap[order.collectionProxyCurrency] }})</template>
</el-descriptions-item>
<el-descriptions-item :label="$t('提单是否显示价格')">
{{order.displayBillLadingPrice ? $t('是') : $t('否')}}
{{ order.displayBillLadingPrice ? $t("是") : $t("否") }}
</el-descriptions-item>
<el-descriptions-item :label="$t('仓库')">
{{order.isExternalWarehouse ? $t('外部仓') : $t('自有仓') }}
<template v-if="order.isExternalWarehouse" v-for="(item, index) in order.externalWarehouseDtoList" >
<div v-if="item.estLoadingTime || item.loadingAddress" :key="index">
{{$t('装柜时间')}}{{item.estLoadingTime}}
{{$t('装柜地址')}}{{item.loadingAddress}}
</div>
{{ order.isExternalWarehouse ? $t("外部仓") : $t("自有仓") }}
<template v-if="order.isExternalWarehouse" v-for="(item, index) in order.externalWarehouseDtoList">
<div v-if="item.estLoadingTime || item.loadingAddress" :key="index">{{ $t("装柜时间") }}{{ item.estLoadingTime }} {{ $t("装柜地址") }}{{ item.loadingAddress }}</div>
</template>
</el-descriptions-item>
<el-descriptions-item :label="$t('快递单号')">
{{order.number}}
</el-descriptions-item>
<el-descriptions-item :label="$t('创建人')">
{{order.creatorName}} ({{order.userType == 1 ? $t('会员') : $t('后台用户')}})
{{ order.number }}
</el-descriptions-item>
<el-descriptions-item :label="$t('创建人')"> {{ order.creatorName }} ({{ order.userType == 1 ? $t("会员") : $t("后台用户") }}) </el-descriptions-item>
<el-descriptions-item :label="$t('创建时间')">
{{order.createTime|parseTime}}
{{ order.createTime | parseTime }}
</el-descriptions-item>
<el-descriptions-item :label="$t('客户经理')">
{{order.salesmanName}}
{{ order.salesmanName }}
</el-descriptions-item>
<!--
新的原型中没有的字段,放在这里备用
......@@ -220,150 +187,125 @@
<el-card class="card">
<el-tabs v-model="activeName">
<el-tab-pane :label="$t('货物详情')" name="first">
<detail-prod :list="order.orderItemVOList"
:attr-list="attrList"
:prod-type-list="prodTypeList"
:currency-map="currencyMap"
:unit-map="unitMap"
:transport-id="order.transportId"
></detail-prod>
<detail-prod :list="order.orderItemVOList" :attr-list="attrList" :prod-type-list="prodTypeList" :currency-map="currencyMap" :unit-map="unitMap" :transport-id="order.transportId"></detail-prod>
</el-tab-pane>
<!--退参品名 退仓/已混箱品名 lanbm 2024-04-16 按客户的要求修改-->
<el-tab-pane :label="$t('退仓/已混箱品名')" name="six">
<detail-prod :list="orderItemDeletedData"
:attr-list="attrList"
:prod-type-list="prodTypeList"
:currency-map="currencyMap"
:unit-map="unitMap"
:transport-id="order.transportId"
></detail-prod>
<detail-prod :list="orderItemDeletedData" :attr-list="attrList" :prod-type-list="prodTypeList" :currency-map="currencyMap" :unit-map="unitMap" :transport-id="order.transportId"></detail-prod>
</el-tab-pane>
<!--lanbm 2024-06-11 处理订单到仓时间取值问题-->
<el-tab-pane :label="$t('订单动态')" name="second">
<el-timeline v-if="order.orderTimeVOList && order.orderTimeVOList.length" :reverse="true">
<el-timeline-item v-for="(activity, index) in order.orderTimeVOList" :key="index" :timestamp="parseTime(activity.businessTime)">
{{ $l(activity, 'title') }}
<div :class="{red: !!activity.mark}">{{$l(activity, 'remarks')}}</div>
{{ $l(activity, "title") }}
<div :class="{ red: !!activity.mark }">{{ $l(activity, "remarks") }}</div>
</el-timeline-item>
</el-timeline>
<el-result v-else icon="info " :title="$t('暂无数据')" :subTitle="$t('暂无订单动态数据')" />
</el-tab-pane>
<el-tab-pane :label="$t('运单资料/提货单')" name="three">
<!--inWarehouseState 1待入库,2多了,3少了,4到齐-->
<el-button v-hasPermi="['ecw:order:show_receipt']" type="text" @click="showWarehouseReceipt=true" :disabled="order.inWarehouseState == 0 && order.shipmentState == 0">{{$t('查看入仓单')}}</el-button>
<el-button v-hasPermi="['ecw:order:show_receipt']" type="text" @click="showWarehouseReceipt = true" :disabled="order.inWarehouseState == 0 && order.shipmentState == 0">{{ $t("查看入仓单") }}</el-button>
<image-display :type="1" :biz-id="order.orderId">
<el-button style="margin: 0 15px" type="text">{{$t('入仓影像')}}</el-button>
<el-button style="margin: 0 15px" type="text">{{ $t("入仓影像") }}</el-button>
</image-display>
<el-button v-hasPermi="['ecw:order:show_landing']" type="text" @click.native="showLadingBill=true" :disabled="!order.ladingState">{{$t('查看提货单')}}</el-button>
<el-button v-hasPermi="['ecw:order:show_packing']" :disabled="!order.packingListUrl" type="text" @click="downloadPackingList">{{$t('装箱单')}}</el-button>
<el-button v-hasPermi="['ecw:order:show_customs']" type="text" @click="showDeclaration=true">{{$t('查看报关资料')}}</el-button>
<el-button v-hasPermi="['ecw:order:show_landing']" type="text" @click.native="showLadingBill = true" :disabled="!order.ladingState">{{ $t("查看提货单") }}</el-button>
<el-button v-hasPermi="['ecw:order:show_packing']" :disabled="!order.packingListUrl" type="text" @click="downloadPackingList">{{ $t("装箱单") }}</el-button>
<el-button v-hasPermi="['ecw:order:show_customs']" type="text" @click="showDeclaration = true">{{ $t("查看报关资料") }}</el-button>
</el-tab-pane>
<el-tab-pane :label="$t('费用明细')" name="four">
<el-button v-has-permi="['order:detail:fee-detail']" type="primary" @click="showFeeSummary=true">{{$t('费用汇总')}}</el-button>
<el-button v-has-permi="['order:detail:fee-detail']" type="primary" @click="showFeeSummary = true">{{ $t("费用汇总") }}</el-button>
<el-table :data="feeList">
<el-table-column :label="$t('订单号')" prop="orderNo">
<template slot-scope="{row}">
{{row.orderNo}}
<template slot-scope="{ row }">
{{ row.orderNo }}
</template>
</el-table-column>
<el-table-column :label="$t('运输方式')">
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="order.transportId" />
</el-table-column>
<el-table-column :label="$t('出货渠道')">
{{channelName}}
{{ channelName }}
</el-table-column>
<el-table-column :label="$t('始发地')" prop="orderNo">
{{$l(departure, 'title') || '-'}}
{{ $l(departure, "title") || "-" }}
</el-table-column>
<el-table-column :label="$t('目的地')">
{{$l(objective, 'title') || '-'}}
{{ $l(objective, "title") || "-" }}
</el-table-column>
<el-table-column :label="$t('品名')" prop="titleZh">
<template slot-scope="{row}">
{{$l(row, 'title')}}
<template slot-scope="{ row }">
{{ $l(row, "title") }}
</template>
</el-table-column>
<el-table-column :label="$t('费用来源')" prop="feeSource">
<template slot-scope="{row}">
<template slot-scope="{ row }">
<dict-tag :type="DICT_TYPE.ECW_FEE_SOURCE" :value="row.feeSource" />
</template>
</el-table-column>
<el-table-column :label="$t('箱数')" prop="num">
<template slot-scope="{row}">
{{row.num || '-'}}
<template slot-scope="{ row }">
{{ row.num || "-" }}
</template>
</el-table-column>
<el-table-column :label="$t('体积/重量')">
<template slot-scope="{row}">
{{row.volume || '-'}} / {{row.weight || '-'}}
</template>
<template slot-scope="{ row }"> {{ row.volume || "-" }} / {{ row.weight || "-" }} </template>
</el-table-column>
<el-table-column :label="$t('收款类型')">
<template slot-scope="{row}">
<template slot-scope="{ row }">
<dict-tag :type="DICT_TYPE.PAYMENT_TYPE" :value="row.collectionType" />
</template>
</el-table-column>
<el-table-column :label="$t('收入类型')">
<template slot-scope="{row}">
<template slot-scope="{ row }">
<dict-tag :type="DICT_TYPE.FEE_TYPE" :value="row.feeType" />
</template>
</el-table-column>
<el-table-column :label="$t('单价金额')" prop="unitPrice">
<template slot-scope="{row}">
{{row.unitPrice}}{{currencyMap[row.currencyId]}}
</template>
<template slot-scope="{ row }"> {{ row.unitPrice }}{{ currencyMap[row.currencyId] }} </template>
</el-table-column>
<el-table-column :label="$t('总金额')" prop="totalAmount">
<template slot-scope="{row}">
{{row.totalAmount}}{{currencyMap[row.currencyId]}}
</template>
<template slot-scope="{ row }"> {{ row.totalAmount }}{{ currencyMap[row.currencyId] }} </template>
</el-table-column>
<el-table-column :label="$t('核销比例')" prop="totalAmount">
<template slot-scope="{row}">
{{row.writeOffProportion || 0}}
<template slot-scope="{ row }">
{{ row.writeOffProportion || 0 }}
</template>
</el-table-column>
</el-table>
</el-tab-pane>
<el-tab-pane :label="$t('到仓详情')" name="seven">
<check-detail-prod :list="warehouseCheckInfoData"
:attr-list="attrList"
:prod-type-list="prodTypeList"
:currency-map="currencyMap"
:unit-map="unitMap"
:transport-id="order.transportId"
:unload-time="order.unloadTime|parseTime"
></check-detail-prod>
<check-detail-prod :list="warehouseCheckInfoData" :attr-list="attrList" :prod-type-list="prodTypeList" :currency-map="currencyMap" :unit-map="unitMap" :transport-id="order.transportId" :unload-time="order.unloadTime | parseTime"></check-detail-prod>
</el-tab-pane>
<!-- 这个地方v-hasPermi不生效,所以换checkPermi函数检查 -->
<el-tab-pane :label="$t('操作日志')" name="five" v-if="checkPermi(['ecw:order:logs'])">
<el-table :data="logs" v-loading="logsLoading">
<el-table-column :label="$t('时间')" width="150">
<template slot-scope="{row}">{{ row.createTime|parseTime}}</template>
<template slot-scope="{ row }">{{ row.createTime | parseTime }}</template>
</el-table-column>
<el-table-column :label="$t('操作人')" prop="creatorName" width="150"> </el-table-column>
<el-table-column :label="$t('操作人类型')" width="100">
<template slot-scope="{row}">{{ row.userType == 1 ? $t('会员') : $t('管理员') }}</template>
<template slot-scope="{ row }">{{ row.userType == 1 ? $t("会员") : $t("管理员") }}</template>
</el-table-column>
<el-table-column :label="$t('操作类型')" prop="type" width="150"></el-table-column>
<el-table-column :label="$t('操作描述')" prop="msg" width="300"></el-table-column>
<el-table-column :label="$t('备注')" prop="note">
<template slot-scope="{row}">
<template slot-scope="{ row }">
<div v-if="row.note">
<div v-for="item in parseLogNote(row.note)">
<template v-if="item.orgValue">
{{$t('【{name}】从【{orgValue}】修改为【{newValue}', item)}}
{{ $t("【{name}】从【{orgValue}】修改为【{newValue}", item) }}
</template>
<template v-else>
{{$t('【{name}】设置为【{newValue}', item)}}
{{ $t("【{name}】设置为【{newValue}", item) }}
</template>
</div>
</div>
</template>
</el-table-column>
<el-table-column :label="$t('操作')" prop="note">
<template slot-scope="{row}">
<el-link type="primary" @click="showLogDetailId=row.id">{{$t('详情')}}</el-link>
<template slot-scope="{ row }">
<el-link type="primary" @click="showLogDetailId = row.id">{{ $t("详情") }}</el-link>
</template>
</el-table-column>
</el-table>
......@@ -371,72 +313,67 @@
</el-tabs>
</el-card>
<print-warehouse-receipt v-if="showWarehouseReceipt" :order-id="order.orderId" @close="showWarehouseReceipt=false" />
<print-warehouse-receipt v-if="showWarehouseReceipt" :order-id="order.orderId" @close="showWarehouseReceipt = false" />
<!--查看提货单 lanbm 2024-06-03-->
<print-lading-bill v-if="showLadingBill" :order-id="order.orderId" :transport-type="order.transportId" @close="showLadingBill=false" />
<print-lading-bill v-if="showLadingBill" :order-id="order.orderId" :transport-type="order.transportId" @close="showLadingBill = false" />
<!--入仓记录 lanbm 2024-06-10 add-->
<warehouse-detail :order="order" :orderItemId="showWarehouseInItemId" :type="type" @openPackHistory="openPackHistory" v-if="showWarehouseInItemId" @close="showWarehouseInItemId=null" />
<warehouse-detail :order="order" :orderItemId="showWarehouseInItemId" :type="type" @openPackHistory="openPackHistory" v-if="showWarehouseInItemId" @close="showWarehouseInItemId = null" />
<el-dialog :title="$t('付款人')" :visible.sync="showDarweeDialog" v-if="order && order.customDraweeVOList">
<el-table :data="order.customDraweeVOList" v-if="order.drawee==3" >
<el-table :data="order.customDraweeVOList" v-if="order.drawee == 3">
<el-table-column :label="$t('费用类型')" prop="label" width="200px">
<template slot-scope="{row}">
<dict-tag :type="DICT_TYPE.ECW_CUSTOM_DRAWEE" :value="row.name"/>
<template slot-scope="{ row }">
<dict-tag :type="DICT_TYPE.ECW_CUSTOM_DRAWEE" :value="row.name" />
</template>
</el-table-column>
<el-table-column :label="$t('付款人')" width="300px">
<template slot-scope="{row}">
<dict-tag :type="DICT_TYPE.DRAWEE" :value="row.value" />
</template>
<template slot-scope="{ row }">
<dict-tag :type="DICT_TYPE.DRAWEE" :value="row.value" />
</template>
</el-table-column>
</el-table>
</el-dialog>
<!--日志详情-->
<operate-log-detail v-if="showLogDetailId" :log-id="showLogDetailId" @close="showLogDetailId=null"></operate-log-detail>
<operate-log-detail v-if="showLogDetailId" :log-id="showLogDetailId" @close="showLogDetailId = null"></operate-log-detail>
<!--打包历史-->
<pack-history v-if="shopPackId" :order ="order" :orderItemId="shopPackId" @showPackDetail="showPackDetail" @close="shopPackId=null"></pack-history>
<pack-history v-if="shopPackId" :order="order" :orderItemId="shopPackId" @showPackDetail="showPackDetail" @close="shopPackId = null"></pack-history>
<!--打包历史详情-->
<pack-history-detail v-if="packAfterData" :order="order" :packAfterData="packAfterData" :orderItemId="showWarehouseInItemId" @close="packAfterData=null"></pack-history-detail>
<pack-history-detail v-if="packAfterData" :order="order" :packAfterData="packAfterData" :orderItemId="showWarehouseInItemId" @close="packAfterData = null"></pack-history-detail>
<!-- 报关资料 -->
<declaration-documents v-if="showDeclaration" :order-id="order.orderId" :order-no="order.orderNo" @close="showDeclaration=false" />
<declaration-documents v-if="showDeclaration" :order-id="order.orderId" :order-no="order.orderNo" @close="showDeclaration = false" />
<!--费用汇总-->
<fee-detail
v-if="showFeeSummary"
:order-id="order.orderId"
:currency-map="currencyMap"
@close="showFeeSummary=false" />
<fee-detail v-if="showFeeSummary" :order-id="order.orderId" :currency-map="currencyMap" @close="showFeeSummary = false" />
</div>
</template>
<script>
import {getOrder, operateLogPage, getOrderItemDeleted} from '@/api/ecw/order'
import { getDictDatas, DICT_TYPE, getDictData } from '@/utils/dict';
import PrintWarehouseReceipt from './components/PrintWarehouseReceipt'
import PrintLadingBill from './components/PrintLadingBill'
import {getUnitList} from '@/api/ecw/unit'
import {getCurrencyList} from '@/api/ecw/currency'
import {getReceivableListByOrderId} from '@/api/ecw/receipt'
import { getChannel } from '@/api/ecw/channel';
import {listByIds} from '@/api/ecw/region'
import WarehouseDetail from './components/WarehouseDetail';
import { parseTime } from '@/utils/ruoyi';
import { getOrder, operateLogPage, getOrderItemDeleted } from "@/api/ecw/order"
import { getDictDatas, DICT_TYPE, getDictData } from "@/utils/dict"
import PrintWarehouseReceipt from "./components/PrintWarehouseReceipt"
import PrintLadingBill from "./components/PrintLadingBill"
import { getUnitList } from "@/api/ecw/unit"
import { getCurrencyList } from "@/api/ecw/currency"
import { getReceivableListByOrderId } from "@/api/ecw/receipt"
import { getChannel } from "@/api/ecw/channel"
import { listByIds } from "@/api/ecw/region"
import WarehouseDetail from "./components/WarehouseDetail"
import { parseTime } from "@/utils/ruoyi"
import WarehouseAreaSelect from "@/components/WarehouseAreaSelect"
import {checkPermi} from '@/utils/permission'
import OperateLogDetail from "@/views/ecw/order/components/OprateLogDetail";
import DeclarationDocuments from './components/DeclarationDocuments';
import ImageDisplay from "@/views/ecw/order/components/imageDisplay.vue";
import FeeDetail from "@/views/ecw/order/components/FeeDetail.vue";
import PackHistory from './components/PackHistory';
import PackHistoryDetail from './components/PackHistoryDetail';
import {getOfferCheck} from '@/api/ecw/offer'
import {getSupplier} from "@/api/ecw/supplier";
import {getProductAttrList} from "@/api/ecw/productAttr";
import Decimal from 'decimal.js'
import DetailProd from '@/views/ecw/order/components/DetailProd.vue'
import CheckDetailProd from '@/views/ecw/order/components/CheckDetailProd.vue'
import {getProductTypeList} from "@/api/ecw/productType";
import { checkPermi } from "@/utils/permission"
import OperateLogDetail from "@/views/ecw/order/components/OprateLogDetail"
import DeclarationDocuments from "./components/DeclarationDocuments"
import ImageDisplay from "@/views/ecw/order/components/imageDisplay.vue"
import FeeDetail from "@/views/ecw/order/components/FeeDetail.vue"
import PackHistory from "./components/PackHistory"
import PackHistoryDetail from "./components/PackHistoryDetail"
import { getOfferCheck } from "@/api/ecw/offer"
import { getSupplier } from "@/api/ecw/supplier"
import { getProductAttrList } from "@/api/ecw/productAttr"
import Decimal from "decimal.js"
import DetailProd from "@/views/ecw/order/components/DetailProd.vue"
import CheckDetailProd from "@/views/ecw/order/components/CheckDetailProd.vue"
import { getProductTypeList } from "@/api/ecw/productType"
export default {
name: "detail",
......@@ -445,16 +382,21 @@ export default {
CheckDetailProd,
ImageDisplay,
OperateLogDetail,
PrintWarehouseReceipt, PrintLadingBill,
WarehouseDetail, WarehouseAreaSelect,DeclarationDocuments,
FeeDetail,PackHistory,PackHistoryDetail
PrintWarehouseReceipt,
PrintLadingBill,
WarehouseDetail,
WarehouseAreaSelect,
DeclarationDocuments,
FeeDetail,
PackHistory,
PackHistoryDetail
},
filters: {
customsTypeFilter(e, customsTypeList) {
if (e) return customsTypeList.find(item => item.value == e).label
if (e) return customsTypeList.find((item) => item.value == e).label
},
transportFilter(e, transportList) {
if (e) return transportList.find(item => item.value == e).label
if (e) return transportList.find((item) => item.value == e).label
},
parseTime
},
......@@ -464,12 +406,12 @@ export default {
// 遮罩层
loading: false,
order: null,
activeName: 'first',
activeName: "first",
orderId: 17,
tableData: [],
queryParams: {
pageNo: 1,
pageSize: 10,
pageSize: 10
},
activities: [],
customsTypeList: getDictDatas(DICT_TYPE.ECW_CUSTOMS_TYPE), //报关类型
......@@ -477,98 +419,98 @@ export default {
showWarehouseReceipt: false, // 是否显示打印入仓单
showLadingBill: false, // 是否显示打印提单
currencyList: [],
unitList:[],
unitList: [],
feeList: [],
channelName: '/',
region: '',
channelName: "/",
region: "",
orderWarehouseIn: null, // 入仓详情
showWarehouseInItemId: null, // 当前显示的入仓
/*showFeeDetailDialog: null, // 是否显示费用详情弹层
feeDetail: null, // 费用详情*/
logsLoading: false, // 日志加载中
logs: [], // 操作日志
activeNames: [],//显示隐藏订单基本信息
showText:this.$t('显示更多'),
showMore:false,
consigneeText:this.$t('更多'),
activeNames: [], //显示隐藏订单基本信息
showText: this.$t("显示更多"),
showMore: false,
consigneeText: this.$t("更多"),
showLogDetailId: null, // 显示日志详情的ID,
showDeclaration:false, //显示报关资料
showDeclaration: false, //显示报关资料
showFeeSummary: false, // 是否显示费用汇总
shopPackId:null,//显示打包历史的ID
packAfterData:null,//显示打包历史详情
shopPackId: null, //显示打包历史的ID
packAfterData: null, //显示打包历史详情
attrList: [],
orderItemDeletedData:[],//退仓品名
warehouseCheckInfoData:[],//到仓详情
prodTypeList:[],//商品类型列表
type:1
orderItemDeletedData: [], //退仓品名
warehouseCheckInfoData: [], //到仓详情
prodTypeList: [], //商品类型列表
type: 1
}
},
computed:{
currencyMap(){
let map = {}
this.currencyList.forEach(item => {
map[item.id] = this.$l(item, 'title')
})
return map
computed: {
currencyMap() {
let map = {}
this.currencyList.forEach((item) => {
map[item.id] = this.$l(item, "title")
})
return map
},
unitMap(){
let map = {}
this.unitList.forEach(item => {
map[item.id] = this.$l(item, 'title')
})
return map
unitMap() {
let map = {}
this.unitList.forEach((item) => {
map[item.id] = this.$l(item, "title")
})
return map
},
getDictData(){
return (type, value) => getDictData(type, value) || {}
getDictData() {
return (type, value) => getDictData(type, value) || {}
},
objective(){
if(this.order && this.order.objectiveVO){
objective() {
if (this.order && this.order.objectiveVO) {
return JSON.parse(this.order.objectiveVO.objective)
}
return {}
},
departure(){
if(this.order && this.order.departureVO){
departure() {
if (this.order && this.order.departureVO) {
return JSON.parse(this.order.departureVO.departure)
}
return {}
},
// 判断用户是否有查看客户详情的权限
hasCustomerDetailPermi(){
return checkPermi(['ecw:customer:index-query'])
hasCustomerDetailPermi() {
return checkPermi(["ecw:customer:index-query"])
},
// 显示特性
showAttrText(){
return ids => {
if(!ids) return ''
ids = !Array.isArray(ids) ? ids.split(',') : ids
showAttrText() {
return (ids) => {
if (!ids) return ""
ids = !Array.isArray(ids) ? ids.split(",") : ids
const attrMap = {}
this.attrList.forEach(item => {
attrMap[item.id] = this.$l(item, 'attrName')
this.attrList.forEach((item) => {
attrMap[item.id] = this.$l(item, "attrName")
})
return ids.map(id => attrMap[id]).join(',')
return ids.map((id) => attrMap[id]).join(",")
}
},
isAir(){
return [3,4].indexOf(+this.order?.transportId) > -1
isAir() {
return [3, 4].indexOf(+this.order?.transportId) > -1
}
},
watch:{
activeName(val){
if(!this.feeList.length && val == 'four'){
watch: {
activeName(val) {
if (!this.feeList.length && val == "four") {
this.loadFeeList()
}
if(!this.logs.length && val == 'five'){
if (!this.logs.length && val == "five") {
this.loadLogs()
}
},
'order.consigneeVO'(val){
if(!val) return '-'
listByIds({ids: [val.country, val.province, val.city].join(',')}).then(res => {
console.log('listById', res)
let region = ''
res.data.forEach(item => {
region += " " + this.$l(item, 'title')
"order.consigneeVO"(val) {
if (!val) return "-"
listByIds({ ids: [val.country, val.province, val.city].join(",") }).then((res) => {
console.log("listById", res)
let region = ""
res.data.forEach((item) => {
region += " " + this.$l(item, "title")
})
this.region = region
})
......@@ -577,69 +519,69 @@ export default {
created() {
if (this.$route.query.orderId) {
this.orderId = this.$route.query.orderId
this.getOrder();
this.getOrder()
this.getOfferNumber()
this.getOrderItemDeleted()
this.getProdTypeList();
this.getProdTypeList()
}
getCurrencyList().then(res => this.currencyList = res.data)
getUnitList().then(res => this.unitList = res.data)
getCurrencyList().then((res) => (this.currencyList = res.data))
getUnitList().then((res) => (this.unitList = res.data))
getProductAttrList().then(response => {
this.attrList = response.data;
getProductAttrList().then((response) => {
this.attrList = response.data
})
},
methods: {
checkPermi, // 检查权限,
handleTest(e){
handleTest(e) {
console.log("handleTest", e)
},
//订单信息显示更多
handleChange(val){
this.showText = val.length>0? this.$t('隐藏') : this.$t('显示更多')
handleChange(val) {
this.showText = val.length > 0 ? this.$t("隐藏") : this.$t("显示更多")
},
getAirCompany(){
getSupplier(this.order.airlineCompany).then(res => {
this.$set(this.order,'companyName',this.$l(res.data,'company'))
getAirCompany() {
getSupplier(this.order.airlineCompany).then((res) => {
this.$set(this.order, "companyName", this.$l(res.data, "company"))
})
},
//订单信息显示更多
consigneeChange(){
this.showMore = !this.showMore;
this.consigneeText = this.showMore? this.$t('隐藏') : this.$t('更多')
consigneeChange() {
this.showMore = !this.showMore
this.consigneeText = this.showMore ? this.$t("隐藏") : this.$t("更多")
},
/** 查询列表 */
getOrder() {
let that = this
that.loading = true;
that.loading = true
// 执行查询
getOrder(that.orderId).then(response => {
that.order = response.data;
if(that.order.airlineCompany) that.getAirCompany()
getOrder(that.orderId).then((response) => {
that.order = response.data
if (that.order.airlineCompany) that.getAirCompany()
for (let index in this.order.orderItemVOList) {
let item = this.order.orderItemVOList[index];
let item = this.order.orderItemVOList[index]
if (item.warehouseCheckInfoVO) {
this.warehouseCheckInfoData.push(item)
}
}
});
})
},
//退仓品名
getOrderItemDeleted(){
getOrderItemDeleted() {
let that = this
// 执行查询
getOrderItemDeleted(that.orderId).then(response => {
that.orderItemDeletedData = response.data;
});
getOrderItemDeleted(that.orderId).then((response) => {
that.orderItemDeletedData = response.data
})
},
/** 获取产品类型列表 */
getProdTypeList() {
getProductTypeList().then((response) => {
this.prodTypeList = response.data;
});
this.prodTypeList = response.data
})
},
/* loadBrands(){
let brandIds = []
......@@ -661,87 +603,89 @@ export default {
this.channelName = res.data.nameZh
})
},*/
loadFeeList(){
getReceivableListByOrderId({id: this.orderId}).then(res => {
loadFeeList() {
getReceivableListByOrderId({ id: this.orderId }).then((res) => {
this.feeList = res.data
})
},
// 加载操作日志
loadLogs(){
loadLogs() {
this.logsLoading = true
operateLogPage({orderId: this.orderId, page: 1, rows: 10000}).then(res => {
this.logs = res.data.list
}).finally(() => {
this.logsLoading = false
})
operateLogPage({ orderId: this.orderId, page: 1, rows: 10000 })
.then((res) => {
this.logs = res.data.list
})
.finally(() => {
this.logsLoading = false
})
},
downloadPackingList(){
downloadPackingList() {
window.open(this.order.packingListUrl)
},
// 显示入仓记录
showWarehouseLogs(row,type){
showWarehouseLogs(row, type) {
this.type = type
this.showWarehouseInItemId = row.orderItemId
},
getWarehouseIn(){
getOrderWarehouseIn(this.order.id).then(res => {
getWarehouseIn() {
getOrderWarehouseIn(this.order.id).then((res) => {
this.orderWarehouseIn = res.data
})
},
// 解析日志node字段
parseLogNote(note){
if(!note) return []
parseLogNote(note) {
if (!note) return []
return JSON.parse(note)
},
//查看打包历史
openPackHistory(id){
openPackHistory(id) {
this.shopPackId = id
},
//查看打包历史详情
showPackDetail(packAfterData){
showPackDetail(packAfterData) {
this.packAfterData = packAfterData
},
getOfferNumber() {
const that = this
getOfferCheck({ orderId: that.orderId }).then(response => {
getOfferCheck({ orderId: that.orderId }).then((response) => {
that.offerData = response.data
})
}
}
};
}
</script>
<style scoped>
.red{
.red {
color: red;
}
.card {
margin-bottom: 20px;
}
.card-title{
.card-title {
font-size: 18px;
font-weight: bold;
}
.el-dropdown-link {
cursor: pointer;
color: #409EFF;
color: #409eff;
}
.el-icon-arrow-down {
font-size: 12px;
}
.hiddenInfo{
display:none;
.hiddenInfo {
display: none;
}
.showInfo{
display:block;
.showInfo {
display: block;
}
/deep/ .el-collapse-item__header{
color:#409EFF !important;
/deep/ .el-collapse-item__header {
color: #409eff !important;
}
/deep/ .el-collapse-item__wrap{
margin-left:-12px;
border:none !important;
/deep/ .el-collapse-item__wrap {
margin-left: -12px;
border: none !important;
}
</style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment