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,22 +36,32 @@ ...@@ -36,22 +36,32 @@
/* 基本配置*/ /* 基本配置*/
url: 'wms/ckgl/llck', url: 'wms/ckgl/llck',
queryUrl: 'wms/ckgl/jhtz/query/jhtzzy', queryUrl: 'wms/ckgl/jhtz/query/jhtzzy',
tableTitle: [ tableTitle: [{
title: "库位",
field: "kwName",
width: 100,
},
{ {
title: "库位", title: "容器",
field: "kwName", field: "rqCode",
width: 100, width: 100,
}, },
{ {
title: "容器", title: "唯一码",
field: "rqCode", field: "packCode",
width: 100, 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="tzqdLeft"> <div class="tzqdItem">
<BasePage ref="basePage" @getRow='getRow' :autoQuery='false' :power="{ 物料名称:{{app.singleItem.wlxxName}}
add: false, </div>
copy: false, <div class="tzqdItem" >
/* 手动控制删除 */ 物料编码:{{app.singleItem.wlxxCode}}
delButton: false, </div>
/* 手动控制编辑按钮权限 */ <div class="tzqdItem" >
editButton: false, 物料规格:{{app.singleItem.wlxxGg}}
/* 是否渲染右侧操作按钮 */ </div>
operateButtons: false, <div class="tzqdItem" >
/* 是否开启工作流按钮 */ 物料批号:{{app.singleItem.wlph}}
workFlow: false, </div>
/* 表格开启选择,以及记住选择 */ <div class="tzqdItem" >
showSelection: false, 制令号:{{app.singleItem.zlh}}
saveSelected: false </div>
}" :toolButton='false' class="min_full" style="height: 100%;width: 100%;" :config="config"> </div>
<div style="display: flex;height: 60vh;" >
<!-- 左表数据-->
<div class="tzqdLeft">
<BasePage @pageQueryFinally.once='pageQueryFinally' ref="basePage" @getRow='getRow' :autoQuery='false' :power="{
add: false,
copy: false,
/* 手动控制删除 */
delButton: false,
/* 手动控制编辑按钮权限 */
editButton: false,
/* 是否渲染右侧操作按钮 */
operateButtons: false,
/* 是否开启工作流按钮 */
workFlow: false,
/* 表格开启选择,以及记住选择 */
showSelection: false,
saveSelected: false
}" :toolButton='false' class="min_full" style="height: 100%;width: 100%;" :config="config">
<template slot="tabCustom2"> <template slot="tabCustom2">
<el-table-column label="操作" width="90" header-align="center" fixed="right"> <el-table-column label="操作" width="90" header-align="center" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button style="text-align: center;color: cornflowerblue;width: 100%;" <el-button style="text-align: center;color: cornflowerblue;width: 100%;"
@click.native.prevent="cz(scope.$index,scope,scope.row)" type="text" size="small"> @click.native.prevent="cz(scope.$index,scope,scope.row)" type="text" size="small">
<i class="el-icon-edit"></i>操作 <i class="el-icon-edit"></i>操作
</el-button> </el-button>
</template> </template>
</el-table-column> </el-table-column>
</template> </template>
</BasePage> </BasePage>
</div> </div>
<div class="tzqdRight"> <div class="tzqdRight">
<EditTable ref="editTable" :app='editTableConfig'> <EditTable ref="editTable" :app='editTableConfig'>
<template slot="tabCustom"> <template slot="tabCustom">
<el-table-column label="操作" width="90" header-align="center" fixed="right"> <el-table-column label="操作" width="90" header-align="center" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button style="text-align: center;color: red;width: 100%;" @click.native.prevent="del(scope.$index)" <el-button style="text-align: center;color: red;width: 100%;" @click.native.prevent="del(scope.$index)"
type="text" size="small"> type="text" size="small">
<i class="el-icon-delete"></i>删除 <i class="el-icon-delete"></i>删除
</el-button> </el-button>
</template> </template>
</el-table-column> </el-table-column>
</template> </template>
</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">
...@@ -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: "物料名称", title: "库存数量",
field: "wlxxName", field: "kcsl",
width: 140
},
{
title: "物料规格",
field: "wlxxGg",
width: 140
},
{
title: "数量",
field: "packmxSl",
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%;
...@@ -368,4 +383,4 @@ ...@@ -368,4 +383,4 @@
padding-left: 5px; padding-left: 5px;
padding-right: 5px; padding-right: 5px;
} }
</style> </style>
\ No newline at end of file
...@@ -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: {
...@@ -106,4 +117,4 @@ ...@@ -106,4 +117,4 @@
</script> </script>
<style> <style>
</style> </style>
\ No newline at end of file
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