Commit c5e5f06b authored by 周毅's avatar 周毅

修改批号锁定功能

parent e780e7ac
<template> <template>
<BasePage ref="basePage" :changeQueryParams='changeQueryParams'power='power' class="min_full" :config="config"> <BasePage ref="basePage" :changeQueryParams='changeQueryParams' :power='power' class="min_full" :config="config">
<template #dialog="ctx"> <template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 --> <!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
<Ph :app='ctx.basePage' v-if="ctx.basePage.showDialog==true" /> <Ph :app='ctx.basePage' v-if="ctx.basePage.showDialog==true" />
...@@ -30,8 +30,8 @@ ...@@ -30,8 +30,8 @@
operateButtons: true, operateButtons: true,
workFlow: false, workFlow: false,
/* 表格 */ /* 表格 */
showSelection: false, showSelection: true,
saveSelected: false saveSelected: true
}, },
config: { config: {
queryDetail: true, queryDetail: true,
...@@ -103,7 +103,7 @@ ...@@ -103,7 +103,7 @@
{ {
label: '物料信息', label: '物料信息',
prop: 'wlxxInfo', prop: 'wlxxInfo',
span: 6, span: 8,
type: 'input', type: 'input',
value: '' value: ''
}, },
...@@ -117,7 +117,7 @@ ...@@ -117,7 +117,7 @@
{ {
label: '制令号', label: '制令号',
prop: 'zlhInfos', prop: 'zlhInfos',
span: 12, span: 10,
type: 'input', type: 'input',
}, },
], ],
...@@ -145,7 +145,6 @@ ...@@ -145,7 +145,6 @@
} }
} }
}, },
] ]
], ],
/* 默认启停用 */ /* 默认启停用 */
...@@ -159,23 +158,23 @@ ...@@ -159,23 +158,23 @@
ctx.showDialog = true ctx.showDialog = true
}, },
doConfirm(ctx) { doConfirm(ctx) {
if (ctx.singleItem && ctx.singleItem.id) { let list =ctx.$refs.TablePager.selectedList;
this.$confirm('是否确认?', '提示', { if(list.length==0){
this.$warning('请至少勾选一条数据!')
return
}
let idList = list.map(item=>item.id)
this.$confirm('确定要解锁选中的数据吗?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(res => { }).then(res => {
this.$post('lxyl/zlgl/uLothold/releaseHold', { this.$post('lxyl/zlgl/uLothold/batchRelease', idList).then(res => {
id: ctx.singleItem.id
}).then(res => {
if (res.success) { if (res.success) {
ctx.refresh() ctx.refresh()
} }
}) })
}) })
} else {
this.$warning('请选中一条数据')
}
}, },
getRow(val) { getRow(val) {
this.$emit('getRow', val) this.$emit('getRow', val)
......
<template> <template>
<DefaultDialog :app='app'> <DefaultDialog :app='app'>
<div slot="form" style="display: flex;height: 450px;"> <div slot="form" style="display: flex;height: 650px;">
<Submit @save='savesdsm' :app='this' v-if="showDialog==true" /> <Submit @save='savesdsm' :app='this' v-if="showDialog==true" />
<BasePage <BasePage
...@@ -154,7 +154,7 @@ import Submit from './submit.vue' ...@@ -154,7 +154,7 @@ import Submit from './submit.vue'
let list = this.$refs.basePage.$refs.TablePager.selectedList let list = this.$refs.basePage.$refs.TablePager.selectedList
let params = { let params = {
sdsm:form.sdsm, sdsm:form.sdsm,
datas:list.map(item=>item.wlph) datas:list
} }
this.$post('lxyl/zlgl/uLothold/batchAdd',params).then(res=>{ this.$post('lxyl/zlgl/uLothold/batchAdd',params).then(res=>{
if(res.success){ if(res.success){
......
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