|
@@ -169,13 +169,6 @@
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :xs="8" :sm="8" :lg="8">
|
|
|
- <el-form-item label="发货仓库" prop="warehouse">
|
|
|
- <el-select v-model="deliverForm.warehouse" placeholder="请选择发货仓库" style="width: 100%" filterable @change="changeWarehouse">
|
|
|
- <el-option v-for="item in warehouseList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
- <el-col :xs="8" :sm="8" :lg="8">
|
|
|
<el-form-item label="选择仓位" prop="position">
|
|
|
<el-select v-model="deliverForm.position" placeholder="请选择仓位" style="width: 100%" filterable>
|
|
|
<el-option v-for="item in positionList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
|
@@ -298,7 +291,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { getDetail, getWarehouseList, adjustDeliver, finishData, directOrder } from "@/api/supply/retail";
|
|
|
+import { getDetail, getWarehouseList, adjustDeliver, finishData, directOrder, getPositionList } from "@/api/supply/retail";
|
|
|
|
|
|
export default {
|
|
|
name: 'RetailDetail',
|
|
@@ -323,21 +316,16 @@ export default {
|
|
|
isShowDeliverDialog: false,
|
|
|
deliverForm: {
|
|
|
date: '',
|
|
|
- warehouse: '',
|
|
|
position: '',
|
|
|
},
|
|
|
deliverFormRules: {
|
|
|
date: [
|
|
|
{ required: true, message: '请选择发货日期', trigger: 'change' }
|
|
|
],
|
|
|
- warehouse: [
|
|
|
- { required: true, message: '请选择发货仓库', trigger: 'change' }
|
|
|
- ],
|
|
|
position: [
|
|
|
- { required: true, message: '请选择仓位', trigger: 'change' }
|
|
|
+ { required: true, message: '请选择虚拟仓位', trigger: 'change' }
|
|
|
],
|
|
|
},
|
|
|
- warehouseList: [],
|
|
|
positionList: [],
|
|
|
|
|
|
goodsList: [],
|
|
@@ -415,24 +403,27 @@ export default {
|
|
|
pageNum: 1,
|
|
|
pageSize: -1,
|
|
|
}).then(res => {
|
|
|
- this.warehouseList = res.data.records;
|
|
|
this.warehouseList1 = res.data.records;
|
|
|
this.warehouseList2 = res.data.records;
|
|
|
})
|
|
|
},
|
|
|
|
|
|
- // 更改仓库
|
|
|
- changeWarehouse() {
|
|
|
- this.deliverForm.position = '';
|
|
|
- let obj = this.warehouseList.find(o => o.id == this.deliverForm.warehouse);
|
|
|
- this.positionList = obj.kingDeeStocks;
|
|
|
+ // 获取虚拟仓位列表
|
|
|
+ getPositionList() {
|
|
|
+ getPositionList({
|
|
|
+ pageNum: 1,
|
|
|
+ pageSize: -1,
|
|
|
+ stockType: 1
|
|
|
+ }).then(res => {
|
|
|
+ this.positionList = res.data.records;
|
|
|
+ })
|
|
|
},
|
|
|
|
|
|
// 打开 直调发货
|
|
|
openDeliverDialog() {
|
|
|
this.isShowDeliverDialog = true;
|
|
|
this.goodsList = this.detailData.retailOrderItemList;
|
|
|
- this.getWarehouseList();
|
|
|
+ this.getPositionList();
|
|
|
},
|
|
|
|
|
|
// 关闭 直调发货
|
|
@@ -459,7 +450,6 @@ export default {
|
|
|
let params = {
|
|
|
orderNo: this.listItem.id,
|
|
|
orderDate: this.deliverForm.date + ' 00:00:00',
|
|
|
- correspondId: this.deliverForm.warehouse,
|
|
|
stockId: this.deliverForm.position,
|
|
|
directItems: goodsList
|
|
|
}
|