Commit de8aaa87 authored by 李苏's avatar 李苏 💬

关闭取消关闭

parent 01dfba71
<template> <template>
<BasePage @getRow='getRow' :power='power' class="min_full" style="height: 100%;" :config="config"> <BasePage @getRow='getRow' :power='power' class="min_full" style="height: 100%;" :config="config">
<template #dialog="ctx"> <template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 --> <!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template> </template>
<template #toolbar="ctx"> <template #toolbar="ctx">
<el-button @click="jhtj(ctx.basePage)" size='mini' type="primary">拣货推荐</el-button> <el-button @click="jhtj(ctx.basePage)" size='mini' type="primary">拣货推荐</el-button>
<!-- <ImportButton @success="()=>{ <el-button @click="gb(ctx.basePage)" size='mini' type="primary">关闭</el-button>
<el-button @click="qxgb(ctx.basePage)" size='mini' type="primary">取消关闭</el-button>
<!-- <ImportButton @success="()=>{
ctx.basePage.refresh() ctx.basePage.refresh()
}" :url="'wms/ckgl/jhtz/import'" /> --> }" :url="'wms/ckgl/jhtz/import'" /> -->
</template> </template>
</BasePage> </BasePage>
</template> </template>
<script> <script>
import Edit from './edit.vue' import Edit from './edit.vue'
export default { export default {
data() { data() {
return { return {
power: { power: {
add: true, add: true,
copy: false, copy: false,
/* 手动控制删除 */ /* 手动控制删除 */
delButton: true, delButton: true,
/* 手动控制编辑按钮权限 */ /* 手动控制编辑按钮权限 */
editButton: true, editButton: true,
/* 是否渲染右侧操作按钮 */ /* 是否渲染右侧操作按钮 */
operateButtons: true, operateButtons: true,
/* 是否开启工作流按钮 */ /* 是否开启工作流按钮 */
workFlow: false, workFlow: false,
/* 表格开启选择,以及记住选择 */ /* 表格开启选择,以及记住选择 */
showSelection: false, showSelection: false,
saveSelected: false saveSelected: false
}, },
config: { config: {
queryDetail: true, queryDetail: true,
/* 基本配置*/ /* 基本配置*/
url: 'wms/ckgl/jhtz', url: 'wms/ckgl/jhtz',
tableTitle: [ tableTitle: [{
title: "状态",
field: "zt",
fieldType: "ftString",
align: 'center',
width: 80,
"transform": {
"url": "wms/ckgl/jhtz/init/zt",
"label": "name",
"value": "id"
}
},
{ {
title: "状态", title: "拣货单号",
field: "zt", field: "djid",
fieldType: "ftString", width: 140
align: 'center', },
width: 80,
"transform": {
"url": "wms/ckgl/jhtz/init/zt",
"label": "name",
"value": "id"
}
},
{
title: "拣货单号",
field: "djid",
width: 140
},
{
title: "业务日期",
field: "ywrq",
fieldType: 'ftDate'
},
{ {
title: "仓库编码", title: "业务日期",
field: "ckCode", field: "ywrq",
width: 140 fieldType: 'ftDate'
}, },
{ {
title: "仓库", title: "仓库编码",
field: "ckName", field: "ckCode",
width: 140 width: 140
}, },
{ {
title: "库区", title: "仓库",
field: "kqName", field: "ckName",
width: 140 width: 140
}, },
{ {
title: "事务类型", title: "库区",
field: "swlxName", field: "kqName",
width: 100 width: 140
}, },
{ {
title: "货主", title: "事务类型",
field: "hzName", field: "swlxName",
width: 140 width: 100
},
{
title: "货主",
field: "hzName",
width: 140
},
{
title: "拣货人",
field: "jhrName",
width: 140
}, },
{
title: "拣货人",
field: "jhrName",
width: 140
},
{ {
title: "单据来源", title: "单据来源",
field: "djly", field: "djly",
width: 140, width: 140,
"transform": { "transform": {
"url": "wms/ckgl/jhtz/init/djly", "url": "wms/ckgl/jhtz/init/djly",
"label": "name", "label": "name",
"value": "id" "value": "id"
} }
}, },
{ {
...@@ -106,137 +107,183 @@ ...@@ -106,137 +107,183 @@
width: 140 width: 140
}, },
{ {
title: "备注", title: "备注",
field: "bz", field: "bz",
width: 240 width: 240
}, },
{ {
title: "维护人", title: "维护人",
field: "whr" field: "whr"
}, },
{ {
title: "维护时间", title: "维护时间",
field: "whsj", field: "whsj",
fieldType: 'ftDateTime' fieldType: 'ftDateTime'
} }
], ],
queryParams: [ queryParams: [
[{ [{
label: '日期', label: '日期',
startProp: "start", startProp: "start",
endProp: "end", endProp: "end",
span: 8, span: 8,
type: 'RelDaterangeV2', type: 'RelDaterangeV2',
startValue: new Date().getTime()-1000*60*60*24*30, startValue: new Date().getTime() - 1000 * 60 * 60 * 24 * 30,
endValue:new Date().getTime(), endValue: new Date().getTime(),
}, },
{
"label": "仓库",
"prop": "ckid",
"span": 8,
"type": "RelSelect",
"value": "",
"typeConfig": {
"src": "jcsj/common/ck/queryCkid",
"match": {
"value": "id",
"label": "name"
}
}
},
{ {
"label": "库区", "label": "仓库",
"prop": "kqid", "prop": "ckid",
"span": 8, "span": 8,
"type": "RelSelect", "type": "RelSelect",
"value": "", "value": "",
"typeConfig": { "typeConfig": {
linkParams:['ckid'], "src": "jcsj/common/ck/queryCkid",
linkage:true, "match": {
"src": "wms/jcsj/kq/query", "value": "id",
"match": { "label": "name"
"value": "id", }
"label": "name" }
} },
} {
"label": "库区",
"prop": "kqid",
"span": 8,
"type": "RelSelect",
"value": "",
"typeConfig": {
linkParams: ['ckid'],
linkage: true,
"src": "wms/jcsj/kq/query",
"match": {
"value": "id",
"label": "name"
}
}
}, },
],[ ],
{ [{
label: '单据编号', label: '单据编号',
prop: 'djid', prop: 'djid',
span: 8, span: 8,
type: 'input', type: 'input',
value: '' value: ''
}, },
{ {
label: '货主', label: '货主',
prop: 'hzInfo', prop: 'hzInfo',
span: 8, span: 8,
type: 'input', type: 'input',
value: '' value: ''
}, },
{
label: '状态',
prop: 'zt',
span: 8,
type: 'RelSelect',
typeConfig: {
src: 'wms/ckgl/jhtz/init/zt'
}
},
],[
{ {
label: '事务类型', label: '状态',
prop: 'swlxid', prop: 'zt',
span: 8, span: 8,
type: 'RelSelect', type: 'RelSelect',
typeConfig: { typeConfig: {
src: 'lxyl/rkgl/jhtz/init/swlx' src: 'wms/ckgl/jhtz/init/zt'
} }
},
],
[{
label: '事务类型',
prop: 'swlxid',
span: 8,
type: 'RelSelect',
typeConfig: {
src: 'lxyl/rkgl/jhtz/init/swlx'
} }
] }]
], ],
/* 默认启停用 */ /* 默认启停用 */
}
}
} },
} methods: {
gb(ctx) {
if (ctx.singleItem && ctx.singleItem.id) {
this.$prompt('请输入原因', '', {
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(({
value
}) => {
if (value) {
this.$post('wms/ckgl/jhtz/close/jhtzmx', {
id: ctx.singleItem.id,
gbyy:value
}).then(res => {
if (res.success) {
this.$success('操作成功')
ctx.refresh()
}
})
} else {
this.$warning('请输入关闭原因')
}
})
}, } else {
methods: { this.$warning('请选中一条数据')
jhtj(ctx){ }
if (ctx.singleItem && ctx.singleItem.id) { },
this.$confirm('是否继续操作, 是否继续?', '提示', { qxgb(ctx) {
confirmButtonText: '确定', if (ctx.singleItem && ctx.singleItem.id) {
cancelButtonText: '取消', this.$confirm('是否继续操作, 是否继续?', '提示', {
type: 'warning' confirmButtonText: '确定',
}).then(res => { cancelButtonText: '取消',
this.$post('lxyl/rkgl/jhtz/calcJhtzqd ', { type: 'warning'
id: ctx.singleItem.id }).then(res => {
}).then(res => { this.$post('wms/ckgl/jhtz/unclose/jhtzmx', {
if (res.success) { id: ctx.singleItem.id
this.$success('操作成功') }).then(res => {
ctx.onlyRefresh() if (res.success) {
} this.$success('操作成功')
}) ctx.refresh()
}) }
} else { })
this.$warning('请选中一条数据') })
} } else {
this.$warning('请选中一条数据')
}
},
jhtj(ctx) {
if (ctx.singleItem && ctx.singleItem.id) {
this.$confirm('是否继续操作, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(res => {
this.$post('lxyl/rkgl/jhtz/calcJhtzqd ', {
id: ctx.singleItem.id
}).then(res => {
if (res.success) {
this.$success('操作成功')
ctx.onlyRefresh()
}
})
})
} else {
this.$warning('请选中一条数据')
}
}, },
getRow(val){ getRow(val) {
this.$emit('getRow',val) this.$emit('getRow', val)
} }
}, },
components: { components: {
Edit Edit
} }
} }
</script> </script>
<style> <style>
......
<template> <template>
<BasePage :copy='false' addRename='新增' @getRow='getRow' class="min_full" style="height: 100%;" :config="config"> <BasePage :copy='false' addRename='新增' @getRow='getRow' class="min_full" style="height: 100%;" :config="config">
<template #dialog="ctx"> <template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 --> <!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template> </template>
<template #toolbar="ctx"> <template #toolbar="ctx">
<el-button @click="tjkw(ctx.basePage)" size='mini' type="primary">推荐库位</el-button> <el-button @click="tjkw(ctx.basePage)" size='mini' type="primary">推荐库位</el-button>
<el-button @click="qktjkw(ctx.basePage)" size='mini' type="primary">清空推荐库位</el-button> <el-button @click="qktjkw(ctx.basePage)" size='mini' type="primary">清空推荐库位</el-button>
<!-- <ImportButton @success="()=>{ <el-button @click="gb(ctx.basePage)" size='mini' type="primary">关闭</el-button>
<el-button @click="qxgb(ctx.basePage)" size='mini' type="primary">取消关闭</el-button>
<!-- <ImportButton @success="()=>{
ctx.basePage.refresh() ctx.basePage.refresh()
}" :url="'/wms/rkgl/rktz/import'" /> --> }" :url="'/wms/rkgl/rktz/import'" /> -->
</template> </template>
</BasePage> </BasePage>
</template> </template>
<script> <script>
import Edit from './edit.vue' import Edit from './edit.vue'
export default { export default {
data() { data() {
return { return {
config: { config: {
queryDetail: true, queryDetail: true,
/* 基本配置*/ /* 基本配置*/
url: 'lxyl/rkgl/sjtz', url: 'lxyl/rkgl/sjtz',
tableTitle: [{ tableTitle: [{
title: "上架单号", title: "上架单号",
field: "djid", field: "djid",
fieldType: "ftString", fieldType: "ftString",
width: 120 width: 120
}, },
{ {
title: "业务日期", title: "业务日期",
field: "ywrq", field: "ywrq",
fieldType: "ftDate" fieldType: "ftDate"
}, },
{ {
title: "仓库编码", title: "仓库编码",
field: "ckCode", field: "ckCode",
width: 140 width: 140
}, },
{ {
title: "仓库", title: "仓库",
field: "ckName", field: "ckName",
fieldType: "ftString", fieldType: "ftString",
width: 140, width: 140,
}, },
{ {
title: "库区", title: "库区",
field: "kqName", field: "kqName",
fieldType: "ftString", fieldType: "ftString",
width: 100, width: 100,
}, },
// { // {
// title: "库位", // title: "库位",
// field: "kwName", // field: "kwName",
// fieldType: "ftString", // fieldType: "ftString",
// width: 192, // width: 192,
// }, // },
{ {
title: "事务类型", title: "事务类型",
field: "swlxName", field: "swlxName",
fieldType: "ftString", fieldType: "ftString",
width: 100, width: 100,
}, },
{ {
title: "部门", title: "部门",
field: "bmName", field: "bmName",
fieldType: "ftString", fieldType: "ftString",
width: 100 width: 100
}, },
{ {
title: "上架人", title: "上架人",
field: "sjrName", field: "sjrName",
fieldType: "ftString", fieldType: "ftString",
width: 100 width: 100
}, },
{ {
title: "货主", title: "货主",
field: "hzName", field: "hzName",
fieldType: "ftString", fieldType: "ftString",
width: 100 width: 100
}, },
{ {
title: "单据来源", title: "单据来源",
field: "djly", field: "djly",
"transform": { "transform": {
"url": "wms/rkgl/sjtz/init/djly", "url": "wms/rkgl/sjtz/init/djly",
"label": "name", "label": "name",
"value": "id" "value": "id"
}, },
width: 80 width: 80
}, },
{ {
title: "来源单号", title: "来源单号",
field: "rktzDjid", field: "rktzDjid",
width: 140 width: 140
}, },
{ {
title: "来源单据号", title: "来源单据号",
field: "lydjDjid", field: "lydjDjid",
width: 140 width: 140
}, },
{ {
title: "状态", title: "状态",
field: "zt", field: "zt",
"transform": { "transform": {
"url": "wms/rkgl/sjtz/init/zt", "url": "wms/rkgl/sjtz/init/zt",
"label": "name", "label": "name",
"value": "id" "value": "id"
}, },
width: 60 width: 60
}, },
{ {
title: "备注", title: "备注",
field: "bz", field: "bz",
fieldType: "ftString", fieldType: "ftString",
width: 300 width: 300
}, },
{ {
title: "维护人", title: "维护人",
field: "whr", field: "whr",
fieldType: "ftString" fieldType: "ftString"
}, },
{ {
title: "维护时间", title: "维护时间",
field: "whsj", field: "whsj",
fieldType: "ftDateTime", fieldType: "ftDateTime",
hidden: true hidden: true
}, },
{ {
title: "创建人", title: "创建人",
field: "cjr", field: "cjr",
fieldType: "ftString" fieldType: "ftString"
}, },
{ {
title: "创建时间", title: "创建时间",
field: "cjsj", field: "cjsj",
fieldType: "ftDateTime", fieldType: "ftDateTime",
hidden: true hidden: true
}, },
], ],
queryParams: [ queryParams: [
[{ [{
label: '日期', label: '日期',
startProp: "start", startProp: "start",
endProp: "end", endProp: "end",
span: 8, span: 8,
type: 'RelDaterangeV2', type: 'RelDaterangeV2',
startValue: new Date().getTime() - 1000 * 60 * 60 * 24 * 30, startValue: new Date().getTime() - 1000 * 60 * 60 * 24 * 30,
endValue: new Date().getTime(), endValue: new Date().getTime(),
}, },
{ {
label: '来源单号', label: '来源单号',
prop: 'lydjDjid', prop: 'lydjDjid',
span: 8, span: 8,
type: 'input', type: 'input',
value: '' value: ''
}, },
{ {
label: '上架单号', label: '上架单号',
prop: 'djid', prop: 'djid',
span: 8, span: 8,
type: 'input', type: 'input',
value: '' value: ''
} }
],[ ],
[
{ {
label: '上架人', label: '上架人',
prop: 'sjrName', prop: 'sjrName',
span: 8, span: 8,
type: 'input', type: 'input',
value: '' value: ''
}, },
] ]
], ],
/* 默认启停用 */ /* 默认启停用 */
} }
} }
},
methods: {
gb(ctx) {
if (ctx.singleItem && ctx.singleItem.id) {
this.$prompt('请输入原因', '', {
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(({
value
}) => {
if (value) {
this.$post('wms/rkgl/sjtz/close/sjtzmx', {
id: ctx.singleItem.id,
gbyy:value
}).then(res => {
if (res.success) {
this.$success('操作成功')
ctx.refresh()
}
})
} else {
this.$warning('请输入关闭原因')
}
})
}, } else {
methods: { this.$warning('请选中一条数据')
qktjkw(ctx){ }
if(ctx.singleItem&&ctx.singleItem.id){ },
qxgb(ctx) {
if (ctx.singleItem && ctx.singleItem.id) {
this.$confirm('是否继续操作, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(res => {
this.$post('wms/rkgl/sjtz/unclose/sjtzmx', {
id: ctx.singleItem.id
}).then(res => {
if (res.success) {
this.$success('操作成功')
ctx.refresh()
}
})
})
} else {
this.$warning('请选中一条数据')
}
},
qktjkw(ctx) {
if (ctx.singleItem && ctx.singleItem.id) {
this.$confirm('是否继续该操作?', '提示', { this.$confirm('是否继续该操作?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(res=>{ }).then(res => {
this.$post('lxyl/rkgl/sjtz/cleanKw ',{ this.$post('lxyl/rkgl/sjtz/cleanKw ', {
id:ctx.singleItem.id id: ctx.singleItem.id
}).then(res=>{ }).then(res => {
if(res.success){ if (res.success) {
this.$success('操作成功') this.$success('操作成功')
ctx.refresh() ctx.refresh()
} }
}) })
}) })
}else{ } else {
this.$warning('请选中一条数据') this.$warning('请选中一条数据')
} }
}, },
tjkw(ctx){ tjkw(ctx) {
if(ctx.singleItem&&ctx.singleItem.id){ if (ctx.singleItem && ctx.singleItem.id) {
this.$confirm('是否继续?', '提示', { this.$confirm('是否继续?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(res=>{ }).then(res => {
this.$post('lxyl/rkgl/sjtz/calcKw',{ this.$post('lxyl/rkgl/sjtz/calcKw', {
id:ctx.singleItem.id id: ctx.singleItem.id
}).then(res=>{ }).then(res => {
if(res.success){ if (res.success) {
this.$success('操作成功') this.$success('操作成功')
this.$emit('sxmx') this.$emit('sxmx')
} }
}) })
}) })
}else{ } else {
this.$warning('请选择一条数据') this.$warning('请选择一条数据')
} }
}, },
getRow(val){ getRow(val) {
this.$emit('getRow',val) this.$emit('getRow', val)
} }
}, },
components: { components: {
Edit Edit
} }
} }
</script> </script>
<style> <style>
......
...@@ -98,7 +98,7 @@ ...@@ -98,7 +98,7 @@
field: "lydid", field: "lydid",
width: 200, width: 200,
formatter(a, b, c) { formatter(a, b, c) {
return a.kccjCode || a.ukcyhdCode return a.lydid||a.kccjCode || a.ukcyhdCode
} }
}, },
{ {
......
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