opt:优化CTU出入库功能;

This commit is contained in:
2025-11-14 13:38:37 +08:00
parent 3d038430f3
commit a65125c8a1
32 changed files with 352 additions and 124 deletions

View File

@@ -36,6 +36,7 @@
size="mini"
placeholder="载具号"
style="width: 110px;"
class="filter-item"
@keyup.enter.native="crud.toQuery"
/>

View File

@@ -89,6 +89,19 @@
<el-table-column type="index" label="序号" align="center" :min-width="flexWidth('index',crud.data,'序号')" />
<el-table-column prop="sect_name" label="盘点库区" align="center" :min-width="flexWidth('sect_name',crud.data,'盘点库区')" />
<el-table-column prop="struct_name" label="盘点货位" align="center" :min-width="flexWidth('struct_name',crud.data,'盘点货位')" />
<!-- <el-table-column prop="storagevehicle_code" label="载具号" :min-width="flexWidth('storagevehicle_code',crud.data,'载具号')">-->
<!-- <template scope="scope">-->
<!-- <el-input v-show="isShow(scope.$index, scope.row,2)" v-model="scope.row.storagevehicle_code" :disabled="scope.row.status === '99'" />-->
<!-- <span v-show="isShow(scope.$index, scope.row,4)">{{ scope.row.storagevehicle_code }}</span>-->
<!-- </template>-->
<!-- </el-table-column>-->
<!-- <el-table-column prop="material_code" label="物料编码" align="center" :min-width="flexWidth('material_code',crud.data,'物料编码')">-->
<!-- <template scope="scope">-->
<!-- <el-input v-show="isShow(scope.$index, scope.row,2)" v-model="scope.row.ma
terial_code" :disabled="scope.row.status === '99'" />-->
<!-- <span v-show="isShow(scope.$index, scope.row,4)">{{ scope.row.material_code }}</span>-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column prop="storagevehicle_code" label="载具号" :min-width="flexWidth('storagevehicle_code',crud.data,'载具号')" />
<el-table-column prop="material_code" label="物料编码" align="center" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
<el-table-column prop="material_name" label="物料名称" align="center" :min-width="flexWidth('material_name',crud.data,'物料名称')" />

View File

