Browse Source

物料包装

master_hella_20240701
yufei0306 5 months ago
parent
commit
de6513d7dd
  1. 40
      src/views/wms/basicDataManage/itemManage/itempackage/index.vue
  2. 2
      src/views/wms/basicDataManage/itemManage/itempackage/itempackage.data.ts

40
src/views/wms/basicDataManage/itemManage/itempackage/index.vue

@ -52,6 +52,7 @@
:apiCreate="ItempackagingApi.createItempackaging"
@searchTableSuccess="searchTableSuccess"
:isBusiness="false"
@onEnter="onEnter"
/>
<!-- 详情 -->
@ -75,6 +76,10 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons'
import TableHead from '@/components/TableHead/src/TableHead.vue'
import ImportForm from '@/components/ImportForm/src/ImportForm.vue'
import Detail from '@/components/Detail/src/Detail.vue'
import * as ItembasicApi from '@/api/wms/itembasic'
import { Itembasic } from '../itembasic/itembasic.data'
import * as PackageunitApi from '@/api/wms/packageunit'
import { Packageunit } from '../packageunit/packageunit.data'
defineOptions({ name: 'Itempackaging' })
@ -205,6 +210,41 @@ const formsSuccess = async (formType, data) => {
basicFormRef.value.dialogVisible = false
getList()
}
const onEnter = async (field,value)=>{
console.log('onEnter',field,value)
if('itemCode'==field){
//
basicFormRef.value.opensearchTable('itemCode', 'code', '物料基础信息', Itembasic.allSchemas, ItembasicApi.getItembasicPage,[{
key: 'available',
value: 'TRUE',
action: '==',
isSearch: true,
isMainValue: false
},{
key: 'code',
value: value,
action: '==',
isSearch: true,
isMainValue: false
}])
}else if('packUnit'==field){
//
basicFormRef.value.opensearchTable('packUnit', 'code', '包装规格信息', Packageunit.allSchemas, PackageunitApi.getPackageunitPage,[{
key: 'available',
value: 'TRUE',
action: '==',
isSearch: true,
isMainValue: false
},{
key: 'code',
value: value,
action: '==',
isSearch: true,
isMainValue: false
}])
}
}
//
const searchTableSuccess = (formField, searchField, val, formRef) => {
nextTick(() => {

2
src/views/wms/basicDataManage/itemManage/itempackage/itempackage.data.ts

@ -23,6 +23,7 @@ export const Itempackaging = useCrudSchemas(reactive<CrudSchema[]>([
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
enterSearch: true, //可输入回车
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择物料代码', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段
@ -64,6 +65,7 @@ export const Itempackaging = useCrudSchemas(reactive<CrudSchema[]>([
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
enterSearch: true, //可输入回车
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择包装规格', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段

Loading…
Cancel
Save