Commit 167b6630 authored by 李苏's avatar 李苏 💬

调整

parent 188b88db
......@@ -3,6 +3,7 @@
<template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
<Xzgw @saveGw='saveGw' :app='ctx.basePage' v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='选择工位'" />
<Xj @saveGw='saveGw' :app='ctx.basePage' v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='下架'" />
</template>
<template #toolbar="ctx">
<!-- 嵌入默认页面工具栏的插槽 ctx.pagePage来操作默认页面 -->
......@@ -14,7 +15,7 @@
<!--<el-button v-if="ctx.basePage.powerObj['22']" @click="qxwc(ctx.basePage)" size='mini' type="primary">取消完成</el-button>-->
<el-button v-if="ctx.basePage.powerObj['23']" @click="sendSap(ctx.basePage)" size='mini' type="primary">发送至sap</el-button>
<el-button @click="cjxjrw(ctx.basePage)" size='mini'
type="primary">创建下架任务</el-button>
type="primary">下架</el-button>
</template>
</BasePage>
......@@ -23,6 +24,7 @@
<script>
import Edit from './edit.vue'
import Xzgw from './xzgw.vue'
import Xj from './xj.vue'
export default {
data() {
return {
......@@ -187,8 +189,8 @@
},
cjxjrw(ctx) {
if (ctx.singleItem && ctx.singleItem.id) {
ctx.DialogTitle = '选择工位'
ctx.DialogWidth = '40vw'
ctx.DialogTitle = '下架'
ctx.DialogWidth = '70vw'
ctx.showDialog = true
} else {
this.$warning('请选中一条数据')
......@@ -342,7 +344,7 @@
}
},
components: {
Edit,Xzgw
Edit,Xzgw,Xj
}
}
......
<template>
<DefaultDialog :app='app'>
<div slot="form" style="display: flex;height: 70vh;">
<xzgw @saveGw='saveGw' :app='this' v-if="showDialog" />
<!-- basePage-->
<BasePage fePage :changeQueryParams='changeQueryParams' ref="basePage" :power='power' :toolButton='false' class="min_full" style="height: 100%;"
:config="config">
<template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template>
<template #toolbar="ctx">
</template>
</BasePage>
</div>
<div slot="reFooter" class="refooter">
<span slot="footer" class="dialog-footer">
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
import xzgw from './xzgw.vue'
export default {
props: {
app: {
type: Object,
default: () => {
return {}
}
}
},
async mounted() {
},
data() {
return {
/* 单独控制本页的dialog*/
showDialog:false,
DialogTitle:'选择工位',
DialogWidth:'30vw',
power: {
add: false,
copy: false,
/* 手动控制删除 */
delButton: false,
/* 手动控制编辑按钮权限 */
editButton: false,
/* 是否渲染右侧操作按钮 */
operateButtons: false,
/* 是否开启工作流按钮 */
workFlow: false,
/* 表格开启选择,以及记住选择 */
showSelection: true,
saveSelected: true
},
config: {
/* 基本配置*/
url: 'lxyl/kcpd/queryKcpdqdForXj',
queryUrl: 'lxyl/kcpd/queryKcpdqdForXj',
tableTitle: [ {
title: "容器",
field: "rqCode",
width: 120,
},
{
title: "唯一码",
field: "packCode",
width: 160,
},
{
title: "物料编码",
field: "wlxxCode",
width: 160,
},
{
title: "物料名称",
field: "wlxxName",
width: 200
},
{
title: "物料批号",
field: "wlph",
width: 160
},
{
title: "规格",
field: "wlxxGg",
width: 140
},
{
title: "计量单位",
field: "jldwName",
width: 100,
},
{
title: "制令号",
field: "zlh",
width: 180,
},
{
title: "库位",
field: "kwCode",
width: 120,
},
{
title: "备注",
field: "bz",
width: 200,
}
],
queryParams: [[
{
label: '库位',
prop: 'kwInfo',
span: 6,
type: 'input',
value: ''
},
{
label: '物料信息',
prop: 'wlxxInfo',
span: 6,
type: 'input',
value: ''
},
{
label: '批号',
prop: 'wlphInfo',
span: 6,
type: 'input',
value: ''
},
{
label: '容器编码',
prop: 'rqInfos',
span: 6,
type: 'input',
value: ''
}
]]
}
}
},
components:{
xzgw
},
methods: {
saveGw(form){
let params = {
id:this.app.singleItem.id,
rqids:this.$refs.basePage.$refs.TablePager.selectedList.map(item=>item.id),
gwid:form.gwid
}
this.$post('lxyl/kcgl/kcpd/lkxj',params).then(res=>{
if(res.success){
this.$success('操作成功')
this.app.showDialog=false
this.app.refreshId(this.app.singleItem.id)
}
})
},
changeQueryParams(queryParams){
queryParams.mid= this.app.singleItem.id
let str=queryParams.rqInfos
let trimmedStr = str.replace(/\s/g, ''); // 使用正则表达式去除空格
trimmedStr=trimmedStr.replace(/,/s, ',')
let arr = trimmedStr.split(",");
queryParams.rqInfos=arr
console.log(queryParams.rqInfos)
},
changeZlh(val){
let list =this.$refs.basePage.$refs.TablePager.selectedList
list.forEach(item=>{
item.bghzlh=val||''
})
/* 触发save事件 */
this.$emit('save',list)
},
save(){
/* 判定是否勾选*/
let list =this.$refs.basePage.$refs.TablePager.selectedList
if(list.length!=0){
this.showDialog=true
}else{
this.showDialog=true
this.$warning('请至少勾选一条数据')
}
}
}
}
</script>
<style scoped lang="scss">
</style>
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