货位信息页面调整
This commit is contained in:
parent
451adfd327
commit
7762e3bb4a
@ -62,3 +62,16 @@ export function delStorage(data: any) {
|
||||
data: data,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param data 获取仓库信息
|
||||
* @returns
|
||||
*/
|
||||
export function getLocation(data: any) {
|
||||
return request({
|
||||
url: '/api/api/wareHouse/getLocation',
|
||||
method: 'post',
|
||||
data: data,
|
||||
});
|
||||
}
|
@ -3,17 +3,30 @@
|
||||
<el-row class="page-search" justify="space-between" align="middle">
|
||||
<el-form ref="queryFormRef" :model="state.queryParams.params" :inline="true">
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="4">
|
||||
<el-col :span="6">
|
||||
<el-form-item label="组织" prop="erpFactory">
|
||||
<el-select v-model="queryParams.params.erpFactory" placeholder="下拉选择">
|
||||
<el-option v-for="item in state.ERPFactoryList" :key="item.ERPFACTORY" :label="item.DESCRIPTION"
|
||||
:value="item.ERPFACTORY" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="仓库编码" prop="params.erpLocation">
|
||||
<el-Input v-model="state.queryParams.params.erpLocation" placeholder="仓库编码查询" clearable/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="货位编码" prop="params.storageName">
|
||||
<el-Input v-model="state.queryParams.params.storageName" placeholder="货位编码查询" clearable/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="货位描述" prop="params.description">
|
||||
<el-Input v-model="state.queryParams.params.description" placeholder="货位描述查询" clearable/>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="货位名称" prop="params.description">
|
||||
<el-Input v-model="state.queryParams.params.description" placeholder="货位名称查询" clearable/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-col :span="6">
|
||||
<el-form-item label="货位属性" prop="params.storageUseType">
|
||||
<el-select
|
||||
size="small"
|
||||
@ -110,11 +123,20 @@
|
||||
<!-- 新增或编辑 -->
|
||||
<el-drawer :title="dialog.title" v-model="dialog.visible" @close="cancel" @opened="dialogOpend">
|
||||
<el-form ref="formDataRef" :model="formData" :rules="rules" label-position="top">
|
||||
<!-- <el-form-item label="组织编码" prop="erpFactory" v-if="dialog.type === 'add'">
|
||||
<el-input v-model="formData.erpFactory" placeholder="请输入组织编码" disabled/>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="仓库编码" prop="erpLocation" v-if="dialog.type === 'add'">
|
||||
<el-input v-model="formData.erpLocation" placeholder="请输入仓库编码" v-on:keyup.enter="erpLocationEnter"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="仓库名称" prop="erpLocationName" v-if="dialog.type === 'add'">
|
||||
<el-input v-model="formData.erpLocationName" placeholder="请输入仓库名称" disabled/>
|
||||
</el-form-item>
|
||||
<el-form-item label="货位编码" prop="storageName" v-if="dialog.type === 'add'">
|
||||
<el-input v-model="formData.storageName" placeholder="请输入货位编码" />
|
||||
</el-form-item>
|
||||
<el-form-item label="货位描述" prop="description">
|
||||
<el-input v-model="formData.description" placeholder="请输入货位描述" />
|
||||
<el-form-item label="货位名称" prop="description">
|
||||
<el-input v-model="formData.description" placeholder="请输入货位名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="货位属性" prop="storageUseType">
|
||||
<el-select
|
||||
@ -151,7 +173,7 @@ import { ElForm, ElMessageBox, ElTable } from "element-plus";
|
||||
import { BpelEvent, getQueryList } from '@/api/common'
|
||||
import { bTableHeight } from '@/composables/calcTableHeight';
|
||||
import { getORG } from '@/api/auth'
|
||||
import { createStorage, delStorage, editStorage, page } from '@/api/wareHouse'
|
||||
import { createStorage, delStorage, editStorage, page, getLocation } from '@/api/wareHouse'
|
||||
import { localStorage as ls } from "@/utils/storage";
|
||||
import { printStorage } from '@/api/label'
|
||||
|
||||
@ -178,14 +200,20 @@ const state = reactive({
|
||||
storageName: '',
|
||||
description: '',
|
||||
storageUseType: '',
|
||||
erpFactory: '',
|
||||
erpLocation: '',
|
||||
},
|
||||
pageNum: 1,
|
||||
pageSize: 10
|
||||
},
|
||||
formData: {
|
||||
siteName: 'SDK',
|
||||
createUser: localStorage.getItem('userName'),
|
||||
storageName: "",
|
||||
description: ""
|
||||
description: "",
|
||||
erpLocation: '',
|
||||
erpFactory: '',
|
||||
erpLocationName: ''
|
||||
} as any,
|
||||
dialog: {
|
||||
title: "新增货位",
|
||||
@ -194,7 +222,8 @@ const state = reactive({
|
||||
},
|
||||
rules: {
|
||||
storageName: [{ required: true, message: "请输入货位编码", trigger: "blur" }],
|
||||
description: [{ required: true, message: "请输入货位描述", trigger: "blur" }],
|
||||
description: [{ required: true, message: "请输入货位名称", trigger: "blur" }],
|
||||
erpLocation: [{ required: true, message: "请输入仓库编码", trigger: "blur" }],
|
||||
// storageUseType: [{ required: true, message: "请输入货位属性", trigger: "blur" }],
|
||||
},
|
||||
// 打印机 start
|
||||
@ -225,14 +254,19 @@ const {
|
||||
|
||||
onMounted(() => {
|
||||
materialTableConfig.value.column = [
|
||||
{ header: "组织编码", field: "erpFactory", hide: false },
|
||||
{ header: "组织名称", field: "orgName", hide: false },
|
||||
{ header: "仓库编码", field: "erpLocation", hide: false },
|
||||
{ header: "仓库名称", field: "erpLocationName", hide: false },
|
||||
{ header: "货位编码", field: "storageName", hide: false },
|
||||
{ header: "货位描述", field: "description", hide: false },
|
||||
{ header: "货位名称", field: "description", hide: false },
|
||||
{ header: "货位属性", field: "storageUseType", hide: false }
|
||||
]
|
||||
handleQuery();
|
||||
updateTableHeight();
|
||||
// 打印机
|
||||
getPRINTLIST();
|
||||
hangERPFactoryQuery();
|
||||
window.addEventListener('resize', handleResize);
|
||||
getStorageUseTypeList()
|
||||
})
|
||||
@ -431,4 +465,20 @@ function getStorageUseTypeList() {
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
function hangERPFactoryQuery() {
|
||||
getORG({ orgNo: null}).then((res: any) => {
|
||||
state.ERPFactoryList = res.resultObj
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
function erpLocationEnter() {
|
||||
getLocation({erpLocation: state.formData.erpLocation}).then((res: any) => {
|
||||
if(res.success && res.resultObj){
|
||||
state.formData.erpLocationName = res.resultObj.erpLocationName
|
||||
state.formData.erpFactory = res.resultObj.erpFactory
|
||||
}
|
||||
})
|
||||
}
|
||||
</script>
|
||||
|
Loading…
x
Reference in New Issue
Block a user