@@ -196,12 +196,12 @@ import crudBsrealstorattr from '@/views/wms/basedata/bsrealstorattr/bsrealstorat
const defaultForm = {
bill_code: '',
stor_id: '',
stor_code: '',
stor_code: '1940342890681208833',
stor_name: '',
bill_status: '10',
total_qty: '0',
detail_count: '0',
bill_type: '',
bill_type: '1003',
remark: '',
biz_date: new Date(),
out_stor_id: '',
@@ -256,6 +256,10 @@ export default {
open() {
crudBsrealstorattr.getStor().then(res => {
this.storlist = res
if (this.storlist && this.storlist.length > 0) {
this.form.stor_id = this.storlist[0].stor_id
this.storChange()
}
})
},
close() {

View File

@@ -36,6 +36,17 @@
@keyup.enter.native="crud.toQuery"
/>
</el-form-item>
<el-form-item label="物料名称">
<el-input
v-model="query.material_name"
clearable
size="mini"
placeholder="物料"
style="width: 200px;"
class="filter-item"
@keyup.enter.native="crud.toQuery"
/>
</el-form-item>
<el-form-item label="物料编码">
<el-input
v-model="query.material_code"

View File

@@ -14,7 +14,7 @@
<span class="el-dialog__title2">出库分配</span>
<span class="crud-opts-right2">
<!--左侧插槽-->
<slot name="left" />
<slot name="left"/>
<el-button slot="left" type="info" @click="dialogVisible = false">关闭</el-button>
</span>
</div>
@@ -25,6 +25,7 @@
<el-form ref="form" :inline="true" :model="form" size="mini">
<el-form-item label="库区" prop="gender2">
<el-cascader
v-model="cascaderValue"
placeholder="请选择"
:options="sects"
:props="{ checkStrictly: true }"
@@ -36,7 +37,7 @@
</div>
<span class="crud-opts-right2">
<!--左侧插槽-->
<slot name="left" />
<slot name="left"/>
<el-button
slot="left"
class="filter-item"
@@ -124,13 +125,19 @@
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
@current-change="handleDtlCurrentChange"
>
<el-table-column prop="bill_status" label="状态" align="center" width="110px" :formatter="bill_statusFormat" />
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center" />
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center" />
<el-table-column show-overflow-tooltip prop="pcsn" label="批次号" align="center" width="140px" />
<el-table-column show-overflow-tooltip prop="plan_qty" label="数量" :formatter="crud.formatNum3" align="center" />
<el-table-column show-overflow-tooltip prop="assign_qty" label="已分配数量" :formatter="crud.formatNum3" align="center" />
<el-table-column show-overflow-tooltip prop="unassign_qty" label="未分配数量" :formatter="crud.formatNum3" align="center" />
<el-table-column prop="bill_status" label="状态" align="center" width="110px" :formatter="bill_statusFormat"/>
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center"/>
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center"/>
<el-table-column show-overflow-tooltip prop="pcsn" label="批次号" align="center" width="140px"/>
<el-table-column show-overflow-tooltip prop="plan_qty" label="数量" :formatter="crud.formatNum3"
align="center"
/>
<el-table-column show-overflow-tooltip prop="assign_qty" label="已分配数量" :formatter="crud.formatNum3"
align="center"
/>
<el-table-column show-overflow-tooltip prop="unassign_qty" label="未分配数量" :formatter="crud.formatNum3"
align="center"
/>
</el-table>
</el-card>
<div class="crud-opts2">
@@ -190,7 +197,7 @@
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
@current-change="handleDisCurrentChange"
>
<el-table-column type="index" label="序号" width="50" align="center" />
<el-table-column type="index" label="序号" width="50" align="center"/>
<el-table-column prop="bill_status" label="状态" align="center" width="110px">
<template slot-scope="scope">
<el-select
@@ -207,30 +214,46 @@
</el-select>
</template>
</el-table-column>
<el-table-column prop="material_code" label="物料编码" width="150px" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
<el-table-column prop="material_name" label="物料名称" width="170px" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
<el-table-column prop="storagevehicle_code" label="载具号" width="150px" :min-width="flexWidth('storagevehicle_code',crud.data,'载具号')" />
<el-table-column prop="pcsn" label="批次号" width="150px" :min-width="flexWidth('pcsn',crud.data,'批次号')" />
<el-table-column show-overflow-tooltip prop="plan_qty" label="出库数量" :formatter="crud.formatNum3" align="center" width="120px" :min-width="flexWidth('plan_qty',crud.data,'出库数量')">
<el-table-column prop="material_code" label="物料编码" width="150px"
:min-width="flexWidth('material_code',crud.data,'物料编码')"
/>
<el-table-column prop="material_name" label="物料名称" width="170px"
:min-width="flexWidth('material_name',crud.data,'物料名称')"
/>
<el-table-column prop="storagevehicle_code" label="载具号" width="150px"
:min-width="flexWidth('storagevehicle_code',crud.data,'载具号')"
/>
<el-table-column prop="pcsn" label="批次号" width="150px" :min-width="flexWidth('pcsn',crud.data,'批次号')"/>
<el-table-column show-overflow-tooltip prop="plan_qty" label="出库数量" :formatter="crud.formatNum3"
align="center" width="120px" :min-width="flexWidth('plan_qty',crud.data,'出库数量')"
>
<template scope="scope">
<el-input-number v-show="mstrow.bill_type === '1011'" v-model="scope.row.plan_qty" :precision="3" :controls="false" :min="1" style="width: 90px" />
<el-input-number v-show="mstrow.bill_type === '1011'" v-model="scope.row.plan_qty" :precision="3"
:controls="false" :min="1" style="width: 90px"
/>
<span v-show="mstrow.bill_type !== '1011'">{{ parseFloat(scope.row.plan_qty).toFixed(3) }}</span>
</template>
</el-table-column>
<el-table-column show-overflow-tooltip prop="struct_code" width="150px" label="仓位编码" align="center" />
<el-table-column show-overflow-tooltip prop="struct_name" width="150px" label="仓位名称" align="center" />
<el-table-column show-overflow-tooltip prop="create_time" width="150px" label="入库时间" align="center" />
<el-table-column show-overflow-tooltip prop="task_code" width="150px" label="任务号" align="center" />
<el-table-column show-overflow-tooltip prop="point_code" width="150px" label="出库点" align="center" />
<el-table-column show-overflow-tooltip prop="struct_code" width="150px" label="仓位编码" align="center"/>
<el-table-column show-overflow-tooltip prop="struct_name" width="150px" label="仓位名称" align="center"/>
<el-table-column show-overflow-tooltip prop="create_time" width="150px" label="入库时间" align="center"/>
<el-table-column show-overflow-tooltip prop="task_code" width="150px" label="任务号" align="center"/>
<el-table-column show-overflow-tooltip prop="point_code" width="150px" label="出库点" align="center"/>
<el-table-column align="center" label="操作" width="120" fixed="right">
<template scope="scope">
<el-button :disabled="tabledisabled(scope.row)" type="danger" class="filter-item" size="mini" icon="el-icon-delete" @click.native.prevent="deleteRow(scope.row)" />
<el-button :disabled="tabledisabled(scope.row)" type="danger" class="filter-item" size="mini"
icon="el-icon-delete" @click.native.prevent="deleteRow(scope.row)"
/>
</template>
</el-table-column>
</el-table>
</el-card>
<pointDialog ref="child" :dialog-show.sync="pointshow" :dialog-typedisable="typedisable" :dialog-areatype="areatype" @PointChanged="PointChanged" />
<StructIvt :dialog-show.sync="structshow" :stor-id="storId" :open-array="openParam" :rowmst="openRow" @StructIvtClosed="queryTableDtl2" />
<pointDialog ref="child" :dialog-show.sync="pointshow" :dialog-typedisable="typedisable" :dialog-areatype="areatype"
@PointChanged="PointChanged"
/>
<StructIvt :dialog-show.sync="structshow" :stor-id="storId" :open-array="openParam" :rowmst="openRow"
@StructIvtClosed="queryTableDtl2"
/>
</el-dialog>
</template>
@@ -259,7 +282,9 @@ export default {
},
openArray: {
type: Array,
default: () => { return [] }
default: () => {
return []
}
},
storId: {
type: String,
@@ -268,6 +293,7 @@ export default {
},
data() {
return {
cascaderValue: [],
dialogVisible: false,
loadingAlldiv: false,
loadingAutodiv: false,
@@ -297,8 +323,7 @@ export default {
},
sects: [],
pointList: [],
rules: {
}
rules: {}
}
},
watch: {
@@ -322,11 +347,25 @@ export default {
methods: {
open() {
crudSectattr.getSectCode({ 'stor_id': this.storId }).then(res => {
debugger
this.sects = res.content
if (this.sects && this.sects.length > 0) {
const firstOption = this.sects[0]
if (firstOption.children && firstOption.children.length > 0) {
this.cascaderValue = [firstOption.value, firstOption.children[0].value]
} else {
this.cascaderValue = [firstOption.value]
}
this.sectQueryChange(this.cascaderValue)
}
})
crudRegion.getRegionList(this.mstrow).then(res => {
this.pointList = res
if (this.pointList && this.pointList.length > 0) {
const foundPoint = this.pointList.find(r => r.region_name.includes('出'))
if (foundPoint) {
this.form2.point_code = foundPoint.region_code
}
}
})
},
close() {
@@ -355,6 +394,9 @@ export default {
})
},
sectQueryChange(val) {
if (!val || val.length === 0) {
val = this.cascaderValue
}
if (val.length === 1) {
this.mstrow.stor_code = val[0]
this.mstrow.sect_code = ''
@@ -528,18 +570,19 @@ export default {
.crud-opts2 .el-dialog__title2 {
line-height: 24px;
font-size:20px;
color:#303133;
font-size: 20px;
color: #303133;
}
.crud-opts2 .role-span {
padding: 10px 0px 10px 0px;
}
.crud-opts2 .crud-opts-form {
padding: 10px 0px 0px 20px;
}
.input-with-select {
.input-with-select {
background-color: #fff;
}
</style>

View File

@@ -81,7 +81,7 @@
<el-table-column prop="vehicle_code" label="载具编码" width="150" show-tooltip-when-overflow />
<el-table-column prop="growth" label="是否增加库存" width="150" show-tooltip-when-overflow>
<template slot-scope="scope">
{{ scope.row.growth }}
{{ scope.row.growth ? '是' : '否' }}
</template>
</el-table-column>
<el-table-column prop="pcsn" label="批次" min-width="150" show-tooltip-when-overflow />