1. 盘点增加根据物料信息的二次判断;

2. 物料信息增加盘点指示器,1/3。
This commit is contained in:
梁州 2025-11-24 14:31:44 +08:00
parent c4b8f5eeb4
commit c5c53f30d5
2 changed files with 820 additions and 766 deletions

View File

@ -11,7 +11,8 @@
</el-row>
<el-row>
<el-button style="background-color: #00CED1; color: #000;"
@click="uploadDialogVisible = true">导入</el-button>
@click="uploadDialogVisible = true">导入
</el-button>
<el-button style="background-color: #32CD32; color: #000;" @click="exportExcel()">导出</el-button>
</el-row>
</div>
@ -24,25 +25,30 @@
<el-radio :label="scope.row.goodsId" v-model="goodsId">&nbsp;</el-radio>
</template>
</el-table-column>
<el-table-column prop="goodsId" label="料号" fixed="left" min-width="120px" />
<el-table-column prop="goodsName" label="描述" min-width="120px" />
<el-table-column prop="goodsUnit" label="单位" min-width="120px" />
<el-table-column prop="goodsType" label="物料分类" min-width="120px" />
<el-table-column prop="providerType" label="供应商分类" min-width="120px" />
<el-table-column prop="weight" label="重量" min-width="120px" />
<el-table-column prop="weightUnit" label="重量单位" min-width="120px" />
<el-table-column prop="quantityPerBox" label="每盒数量" min-width="120px" />
<el-table-column prop="unpackingType" label="拆包方式" min-width="120px" />
<el-table-column prop="vehicleType" label="料箱类型" min-width="120px" />
<el-table-column prop="vehicleTypeDescription" label="料箱类型描述" min-width="120px" />
<el-table-column prop="goodsInVehicleType" label="料箱类型2" min-width="120px" />
<el-table-column prop="feedingType" label="补料方式" min-width="120px" />
<el-table-column prop="feedingValue" label="补货点" min-width="120px" />
<el-table-column prop="heat" label="热度" min-width="120px" />
<el-table-column prop="releasePoint" label="卸货点" min-width="120px" />
<el-table-column prop="dataSource" label="数据来源" min-width="120px" />
<el-table-column prop="lastUpdateTime" label="最近更新时间" :formatter="timeFormat" min-width="120px" />
<el-table-column prop="lastUpdateUser" label="最近更新用户" min-width="120px" />
<el-table-column prop="goodsId" label="料号" fixed="left" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="goodsName" label="描述" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="goodsUnit" label="单位" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="goodsType" label="物料分类" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="providerType" label="供应商分类" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="weight" label="重量" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="weightUnit" label="重量单位" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="quantityPerBox" label="每盒数量" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="unpackingType" label="拆包方式" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="vehicleType" label="料箱类型" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="vehicleTypeDescription" label="料箱类型描述" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="goodsInVehicleType" label="料箱类型2" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="feedingType" label="补料方式" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="feedingValue" label="补货点" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="heat" label="热度" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="releasePoint" label="卸货点" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="dataSource" label="数据来源" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="needInventory" label="盘点管理" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="haveSled" label="SLED管理" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="sledDays" label="SLED天数" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="indicator" label="盘点指示器" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="lastUpdateTime" label="最近更新时间" :formatter="timeFormat" min-width="120px"
show-overflow-tooltip/>
<el-table-column prop="lastUpdateUser" label="最近更新用户" min-width="120px" show-overflow-tooltip/>
<el-table-column fixed="right" label="操作" width="240px">
<template v-slot="scope">
<el-button plain type="primary" @click="editCurrentRowGoods(scope.row)">编辑</el-button>
@ -147,6 +153,32 @@
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="16">
<el-col :span="12" :offset="0">
<el-form-item label="盘点管理" prop="needInventory">
<el-input v-model="goodsFormEntity.needInventory" clearable/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="SLED管理" prop="haveSled">
<el-input v-model="goodsFormEntity.haveSled" clearable/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="16">
<el-col :span="12" :offset="0">
<el-form-item label="SLED天数" prop="sledDays">
<el-input-number v-model.number="goodsFormEntity.sledDays"
controls-position="right" clearable/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="盘点指示器" prop="indicator">
<el-input-number v-model.number="goodsFormEntity.indicator"
controls-position="right" :min="1" :max="3" :step="2" clearable/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="16">
<el-col :span="12" :offset="0">
<el-form-item label="料箱类型描述" prop="vehicleTypeDescription">
@ -296,6 +328,10 @@ export default {
dataSource: row.dataSource,
heat: row.heat,
releasePoint: row.releasePoint,
needInventory: row.needInventory,
haveSled: row.haveSled,
sledDays: row.sledDays,
indicator: row.indicator,
}
this.dialogVisible = true
},
@ -330,6 +366,9 @@ export default {
})
},
submitGoodsInfo(formData) {
if (formData.indicator !== null && formData.indicator !== 1 && formData.indicator !== 3) {
return errorBox('指示器只能为1或3')
}
const request = {
goodsId: formData.goodsId,
goodsName: formData.goodsName,
@ -348,6 +387,10 @@ export default {
heat: formData.heat,
releasePoint: formData.releasePoint,
dataSource: formData.dataSource,
needInventory: formData.needInventory,
haveSled: formData.haveSled,
sledDays: formData.sledDays,
indicator: formData.indicator,
userName: store.getters.getUserName
}
updateGoodsInfo(request).then(res => {

View File

@ -27,7 +27,8 @@
<el-table-column prop="vehicleIds" label="料箱号" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="vehicleStatus" label="料箱状态" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="feedingWS" label="备料工位" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="lastFeedingMachineNo" label="最后一台备料机器序列号" min-width="120px" show-overflow-tooltip />
<el-table-column prop="lastFeedingMachineNo" label="最后一台备料机器序列号" min-width="120px"
show-overflow-tooltip/>
<el-table-column prop="lastFeedingTime" label="备料最后一台车日期" min-width="120px" show-overflow-tooltip/>
<el-table-column prop="isLack" label="是否缺料" min-width="120px" show-overflow-tooltip/>
</el-table>
@ -111,7 +112,8 @@
<div style="display: flex; margin-top: 20px;">
<div class="display-form-div-left">
<el-input-number v-model.number="confirmFormEntity.confirmNum"
ref="confirmNum" v-on:keyup.enter="changeFocus()" controls-position="right" :min="0" />
ref="confirmNum" v-on:keyup.enter="changeFocus()" controls-position="right"
:min="0"/>
</div>
<div class="display-form-div-right">
<span class="display-form-text-right">PC</span>
@ -168,6 +170,7 @@ export default {
vehicleId: '',
confirmNum: null
}),
invIndexMap: new Map(),
}
},
mounted() {
@ -178,7 +181,7 @@ export default {
methods: {
//
getCurrentInvInfo() {
if (this.workFormEntity.goodsId == '') {
if (this.workFormEntity.goodsId === '') {
return
}
const request = {
@ -187,7 +190,7 @@ export default {
}
getCurrentGoodsInventory(request).then(res => {
const response = res.data
if (response.code == 0) {
if (response.code === 0) {
this.inventoryGoodsDetails = response.returnData
} else {
this.inventoryGoodsDetails = []
@ -216,7 +219,7 @@ export default {
this.$refs.confirmGoodsId.focus()
},
invenOut() {
if (this.workFormEntity.goodsId == '') {
if (this.workFormEntity.goodsId === '') {
errorBox('料号不可缺少')
return
}
@ -227,7 +230,7 @@ export default {
}
inventoryOut(request).then(res => {
const response = res.data
if (response.code == 0) {
if (response.code === 0) {
this.resetWorkForms()
ElMessage.success(response.message)
} else {
@ -240,20 +243,29 @@ export default {
},
//
invenConfirm() {
if (this.confirmFormEntity.goodsId == '' || this.confirmFormEntity.vehicleId == '' || this.confirmFormEntity.confirmNum == null || this.confirmFormEntity.confirmNum == '') {
if (this.confirmFormEntity.goodsId === '' || this.confirmFormEntity.vehicleId === '' || this.confirmFormEntity.confirmNum == null || this.confirmFormEntity.confirmNum === '') {
errorBox('料号、箱号、确认数量不可缺少。')
return
}
const invKey = this.confirmFormEntity.goodsId + '_' + this.confirmFormEntity.vehicleId
if (!this.invIndexMap.has(invKey)) {
this.invIndexMap.set(invKey, 1)
} else {
this.invIndexMap.set(invKey, this.invIndexMap.get(invKey) + 1)
}
const confirmParams = {
goodsId: this.confirmFormEntity.goodsId,
vehicleId: this.confirmFormEntity.vehicleId,
confirmNum: this.confirmFormEntity.confirmNum,
invIndex: this.invIndexMap.get(invKey),
userName: store.getters.getUserName
}
inventoryConfirmBack(confirmParams).then(res => {
const response = res.data
if (response.code == 0) {
if (response.code === 0) {
this.resetConfirmForms()
// map
this.invIndexMap.delete(invKey)
ElMessage.success(response.message)
} else {
errorBox(response.message)
@ -265,17 +277,16 @@ export default {
},
changeFocus() {
this.confirmFormEntity.vehicleId = replaceEnglishAndNumberIGAI(this.confirmFormEntity.vehicleId)
if (this.confirmFormEntity.vehicleId == '' || this.confirmFormEntity.vehicleId == null || this.confirmFormEntity.vehicleId == undefined) {
if (this.confirmFormEntity.vehicleId === '' || this.confirmFormEntity.vehicleId == null) {
this.$refs.confirmVehicleId.focus()
return
}
if (this.confirmFormEntity.goodsId == '' || this.confirmFormEntity.goodsId == null || this.confirmFormEntity.goodsId == undefined) {
if (this.confirmFormEntity.goodsId === '' || this.confirmFormEntity.goodsId == null) {
this.$refs.confirmGoodsId.focus()
return
}
if (this.confirmFormEntity.confirmNum == null || this.confirmFormEntity.confirmNum == undefined || this.confirmFormEntity.confirmNum == '') {
if (this.confirmFormEntity.confirmNum == null || this.confirmFormEntity.confirmNum === '') {
this.$refs.confirmNum.focus()
return
}
},
}