Commit d2b4ce19 authored by huhaiqing's avatar huhaiqing

海运出货多规格

parent fccdf694
<template>
<!-- 订单获取入仓记录 -->
<el-dialog :title="title" visible :before-close="closeDialog" :close-on-click-modal="false" width="1000px" append-to-body>
<el-table v-if="warehouseItem && warehouseItem.orderWarehouseInBackItemDoList" :data="warehouseItem.orderWarehouseInBackItemDoList">
<el-table-column type="index" :label="$t('序号')" />
<el-table-column :label="$t('箱数')" prop="cartonsNum" />
<el-table-column :label="$t('入仓类型')" prop="cartonsNum">
<template slot-scope="{row}">
<dict-tag :type="DICT_TYPE.WAREHOUSING_SPECIFICATION_TYPE" :value="row.specificationType" />
</template>
</el-table-column>
<el-table-column :label="$t('包装类型')" prop="unit">
<template slot-scope="{row}">
<dict-tag :type="DICT_TYPE.ECW_PACKAGING_TYPE" :value="row.unit" />
</template>
</el-table-column>
<el-table-column :label="$t('长')" prop="boxGauge">
<template slot-scope="{row}">
{{row.boxGauge.split('*')[0]}}
</template>
</el-table-column>
<el-table-column :label="$t('宽')" prop="boxGauge">
<template slot-scope="{row}">
{{row.boxGauge.split('*')[1]}}
</template>
</el-table-column>
<el-table-column :label="$t('高')" prop="boxGauge">
<template slot-scope="{row}">
{{row.boxGauge.split('*')[2]}}
</template>
</el-table-column>
<el-table-column :label="$t('体积') + '(m³)'" prop="volume" />
<el-table-column :label="$t('重量') + '(kg)'" prop="weight" />
<el-table-column :label="$t('数量(个)')" prop="quantityAll" />
<el-table-column :label="$t('快递单号')" prop="expressNo" />
<el-table-column :label="$t('入仓时间')" prop="inTime">
<template slot-scope="{row}">{{row.inTime|parseTime}}</template>
</el-table-column>
</el-table>
</el-dialog>
</template>
<script>
import { getOrder, getOrderWarehouseIn } from "@/api/ecw/order";
import { DICT_TYPE } from "@/utils/dict";
import { parseTime } from "@/utils/ruoyi";
export default {
filters: { parseTime },
props: {
order: Object, // order 和 orderId 二选一
orderId: Number,
orderItemId: Number,
},
data() {
return {
orderDetail: null,
warehouseList: null,
};
},
computed: {
info() {
return this.orderDetail || this.order;
},
orderItem() {
if (!this.info) return null;
return this.info.orderItemVOList.find(
(item) => item.orderItemId == this.orderItemId
);
},
warehouseItem() {
if (!this.warehouseList) return [];
return (
this.warehouseList.find(
(item) => item.orderItemId == this.orderItemId
) || []
);
},
title() {
if (!this.orderItem) return "-";
return this.$l(this.orderItem, "prodTitle") + " - " + this.$t("入仓记录");
},
},
created() {
this.show = true;
if (!this.order && this.orderId) {
getOrder(this.orderId).then((res) => {
this.orderDetail = res.data;
});
}
this.getOrderWarehouseIn();
},
methods: {
closeDialog() {
this.show = false;
this.$emit("close");
},
getOrderWarehouseIn() {
getOrderWarehouseIn(this.info.orderId).then((res) => {
this.warehouseList = res.data;
});
},
},
};
</script>
......@@ -47,9 +47,9 @@
</el-table-column>
<el-table-column :label="$t('箱数')" align="center" prop="num">
<template slot-scope="scope">
<div>
<el-link type="primary" @click.native="showWarehouseLogs(scope.row)">
{{scope.row.num}}
</div>
</el-link>
<div style="color:blue;fontWeight:bold;">
{{ scope.row.multiSpecification === true ? '(多规格)' : ''}}
</div>
......@@ -93,6 +93,7 @@
<el-dialog custom-class="shipping-dialog" :title="dialogConfig.title" :visible.sync="dialogConfig.dialogVisible" :fullscreen="dialogConfig.fullscreen" :width="dialogConfig.width" :modal-append-to-body=false append-to-body>
<batchTally v-if="dialogConfig.dialogVisible" v-bind="$attrs" @closeDialog="closeDialog" :type="dialogConfig.type" :tallyRows="tallyRows" :shipmentObj="shipmentObj" />
</el-dialog>
<warehouse-detail :order="order" :orderItemId="showWarehouseInItemId" v-if="showWarehouseInItemId" @close="showWarehouseInItemId=null" />
</div>
</template>
......@@ -100,18 +101,23 @@
import batchTally from "./batchTally.vue";
import { getTallyList, tallyRemove, tallyCommit } from "@/api/ecw/boxSea";
import { formatDate, serviceMsg } from "../../utils";
import WarehouseDetail from "./WarehouseDetail";
import { getOrder } from "@/api/ecw/order";
export default {
name: "tally",
inheritAttrs: false,
components: {
batchTally,
WarehouseDetail,
},
props: {
shipmentObj: Object,
},
data() {
return {
showWarehouseInItemId: null,
order: null,
tallyList: [],
// 理货数据
tallyRows: [],
......@@ -245,6 +251,13 @@ export default {
});
});
},
// 显示入仓记录
showWarehouseLogs(row) {
getOrder(row.orderId).then((response) => {
this.order = response.data;
this.showWarehouseInItemId = row.orderItemId;
});
},
},
computed: {
/* 获取仓库 */
......
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