提交库存编号

master
Mr.sun 2 years ago
parent cdaf26da21
commit a12fe2456d
  1. 14
      src/api/libraryManage/inventory.js
  2. 54
      src/views/libraryManage/inventory/inventory.vue

@ -27,15 +27,15 @@ export function add(data) {
});
}
// 库内管理-补货-根据库别查询区域
// export function listAreaByStorage(query) {
// return request({
// url: `/wms/stock/common/listAreaByStorage/${query}`,
// method: "get",
// });
// }
// 库内管理-补货-根据库别查询区域
export function listAreaByStorage(query) {
return request({
url: `/wms/stock/common/listAreaByStorage/${query}`,
method: "get",
});
}
// 库内管理-补货-根据库别查询区域
export function storageList1(query) {
return request({
url: `/wms/storage/list`,
method: "get",

@ -38,23 +38,6 @@
</el-option>
</el-select>
</el-form-item> -->
<el-form-item label="库区编号">
<el-select
v-model="enterForm.id"
placeholder="请选择库区编号"
clearable
style="width: 240px"
>
<el-option
v-for="item in areaIdhList"
:key="item.storageCode"
:label="item.storageName"
:value="item.id"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="货位">
<el-input
v-model="enterForm.locationCode"
@ -92,6 +75,26 @@
</el-option>
</el-select>
</el-form-item>
<el-form-item
label="库区编号"
prop='state'
>
<el-select
v-model="enterForm.areaId"
placeholder="请选择库区编号"
clearable
style="width: 240px"
>
<el-option
v-for="item in areaIdhList"
:key="item.areaCode"
:label="item.areaName"
:value="item.id"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button
type="primary"
@ -137,7 +140,7 @@
import { tableConfig } from './config.js'
import { consignorList } from '@/api/warehousing/acceptance'
import { storageList } from '@/api/warehousing/acceptance'
import { queryGoods, add, listAreaByStorage, exportBtn } from '@/api/libraryManage/inventory'
import { queryGoods, storageList1, add, listAreaByStorage, exportBtn, getAreaList } from '@/api/libraryManage/inventory'
import { Debounce, getDictLabel } from '@/utils/index'
export default {
name: 'Inventory',
@ -160,6 +163,7 @@ export default {
areaIdhList: [],
handleSelect: [],
tableConfig: {},
storageId: '',
paging: {
page: 1, //
size: 10, //
@ -170,7 +174,11 @@ export default {
mounted() {
this.getBasicList()
this.getBasicListsto()
this.listAreaByStorage()
storageList1().then((res) => {
this.enterForm.storageId = res.data[0].id
this.listAreaByStorage(this.enterForm.storageId)
})
},
async created() {
this.tableConfig = await this.getTableHeaderCom('busin_inventory', tableConfig.call(this))
@ -191,15 +199,15 @@ export default {
//
selectStoId(val) {
this.enterForm.areaId = ''
if (val) {
this.listAreaByStorage(val)
if (this.enterForm.storageId) {
this.listAreaByStorage(this.enterForm.storageId)
}
},
//
listAreaByStorage(val) {
listAreaByStorage().then((res) => {
listAreaByStorage(this.enterForm.storageId).then((res) => {
this.areaIdhList = res.data
this.enterForm.areaId = 1
// console.log(this.areaIdhList)
})
},

Loading…
Cancel
Save