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

库区

parent 96d0a882
<template> <template>
<BasePage :setFirstCurrent='false' class="min_full" :config="config"> <BasePage :setFirstCurrent='false' class="min_full" :config="config">
<template #dialog="ctx"> <template #dialog="ctx">
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 --> <!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
<Detail :app='ctx.basePage' v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='查看详情'" /> <Detail :app='ctx.basePage' v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='查看详情'" />
<Kwbg :app='ctx.basePage' v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='库位变更'" /> <Kwbg :app='ctx.basePage' v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='库位变更'" />
</template> </template>
<template #toolbar="ctx"> <template #toolbar="ctx">
<ImportButton @success="()=>{ <ImportButton @success="()=>{
ctx.basePage.refresh() ctx.basePage.refresh()
}" :url="'lxyl/jcsj/kw/import'" /> }" :url="'lxyl/jcsj/kw/import'" />
<el-button style="margin-left: 10px;" @click="qkkw(ctx.basePage)" size='mini' <el-button style="margin-left: 10px;" @click="qkkw(ctx.basePage)" size='mini' type="primary">清空库位</el-button>
type="primary">清空库位</el-button> <el-button style="margin-left: 10px;" @click="ckxq(ctx.basePage)" size='mini' type="primary">查看详情</el-button>
<el-button style="margin-left: 10px;" @click="ckxq(ctx.basePage)" size='mini' <!-- <el-button style="margin-left: 10px;" @click="kwbg(ctx.basePage)" size='mini'
type="primary">查看详情</el-button>
<!-- <el-button style="margin-left: 10px;" @click="kwbg(ctx.basePage)" size='mini'
type="primary">库位变更</el-button> --> type="primary">库位变更</el-button> -->
</template> </template>
</BasePage> </BasePage>
</template> </template>
<script> <script>
import Edit from './edit.vue' import Edit from './edit.vue'
import Detail from './detail.vue' import Detail from './detail.vue'
import Kwbg from './kwbg.vue' import Kwbg from './kwbg.vue'
export default { export default {
data() { data() {
return { return {
config: { config: {
/* 基本配置*/ /* 基本配置*/
url: 'wms/jcsj/kw', url: 'wms/jcsj/kw',
tableTitle: [{ tableTitle: [{
title: "状态", title: "状态",
field: "zt", field: "zt",
width: 80, width: 80,
"transform": { "transform": {
"url": "wms/jcsj/kw/init/zt", "url": "wms/jcsj/kw/init/zt",
"label": "name", "label": "name",
"value": "id" "value": "id"
} }
}, },
{ {
title: "库位编码", title: "库位编码",
field: "code", field: "code",
width: 120 width: 120
}, },
{ {
title: "库位", title: "库位",
field: "name", field: "name",
width: 120 width: 120
}, },
{ {
title: "仓库", title: "仓库",
field: "ckName", field: "ckName",
with: 120, with: 120,
}, },
{ {
title: "库区", title: "库区",
field: "kqName", field: "kqName",
width: 140, width: 140,
}, },
{ {
title: "货架", title: "货架",
field: "hjName", field: "hjName",
width: 140, width: 140,
}, },
{ {
title: "排", title: "排",
field: "kwx", field: "kwx",
width: 80, width: 80,
}, { }, {
title: "列", title: "列",
field: "kwy", field: "kwy",
width: 80, width: 80,
}, { }, {
title: "层", title: "层",
field: "kwz", field: "kwz",
width: 80, width: 80,
}, },
{ {
title: "存储状态", title: "存储状态",
field: "kczt", field: "kczt",
"transform": { "transform": {
"url": "wms/jcsj/kw/init/kczt ", "url": "wms/jcsj/kw/init/kczt ",
"label": "name", "label": "name",
"value": "id" "value": "id"
} }
}, },
{ {
title: "外层库位", title: "外层库位",
field: "wcKwCode", field: "wcKwCode",
width: 120, width: 120,
}, },
{ {
title: "ABC", title: "ABC",
field: "abc", field: "abc",
width: 170 width: 170
}, },
{ {
title: "停用日期", title: "停用日期",
field: "tyrq", field: "tyrq",
fieldType: 'ftDate' fieldType: 'ftDate'
}, },
{ {
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'
}, },
{ {
title: "创建人", title: "创建人",
field: "cjr", field: "cjr",
hidden: true hidden: true
}, },
{ {
title: "创建时间", title: "创建时间",
field: "cjsj", field: "cjsj",
fieldType: 'ftDateTime', fieldType: 'ftDateTime',
hidden: true hidden: true
} }
], ],
queryParams: [ queryParams: [
[{ [{
"label": "仓库", "label": "仓库",
"prop": "ckid", "prop": "ckid",
"span": 6, "span": 6,
"type": "RelSelect", "type": "RelSelect",
"value": "", "value": "",
"typeConfig": { "typeConfig": {
"src": "lxyl/jcsj/uck/ck/queryCjckid", "src": "lxyl/jcsj/uck/ck/queryCjckid",
"match": { "match": {
"value": "id", "value": "id",
"label": "name" "label": "name"
} }
} }
}, },
{ {
"label": "库位信息", label: '库区',
"prop": "kwInfo", prop: 'kqid',
"span": 6, span: 6,
"type": "input", type: 'RelSelect',
"value": "", typeConfig: {
}, src: "wms/jcsj/kq/query",
linkage: true,
linkParams: ['ckid']
},
},
{ {
"label": "货架", "label": "库位信息",
"prop": "hjid", "prop": "kwInfo",
"span": 6, "span": 6,
"type": "RelSelect", "type": "input",
"value": "", "value": "",
"typeConfig": {
"src": "wms/jcsj/kw/init/hj",
}
}, },
{ {
"label": "状态", "label": "货架",
"prop": "zt", "prop": "hjid",
"span": 6, "span": 6,
"type": "RelSelect", "type": "RelSelect",
"value": "", "value": "",
"typeConfig": { "typeConfig": {
"src": "wms/jcsj/kw/init/zt", "src": "wms/jcsj/kw/init/hj",
} }
} },
],[ ],
[
{
"label": "状态",
"prop": "zt",
"span": 6,
"type": "RelSelect",
"value": "",
"typeConfig": {
"src": "wms/jcsj/kw/init/zt",
}
},
{ {
"label": "存储状态", "label": "存储状态",
"prop": "kczt", "prop": "kczt",
"span": 6, "span": 6,
"type": "RelSelect", "type": "RelSelect",
"value": "", "value": "",
"typeConfig": { "typeConfig": {
"src": "wms/jcsj/kw/init/kczt", "src": "wms/jcsj/kw/init/kczt",
} }
}, }, ]
] ],
], /* 默认启停用 */
/* 默认启停用 */ showqt: true,
showqt: true, }
} }
}
}, },
methods: { methods: {
kwbg(ctx){ kwbg(ctx) {
if (ctx.singleItem && ctx.singleItem.id) { if (ctx.singleItem && ctx.singleItem.id) {
ctx.DialogWidth = '30vw' ctx.DialogWidth = '30vw'
ctx.DialogTitle = '库位变更' ctx.DialogTitle = '库位变更'
ctx.showDialog = true ctx.showDialog = true
} else { } else {
this.$warning('请选中一条数据') this.$warning('请选中一条数据')
} }
}, },
qkkw(ctx) { qkkw(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('wms/jcsj/kw/clean', { this.$post('wms/jcsj/kw/clean', {
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('请选中一条数据')
} }
}, },
ckxq(ctx) { ckxq(ctx) {
if (ctx.singleItem && ctx.singleItem.id) { if (ctx.singleItem && ctx.singleItem.id) {
ctx.DialogWidth = '80vw' ctx.DialogWidth = '80vw'
ctx.DialogTitle = '查看详情' ctx.DialogTitle = '查看详情'
ctx.showDialog = true ctx.showDialog = true
} else { } else {
this.$warning('请选中一条数据') this.$warning('请选中一条数据')
} }
} }
/* 示例*/ /* 示例*/
// demo(basePage){ // demo(basePage){
// } // }
}, },
components: { components: {
Edit, Edit,
Detail, Detail,
// Kwbg // Kwbg
} }
} }
</script> </script>
<style> <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