|
|
@ -19,10 +19,28 @@ |
|
|
|
<el-input v-model="listQuery.params.goodsSkuCode" placeholder="" clearable/> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="仓库"> |
|
|
|
<el-input v-model="listQuery.params.warehouseName" placeholder="" clearable/> |
|
|
|
<el-select v-model="listQuery.params.warehouseName" filterable clearable placeholder="请选择" style="width:100%" @change="selectWarehouseName"> |
|
|
|
<el-option v-for="item in warehouseList" :key="item.sid" :label="item.warehouseName" :value="item.sid"> |
|
|
|
</el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="区域"> |
|
|
|
<el-select v-model="listQuery.params.wareZoneName" filterable clearable placeholder="请选择" @change="selectWareZoneName"> |
|
|
|
<el-option v-for="item in warehouseZoneList" :key="item.sid" :label="item.zoneName" :value="item.sid"> |
|
|
|
</el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="库区"> |
|
|
|
<el-select v-model="listQuery.params.warehouseAreaName" filterable clearable placeholder="请选择" @change="selectWareAreaName"> |
|
|
|
<el-option v-for="item in warehouseAreaList" :key="item.sid" :label="item.areaName" :value="item.sid"> |
|
|
|
</el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="库位"> |
|
|
|
<el-input v-model="listQuery.params.warehouseRackCode" placeholder="" clearable/> |
|
|
|
<el-select v-model="listQuery.params.warehouseRackCode" filterable clearable placeholder="请选择" style="width:100%"> |
|
|
|
<el-option v-for="item in warehouseRackCodeList" :key="item.rackCode" :label="item.rackCode" :value="item.rackCode"> |
|
|
|
</el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="供应商"> |
|
|
|
<el-input v-model="listQuery.params.supplierName" placeholder="" clearable/> |
|
|
@ -67,8 +85,10 @@ |
|
|
|
<el-table-column prop="unit" label="单位" align="center" width="80" /> |
|
|
|
<el-table-column prop="manufacturerName" label="厂家" align="center" min-width="100" /> |
|
|
|
<el-table-column prop="supplierName" label="供应商" align="center" min-width="100" /> |
|
|
|
<el-table-column prop="warehouseName" label="仓库" min-width="100" /> |
|
|
|
<el-table-column prop="warehouseRackCode" label="库位" width="100" /> |
|
|
|
<el-table-column prop="warehouseName" label="仓库" align="center" min-width="100" /> |
|
|
|
<el-table-column prop="wareZoneName" label="区域" align="center" min-width="100" /> |
|
|
|
<el-table-column prop="wareAreaName" label="库区" align="center" min-width="100" /> |
|
|
|
<el-table-column prop="warehouseRackCode" label="库位" align="center" width="100" /> |
|
|
|
<el-table-column prop="count" label="现有库存" align="center" width="100" /> |
|
|
|
<el-table-column prop="cost" label="入库单价" align="center" width="100" /> |
|
|
|
<el-table-column prop="tax" label="税率" align="center" width="100" /> |
|
|
@ -96,6 +116,7 @@ import pageye from '@/components/pagination/pageye' |
|
|
|
import ButtonBar from '@/components/ButtonBar' |
|
|
|
import req from '@/api/storage/inventory' |
|
|
|
import inventoryRecord from './inventoryRecord' |
|
|
|
import { getAllRackByKQSid, getAllWarehouse, getAllWarehouseareaByZoneSid, getAllWarehousezoneBysid } from '@/api/Common/dictcommons' |
|
|
|
|
|
|
|
export default { |
|
|
|
name: 'Capital', |
|
|
@ -144,6 +165,10 @@ export default { |
|
|
|
tableKey: 0, |
|
|
|
list: [], |
|
|
|
sids: [], // 用于导出的时候保存已选择的SIDs |
|
|
|
warehouseList: [], |
|
|
|
warehouseZoneList: [], |
|
|
|
wareAreaList: [], |
|
|
|
warehouseRackList: [], |
|
|
|
FormLoading: false, |
|
|
|
listLoading: false, |
|
|
|
// 翻页 |
|
|
@ -156,6 +181,8 @@ export default { |
|
|
|
goodsSpuName: '', |
|
|
|
goodsSkuCode: '', |
|
|
|
warehouseName: '', |
|
|
|
wareZoneName: '', |
|
|
|
wareAreaName: '', |
|
|
|
warehouseRackCode: '', |
|
|
|
supplierName: '', |
|
|
|
manufacturerName: '', |
|
|
@ -171,12 +198,20 @@ export default { |
|
|
|
}, |
|
|
|
created() { |
|
|
|
// 初始化变量 |
|
|
|
this.init() |
|
|
|
this.getList() |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
this.$refs['btnbar'].setButtonList(this.btnList) |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
init() { |
|
|
|
getAllWarehouse({ orgPath: window.sessionStorage.getItem('defaultOrgPath') }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.warehouseList = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
// 搜索条件效果 |
|
|
|
clicksearchShow() { |
|
|
|
this.isSearchShow = !this.isSearchShow |
|
|
@ -252,6 +287,8 @@ export default { |
|
|
|
goodsSpuName: '', |
|
|
|
goodsSkuCode: '', |
|
|
|
warehouseName: '', |
|
|
|
wareZoneName: '', |
|
|
|
wareAreaName: '', |
|
|
|
warehouseRackCode: '', |
|
|
|
supplierName: '', |
|
|
|
manufacturerName: '', |
|
|
@ -265,6 +302,66 @@ export default { |
|
|
|
} |
|
|
|
this.getList() |
|
|
|
}, |
|
|
|
selectWarehouseName(val) { |
|
|
|
const choose = this.warehouseList.filter((item) => item.sid === val) |
|
|
|
if (choose !== null || choose.length > 0) { |
|
|
|
this.listQuery.params.warehouseName = choose[0].warehouseName |
|
|
|
this.getWarehouseZoneList(choose[0].sid) |
|
|
|
} else { |
|
|
|
this.listQuery.params.warehouseName = '' |
|
|
|
} |
|
|
|
this.listQuery.params.wareZoneName = '' |
|
|
|
this.listQuery.params.wareAreaName = '' |
|
|
|
this.listQuery.params.warehouseRackCode = '' |
|
|
|
this.warehouseZoneList = [] |
|
|
|
this.wareAreaList = [] |
|
|
|
this.warehouseRackList = [] |
|
|
|
}, |
|
|
|
getWarehouseZoneList(sid) { |
|
|
|
getAllWarehousezoneBysid({ ckSid: sid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.warehouseZoneList = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
selectWareZoneName(val) { |
|
|
|
const choose = this.warehouseZoneList.filter((item) => item.sid === val) |
|
|
|
if (choose !== null && choose.length > 0) { |
|
|
|
this.listQuery.params.wareZoneName = choose[0].zoneName |
|
|
|
this.getWareAreaList(choose[0].sid) |
|
|
|
} else { |
|
|
|
this.listQuery.params.wareZoneName = '' |
|
|
|
} |
|
|
|
this.listQuery.params.wareAreaName = '' |
|
|
|
this.listQuery.params.warehouseRackCode = '' |
|
|
|
this.wareAreaList = [] |
|
|
|
this.warehouseRackList = [] |
|
|
|
}, |
|
|
|
getWareAreaList(sid) { |
|
|
|
getAllWarehouseareaByZoneSid({ qySid: sid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.wareAreaList = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
selectWareAreaName(val) { |
|
|
|
const choose = this.wareAreaList.filter((item) => item.sid === val) |
|
|
|
if (choose !== null && choose.length > 0) { |
|
|
|
this.listQuery.params.wareAreaName = choose[0].areaName |
|
|
|
this.getWarehouseRackList(choose[0].sid) |
|
|
|
} else { |
|
|
|
this.listQuery.params.wareAreaName = '' |
|
|
|
} |
|
|
|
this.listQuery.params.warehouseRackCode = '' |
|
|
|
this.warehouseRackList = [] |
|
|
|
}, |
|
|
|
getWarehouseRackList(sid) { |
|
|
|
getAllRackByKQSid({ kqSid: sid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.warehouseRackList = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
toCRK(row) { |
|
|
|
this.viewState = 2 |
|
|
|
this.$refs['divCRK'].showInfo(row) |
|
|
|