rev:解决冲突

This commit is contained in:
2023-05-29 10:24:49 +08:00
parent 6053f4046b
commit 973425d6a8
21 changed files with 718 additions and 74 deletions

View File

@@ -158,7 +158,8 @@
</template>
</el-table-column>
<el-table-column prop="material_name" label="物料名称" align="center" min-width="200" show-overflow-tooltip/>
<el-table-column prop="ivt_qty" label="库存重量" align="center" :formatter="crud.formatNum3"/>
<el-table-column v-if="!crud.status.view > 0" prop="ivt_qty" label="库存重量" align="center"
:formatter="crud.formatNum3"/>
<el-table-column prop="mol_qty" width="220" label="损溢重量" align="center">
<template scope="scope">
<el-input-number
@@ -289,25 +290,24 @@ export default {
},
[CRUD.HOOK.afterToEdit]() {
// 获取入库单明细
crudMoreOrless.queryMolDtl({'mol_id': this.form.mol_id, 'struct_id': this.form.struct_id}).then(res => {
crudMoreOrless.getMlDtl({'mol_id': this.form.mol_id}).then(res => {
this.form.tableData = res
// 将明细变成不可编辑
for (let i = 0; i < this.form.tableData.length; i++) {
const row = this.form.tableData[i]
row.isadd = false
row.edit = true
this.$set(row, 'edit', false)
this.form.tableData.splice(i, 1, row)
}
})
},
[CRUD.HOOK.afterToView]() {
this.mater_btn = true
crudMoreOrless.queryMolDetail({'mol_id': this.form.mol_id, 'struct_id': this.form.struct_id}).then(res => {
crudMoreOrless.getMlDtl({ 'mol_id': this.form.mol_id }).then(res => {
this.form.tableData = res
// 将明细变成不可编辑
for (let i = 0; i < this.form.tableData.length; i++) {
const row = this.form.tableData[i]
row.edit = true
this.$set(row, 'edit', true)
this.form.tableData.splice(i, 1, row)
}
})
@@ -363,8 +363,13 @@ export default {
this.$set(this.nowrow, 'material_code', row.material_code)
this.$set(this.nowrow, 'material_id', row.material_id)
this.$set(this.nowrow, 'material_name', row.material_name)
this.$set(this.nowrow, 'qty_unit_id', row.qty_unit_id)
this.$set(this.nowrow, 'qty_unit_id', row.base_unit_id)
this.$set(this.nowrow, 'qty_unit_name', row.base_unit_name)
this.$set(this.nowrow, 'struct_id', this.form.struct_id)
this.$set(this.nowrow, 'struct_code', this.form.struct_code)
this.$set(this.nowrow, 'sect_id', this.form.sect_id)
this.$set(this.nowrow, 'sect_name', this.form.sect_name)
this.$set(this.nowrow, 'struct_name', this.form.struct_name)
this.form.tableData.splice(this.nowindex, 1, this.nowrow) // 通过splice 替换数据 触发视图更新
},
tableChanged(row) {

View File

@@ -11,12 +11,12 @@
label-width="80px"
label-suffix=":"
>
<el-form-item label="模糊查询">
<el-form-item label="单据编号">
<el-input
v-model="query.struct_search"
v-model="query.mol_code"
size="mini"
clearable
placeholder="货位编码、名称"
placeholder="单据编号"
@keyup.enter.native="crud.toQuery"
/>
</el-form-item>
@@ -69,7 +69,7 @@
<el-form-item label="单据状态">
<el-select
v-model="query.bill_status"
v-model="query.status"
clearable
size="mini"
placeholder="单据状态"
@@ -149,8 +149,8 @@
<el-table-column :formatter="stateFormat" min-width="100" prop="status" label="单据状态" />
<el-table-column label="备注" align="center" min-width="100" prop="remark" />
<el-table-column prop="create_mode" min-width="100" :formatter="create_modeFormat" label="生成方式" />
<el-table-column label="制单人" align="center" min-width="100" prop="input_optname" />
<el-table-column label="制单时间" align="center" prop="input_time" min-width="150" />
<el-table-column label="制单人" align="center" min-width="100" prop="create_name" />
<el-table-column label="制单时间" align="center" prop="create_time" min-width="150" />
<el-table-column label="确认人" align="center" prop="confirm_optname" min-width="150" />
<el-table-column label="确认时间" align="center" prop="confirm_time" min-width="150" />
</el-table>
@@ -185,7 +185,7 @@ export default {
size: 20
},
idField: 'mol_id',
url: '/api/instor/mol',
url: '/api/moreOrLess',
crudMethod: { ...crudMoreOrless }
})
},

View File

@@ -2,7 +2,7 @@ import request from '@/utils/request'
export function add(data) {
return request({
url: '/api/instor/mol',
url: '/api/moreOrLess',
method: 'post',
data
})
@@ -10,16 +10,16 @@ export function add(data) {
export function del(ids) {
return request({
url: '/api/instor/mol',
method: 'delete',
url: '/api/moreOrLess/delete',
method: 'post',
data: ids
})
}
export function edit(data) {
return request({
url: '/api/instor/mol',
method: 'put',
url: '/api/moreOrLess/update',
method: 'post',
data
})
}
@@ -32,28 +32,20 @@ export function getStructIvt(params) {
})
}
export function queryMolDtl(params) {
export function getMlDtl(data) {
return request({
url: '/api/instor/mol/queryMolDtl',
method: 'get',
params
})
}
export function queryMolDetail(params) {
return request({
url: '/api/instor/mol/queryMolDetail',
method: 'get',
params
})
}
export function confirm(data) {
return request({
url: '/api/instor/mol/confirm',
url: '/api/moreOrLess/getMlDtl',
method: 'post',
data
})
}
export default { add, edit, del, getStructIvt, queryMolDtl, queryMolDetail, confirm }
export function confirm(data) {
return request({
url: '/api/moreOrLess/confirm',
method: 'post',
data
})
}
export default { add, edit, del, getStructIvt, getMlDtl, confirm }