Commit 60cddee0 authored by 李苏's avatar 李苏 💬

质量重检测

parent 57e0bd47
<template> <template>
<BasePage @getRow='getRow' ref="basePage" :power='power' :toolButton='false' class="min_full" style="height: 100%;border-top: 0px;" :autoQuery='false' <BasePage @getRow='getRow' ref="basePage" :power='power' :toolButton='false' class="min_full"
:config="config"> style="height: 100%;border-top: 0px;" :autoQuery='false' :config="config">
<template #dialog="ctx"> <template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 --> <!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template> </template>
...@@ -36,8 +36,7 @@ ...@@ -36,8 +36,7 @@
/* 基本配置*/ /* 基本配置*/
url: 'wms/ckgl/llck', url: 'wms/ckgl/llck',
queryUrl: 'wms/ckgl/jhtz/query/jhtzzy', queryUrl: 'wms/ckgl/jhtz/query/jhtzzy',
tableTitle: [ tableTitle: [{
{
title: "库位", title: "库位",
field: "kwName", field: "kwName",
width: 100, width: 100,
...@@ -47,11 +46,22 @@ ...@@ -47,11 +46,22 @@
field: "rqCode", field: "rqCode",
width: 100, width: 100,
}, },
{
title: "唯一码",
field: "packCode",
width: 140,
},
{ {
title: "状态", title: "状态",
field: "zt", field: "zt",
width: 100, width: 100,
"transform": {
"url": "wms/ckgl/jhtz/init/zt",
"label": "name",
"value": "id"
} }
},
], ],
queryParams: [], queryParams: [],
...@@ -60,13 +70,13 @@ ...@@ -60,13 +70,13 @@
}, },
methods: { methods: {
getRow(val){ getRow(val) {
this.$emit('getRow',val) this.$emit('getRow', val)
}, },
demo(ctx){ demo(ctx) {
if(ctx.singleItem&&ctx.singleItem.id){ if (ctx.singleItem && ctx.singleItem.id) {
console.log(ctx.singleItem) console.log(ctx.singleItem)
}else{ } else {
this.$warning('请选中一条数据') this.$warning('请选中一条数据')
} }
} }
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<el-tab-pane class="full" label="拣货清单" name="second"> <el-tab-pane class="full" label="拣货清单" name="second">
<Qd ref="qd" class="full" /> <Qd ref="qd" class="full" />
</el-tab-pane> </el-tab-pane>
<el-tab-pane class="full" label="拣货汇总" name="third"> <el-tab-pane class="full" label="拣货作业" name="third">
<Hz ref="hz" class="full" /> <Hz ref="hz" class="full" />
</el-tab-pane> </el-tab-pane>
<el-tab-pane class="full" label="拣货结果" name="fourth"> <el-tab-pane class="full" label="拣货结果" name="fourth">
......
...@@ -108,7 +108,7 @@ ...@@ -108,7 +108,7 @@
{ {
"label": "仓库", "label": "仓库",
"prop": "ckid", "prop": "ckid",
"span": 6, "span": 4,
"type": "RelSelect", "type": "RelSelect",
"value": "", "value": "",
"typeConfig": { "typeConfig": {
...@@ -122,7 +122,7 @@ ...@@ -122,7 +122,7 @@
{ {
"label": "库区", "label": "库区",
"prop": "kqid", "prop": "kqid",
"span": 6, "span": 4,
"type": "RelSelect", "type": "RelSelect",
"value": "", "value": "",
"typeConfig": { "typeConfig": {
...@@ -138,7 +138,7 @@ ...@@ -138,7 +138,7 @@
{ {
label: '单据编号', label: '单据编号',
prop: 'djid', prop: 'djid',
span: 6, span: 4,
type: 'input', type: 'input',
value: '' value: ''
} }
......
<template> <template>
<DefaultDialog :app='app'> <DefaultDialog :app='app'>
<div slot="form" style="display: flex;height: 70vh;"> <div slot="form" >
<div style="height: 50px;width: 100%;display: flex;" >
<div class="tzqdItem">
物料名称:{{app.singleItem.wlxxName}}
</div>
<div class="tzqdItem" >
物料编码:{{app.singleItem.wlxxCode}}
</div>
<div class="tzqdItem" >
物料规格:{{app.singleItem.wlxxGg}}
</div>
<div class="tzqdItem" >
物料批号:{{app.singleItem.wlph}}
</div>
<div class="tzqdItem" >
制令号:{{app.singleItem.zlh}}
</div>
</div>
<div style="display: flex;height: 60vh;" >
<!-- 左表数据--> <!-- 左表数据-->
<div class="tzqdLeft"> <div class="tzqdLeft">
<BasePage ref="basePage" @getRow='getRow' :autoQuery='false' :power="{ <BasePage @pageQueryFinally.once='pageQueryFinally' ref="basePage" @getRow='getRow' :autoQuery='false' :power="{
add: false, add: false,
copy: false, copy: false,
/* 手动控制删除 */ /* 手动控制删除 */
...@@ -49,6 +67,8 @@ ...@@ -49,6 +67,8 @@
</EditTable> </EditTable>
</div> </div>
</div> </div>
</div>
<div slot="reFooter" class="refooter"> <div slot="reFooter" class="refooter">
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button @click="app.showDialog=false">取 消</el-button> <el-button @click="app.showDialog=false">取 消</el-button>
...@@ -83,24 +103,7 @@ ...@@ -83,24 +103,7 @@
this.$refs.basePage.queryParams.wlph = this.app.singleItem.wlph this.$refs.basePage.queryParams.wlph = this.app.singleItem.wlph
this.$refs.basePage.refresh() this.$refs.basePage.refresh()
/* 清单查询*/ /* 清单查询*/
let params = {
zlh: this.app.singleItem.zlh,
wlid: wlid,
wlph: this.app.singleItem.wlph,
mid: this.app.singleItem.$id,
ckid: this.app.singleItem.$ckid
}
this.$post('wms/ckgl/jhtz/query/jhtzqd', params).then(res => {
if (res.success) {
res.data.records.forEach(item => {
this.editTableConfig['editTableData'].push(_.cloneDeep(item))
/* 原始数据保留*/
this.original.push(_.cloneDeep(item))
this.sljl[item.packid] = item.jhsl
})
}
})
}) })
...@@ -139,14 +142,9 @@ ...@@ -139,14 +142,9 @@
width: 130, width: 130,
}, },
{ {
label: '名称', label: "物料批号",
prop: 'wlxxName', prop: "wlph",
width: 100, width: 140
},
{
label: '物料批号',
prop: 'wlph',
width: 100,
}, },
{ {
label: '容器', label: '容器',
...@@ -173,25 +171,11 @@ ...@@ -173,25 +171,11 @@
/* 基本配置*/ /* 基本配置*/
url: 'lxyl/zlgl/ukcjyd', url: 'lxyl/zlgl/ukcjyd',
// url: 'wms/ckgl/jhtz', // url: 'wms/ckgl/jhtz',
queryUrl: 'wms/common/queryZkPackOrRq', queryUrl: 'wms/common/query/kcfp',
tableTitle: [{ tableTitle: [
title: "物料编码",
field: "wlxxCode",
width: 140
},
{
title: "物料名称",
field: "wlxxName",
width: 140
},
{
title: "物料规格",
field: "wlxxGg",
width: 140
},
{ {
title: "数量", title: "库存数量",
field: "packmxSl", field: "kcsl",
width: 140 width: 140
}, },
{ {
...@@ -214,7 +198,6 @@ ...@@ -214,7 +198,6 @@
field: "packCode", field: "packCode",
width: 140 width: 140
}, },
{ {
title: "维护人", title: "维护人",
field: "whr" field: "whr"
...@@ -236,6 +219,33 @@ ...@@ -236,6 +219,33 @@
} }
}, },
methods: { methods: {
pageQueryFinally(){
/* 只执行意思*/
let params = {
zlh: this.app.singleItem.zlh,
wlid: this.app.singleItem.wlid,
wlph: this.app.singleItem.wlph,
mid: this.app.singleItem.$id,
ckid: this.app.singleItem.$ckid
}
this.$post('wms/ckgl/jhtz/query/jhtzqd', params).then(res => {
if (res.success) {
res.data.records.forEach(item => {
this.editTableConfig['editTableData'].push(_.cloneDeep(item))
/* 原始数据保留*/
this.original.push(_.cloneDeep(item))
this.sljl[item.packid] = item.jhsl
/* 延迟修改右侧原始数据*/
this.$refs.basePage.$refs.TablePager.tableData.forEach(ritem => {
if (ritem.packid == item.packid) {
/* 减少初始数量*/
ritem.kcsl=ritem.kcsl-item.jhsl
}
})
})
}
})
},
save() { save() {
/* 源数据*/ /* 源数据*/
let originalMap = {} let originalMap = {}
...@@ -297,7 +307,7 @@ ...@@ -297,7 +307,7 @@
let slc = o - n let slc = o - n
/* 数量记录为新*/ /* 数量记录为新*/
this.sljl[item.packid] = n this.sljl[item.packid] = n
item.packmxSl = item.packmxSl + slc item.kcsl = item.kcsl + slc
}, },
getRow(val) { getRow(val) {
...@@ -354,6 +364,11 @@ ...@@ -354,6 +364,11 @@
</script> </script>
<style scoped> <style scoped>
.tzqdItem{
flex: 1;
line-height: 50px;
font-weight: 800;
}
.tzqdLeft { .tzqdLeft {
width: 50%; width: 50%;
height: 100%; height: 100%;
......
...@@ -128,7 +128,7 @@ ...@@ -128,7 +128,7 @@
save(){ save(){
let list =this.$refs.basePage.$refs.TablePager.selectedList||[] let list =this.$refs.basePage.$refs.TablePager.selectedList||[]
if(list.length!=0){ if(list.length!=0){
this.$post('lxyl/zlgl/ukcjyd/add',list).then(res=>{ this.$post('lxyl/zlgl/kccj/doGenerate',list).then(res=>{
if(res.success){ if(res.success){
this.app.showDialog=false this.app.showDialog=false
this.app.refresh() this.app.refresh()
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
</template> </template>
<template #toolbar="ctx"> <template #toolbar="ctx">
<el-button @click="showAdd(ctx.basePage)" size='mini' type="primary">新增</el-button> <el-button @click="showAdd(ctx.basePage)" size='mini' type="primary">新增</el-button>
<el-button @click="cxjyrw(ctx.basePage)" size='mini' type="primary">创建检验任务</el-button>
</template> </template>
...@@ -95,6 +96,16 @@ ...@@ -95,6 +96,16 @@
}, },
getRow(val) { getRow(val) {
this.$emit('getRow', val) this.$emit('getRow', val)
},
cxjyrw(ctx){
if(ctx.singleItem&&ctx.singleItem.id){
this.$post('lxyl/zlgl/kccj/genJyd',{id:ctx.singleItem.id}).then(res=>{
if(res.success('操作成功')){
ctx.refresh()
}
})
}
} }
}, },
components: { components: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment