Commit edce21e5 authored by 黄卓's avatar 黄卓

入仓

parent b58a0ec1
......@@ -18,7 +18,7 @@
<dict-selector :type="DICT_TYPE.ECW_PRODUCT_MATERIAL" v-model="form.material"></dict-selector>
</el-form-item>
<el-form-item label="入仓时间">
<el-date-picker v-model="form.time" type="datetime" placeholder="请选择入仓时间"></el-date-picker>
<el-date-picker v-model="form.inTime" type="datetime" placeholder="请选择入仓时间"></el-date-picker>
</el-form-item>
</el-form>
......@@ -51,51 +51,51 @@
</el-table-column>
</el-table>
<el-table
:data="warehousingInNewList"
:data="form.orderWarehouseInItemDoList"
style="width: 100%">
<el-table-column label="箱数">
<template v-slot="{r,c,$index}">
<el-input v-model="warehousingInNewList[$index].cartonsNum" placeholder=""></el-input>
<el-input v-model="form.orderWarehouseInItemDoList[$index].cartonsNum" placeholder=""></el-input>
</template>
</el-table-column>
<el-table-column label="包装类型">
<template v-slot="{r,c,$index}">
<el-input v-model="warehousingInNewList[$index].boxGauge" placeholder=""></el-input>
<el-input v-model="form.orderWarehouseInItemDoList[$index].boxGauge" placeholder=""></el-input>
</template>
</el-table-column>
<el-table-column label="长(cm)">
<!-- <template v-slot="{r,c,$index}">-->
<!-- <el-input v-model="warehousingInNewList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- <el-input v-model="form.orderWarehouseInItemDoList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- </template>-->
</el-table-column>
<el-table-column label="款(cm)">
<!-- <template v-slot="{r,c,$index}">-->
<!-- <el-input v-model="warehousingInNewList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- <el-input v-model="form.orderWarehouseInItemDoList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- </template>-->
</el-table-column>
<el-table-column label="高(cm)">
<!-- <template v-slot="{r,c,$index}">-->
<!-- <el-input v-model="warehousingInNewList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- <el-input v-model="form.orderWarehouseInItemDoList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- </template>-->
</el-table-column>
<el-table-column label="体积(m³)">
<!-- <template v-slot="{r,c,$index}">-->
<!-- <el-input v-model="warehousingInNewList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- </template>-->
<template v-slot="{r,c,$index}">
<el-input v-model="form.orderWarehouseInItemDoList[$index].volume" placeholder=""></el-input>
</template>
</el-table-column>
<el-table-column label="重量(Kg)">
<!-- <template v-slot="{r,c,$index}">-->
<!-- <el-input v-model="warehousingInNewList[$index].cartonsNum" placeholder=""></el-input>-->
<!-- </template>-->
<template v-slot="{r,c,$index}">
<el-input v-model="form.orderWarehouseInItemDoList[$index].weight" placeholder=""></el-input>
</template>
</el-table-column>
<el-table-column label="数量">
<template v-slot="{r,c,$index}">
<el-input v-model="warehousingInNewList[$index].quantityAll" placeholder=""></el-input>
<el-input v-model="form.orderWarehouseInItemDoList[$index].quantityAll" placeholder=""></el-input>
</template>
</el-table-column>
<el-table-column label="快递单号">
<template v-slot="{r,c,$index}">
<el-input v-model="warehousingInNewList[$index].expressNo" placeholder=""></el-input>
<el-input v-model="form.orderWarehouseInItemDoList[$index].expressNo" placeholder=""></el-input>
</template>
</el-table-column>
</el-table>
......@@ -147,11 +147,22 @@ export default {
DICT_TYPE,
opened: false,
form: {
material: undefined,
inTime: 0
"brand": "",
"brandType": 0,
"inTime": "",
"material": "",
"orderId": 0,
"orderItemId": 0,
"orderNo": "",
"orderWarehouseInItemDoList": [],
"prodAttrIds": "",
"prodId": 0,
"prodTitleEn": "",
"prodTitleZh": "",
"prodType": 0,
"type": 0
},
// orderItem: {}
warehousingInNewList: []
};
},
......@@ -177,50 +188,47 @@ export default {
methods: {
handleSubmit() {
Promise.all(
this.warehousingInNewList.map(e => {
// Promise.all(
// this.form.orderWarehouseInItemDoList.map(e => {
// return orderWarehouseIn({
// ...e,
// inTime: this.form.inTime,
// material: this.form.material,
// brandType: this.warehousing.brandType,
// orderId: this.warehousing.orderId,
// orderItemId: this.warehousing.orderItemId,
// orderNo: this.warehousing.orderNo
// })
// })
// ).then(() => {
// this.handleClose()
// })
return orderWarehouseIn({
...e,
...this.form,
inTime: this.form.inTime,
material: this.form.material,
brandType: this.warehousing.brandType,
orderId: this.warehousing.orderId,
orderItemId: this.warehousing.orderItemId,
orderNo: this.warehousing.orderNo
})
})
).then(() => {
}).then(() => {
this.handleClose()
})
},
handleClose() {
this.warehousingInNewList = []
this.form.orderWarehouseInItemDoList = []
this.opened = false
},
handleDelete() {
this.warehousingInNewList.pop()
this.form.orderWarehouseInItemDoList.pop()
},
handleAdd() {
this.warehousingInNewList.push({
this.form.orderWarehouseInItemDoList.push({
"boxGauge": "",
"brand": "",
"brandType": 0,
"cartonsNum": 0,
"expressNo": "",
"inTime": "",
"material": "",
"orderId": 0,
"orderItemId": 0,
"orderNo": "",
"prodAttrIds": "",
"prodId": 0,
"prodTitleEn": "",
"prodTitleZh": "",
"prodType": 0,
"quantityAll": 0,
"type": 0,
"unit": "package",
"unit": "",
"volume": 0,
"weight": 0
})
......
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