diff --git a/src/api/wms/itembasic/index.ts b/src/api/wms/itembasic/index.ts index efd0319f0..3cdb3ebd6 100644 --- a/src/api/wms/itembasic/index.ts +++ b/src/api/wms/itembasic/index.ts @@ -119,3 +119,7 @@ export const getItemListByCodes = async (params) => { return await request.get({ url: `/wms/itembasic/listByCodes`,params}) } +// 根据cood查询器具物料信息 +export const selectContainermanageItemCode = async (code: String) => { + return await request.get({ url: `/wms/itembasic/selectContainermanageItemCode`,code}) +} diff --git a/src/api/wms/productionitemcodeSpareitemcode/index.ts b/src/api/wms/productionitemcodeSpareitemcode/index.ts index b201b9e1e..69a32a030 100644 --- a/src/api/wms/productionitemcodeSpareitemcode/index.ts +++ b/src/api/wms/productionitemcodeSpareitemcode/index.ts @@ -24,7 +24,7 @@ export const getProductionitemcodeSpareitemcodeRelation = async (params) => { if (params.isSearch) { delete params.isSearch const data = {...params} - return await request.post({ url: '/wms/productionitemcode-spareitemcode/getRelationSeniorS', data }) + return await request.post({ url: '/wms/productionitemcode-spareitemcode/getRelationSenior', data }) } else { return await request.get({ url: `/wms/productionitemcode-spareitemcode/getRelation`, params }) } diff --git a/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue b/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue index ce621fe3f..5c2e536c8 100644 --- a/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue +++ b/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue @@ -62,6 +62,21 @@ :detailButtonIsShowAdd="true" :detailButtonIsShowDelete="true" /> + + + + @@ -77,7 +92,8 @@ 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 { ProductreceiptRequestLabel,ProductreceiptRequestLabelRules } from '../../../../productionManage/productreceipt/productreceiptRequestMain/productreceiptRequestMain.data' + defineOptions({ name: 'RelegateRequestMain' }) const message = useMessage() // 消息弹窗 @@ -89,7 +105,8 @@ const businessType = 'relegate' routeName.value = route.name const tableColumns = ref([...RelegateRequestMain.allSchemas.tableColumns, ...RelegateRequestDetail.allSchemas.tableMainColumns]) const isShowButton = ref(true) - +//创建标签 +const detailListTableColumns = ProductreceiptRequestLabel.allSchemas // 查询页面返回 const searchTableSuccess = (formField, searchField, val, formRef, type, row) => { nextTick(() => { @@ -108,22 +125,15 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) => newRow['inventoryStatus'] = item['inventoryStatus'] tableData.value.push(newRow) }) - } else if (formField == 'downItemCode') { - if(row['itemCode'] == val[0]['spareItemCode']){ - row['downItemCode'] = val[0]['productionItemCode'] //量产件 - }else{ - row['downItemCode'] = val[0]['spareItemCode'] //备件 + // if(row['itemCode'] == val[0]['spareItemCode']){ + // row['downItemCode'] = val[0]['productionItemCode'] //量产件 + // }else{ + // row['downItemCode'] = val[0]['spareItemCode'] //备件 - } - console.log(row['itemCode']); - // ItembasicApi.getItemListByCodes(row['itemCode']) - - // if(){ - // row['downItemCode'] = val[0]['productionItemCode'] - // }else if(){ - // row['downItemCode'] = val[0]['spareItemCode'] // } + console.log(row['itemCode']); + ItembasicApi.getItemListByCodes(row['itemCode']) } else if (formField == 'toLocationCode') { row['toLocationCode'] = val[0]['code'] } else { diff --git a/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/relegateRequestMain.data.ts b/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/relegateRequestMain.data.ts index 41bd576fb..a0310eebf 100644 --- a/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/relegateRequestMain.data.ts +++ b/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/relegateRequestMain.data.ts @@ -2,7 +2,6 @@ import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import { dateFormatter } from '@/utils/formatTime' import * as getRequestsettingApi from '@/api/wms/requestsetting/index' -import * as ItembasicApi from '@/api/wms/itembasic' import { Itembasic } from '@/views/wms/basicDataManage/itemManage/itembasic/itembasic.data' import {Warehouse} from "@/views/wms/basicDataManage/factoryModeling/warehouse/warehouse.data"; @@ -18,8 +17,6 @@ import * as ItempackageApi from '@/api/wms/itempackage' import { Itempackaging } from '@/views/wms/basicDataManage/itemManage/itempackage/itempackage.data' import * as ProductionitemcodeSpareitemcodeApi from '@/api/wms/productionitemcodeSpareitemcode' -import { ProductionitemcodeSpareitemcode } from '@/views/wms/basicDataManage/itemManage/productionitemcodeSpareitemcode/productionitemcodeSpareitemcode.data' -import * as confgiApi from '@/api/infra/config' // 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值 const queryParams = { pageSize:10, @@ -28,7 +25,6 @@ const queryParams = { } const data = await getRequestsettingApi.getRequestsettingPage(queryParams) const requestsettingData =data?.list[0]||{} - const confgiData = await confgiApi.queryByKey("relegateItemType") // 表单校验 export const RelegateRequestMainRules = reactive({ fromWarehouseCode: [required], @@ -343,7 +339,7 @@ export const RelegateRequestDetail = useCrudSchemas(reactive([ // value: 'TRUE', // isMainValue: false // } - ,{ + { message: '请选择从仓库代码!', key: 'fromWarehouseCode', value: 'fromWarehouseCode', @@ -355,24 +351,24 @@ export const RelegateRequestDetail = useCrudSchemas(reactive([ }, }, { - label: '降级物料代码', + label: '物料变更代码', field: 'downItemCode', sort: 'custom', form: { componentProps: { enterSearch: true, isSearchList: true, - searchListPlaceholder: '请选择降级物料代码', + searchListPlaceholder: '请选择物料代码', searchField: 'productionItemCode', searchTitle: '物料基础信息', - searchAllSchemas: ProductionitemcodeSpareitemcode.allSchemas, + searchAllSchemas: Itembasic.allSchemas, searchPage: ProductionitemcodeSpareitemcodeApi.getProductionitemcodeSpareitemcodeRelation, searchCondition: [{ key: 'available', value: 'TRUE', isMainValue: false },{ - key: 'itemCode', + key: 'code', value: 'itemCode', isTableRowValue: true, isMainValue:false @@ -389,10 +385,10 @@ export const RelegateRequestDetail = useCrudSchemas(reactive([ }, tableForm:{ isInpuFocusShow: true, - searchListPlaceholder: '请选择降级物料代码', // 输入框占位文本 + searchListPlaceholder: '请选择物料代码', // 输入框占位文本 searchField: 'productionItemCode', // 查询弹窗赋值字段 searchTitle: '物料基础信息', // 查询弹窗标题 - searchAllSchemas: ProductionitemcodeSpareitemcode.allSchemas, // 查询弹窗所需类 + searchAllSchemas: Itembasic.allSchemas, // 查询弹窗所需类 searchPage: ProductionitemcodeSpareitemcodeApi.getProductionitemcodeSpareitemcodeRelation, // 查询弹窗所需分页方法 searchCondition:[ { @@ -400,7 +396,7 @@ export const RelegateRequestDetail = useCrudSchemas(reactive([ value: 'TRUE', isMainValue: false },{ - key: 'itemCode', + key: 'code', value: 'itemCode', isTableRowValue: true, isMainValue:false