From 254ec8aaf9d748054c07018a64f448c9d5b83f45 Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Mon, 15 Jan 2024 13:07:11 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=87=E8=B4=AD=E9=80=80=E8=B4=A7=E7=94=B3?= =?UTF-8?q?=E8=AF=B7=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../purchasereturnRequestMain/index.vue | 49 ++- .../purchasereturnRequestMain.data.ts | 371 +++++++----------- 2 files changed, 184 insertions(+), 236 deletions(-) diff --git a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue index b60ff6d55..39b5b0687 100644 --- a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue @@ -125,13 +125,6 @@ const updataTableColumns = (val) => { // 查询页面返回 const searchTableSuccess = (formField, searchField, val, formRef, type, row) => { - console.log("formField",formField) - console.log("searchField",searchField) - console.log("val",val) - console.log("formRef",formRef) - console.log("type",row) - - nextTick(() => { if (type == 'tableForm') { // 明细查询页赋值 @@ -190,6 +183,7 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) => item.batch = item.toBatch item.packingNumber = item.toPackingNumber item.containerNumber = item.toContainerNumber + item.containerNumber = item.toContainerNumber item.toLocationGroupCode = null item.toWarehouseCode = null item.toLocationTypes = null @@ -230,7 +224,46 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) => const searchTableSuccessDetail = (formField, searchField, val, formRef) => { nextTick(() => { const setV = {} - setV[formField] = val[0][searchField] + if(formField == 'poLine'){ + console.log(val) + setV['poLine'] = val[0]['poLine'] + setV['poNumber'] = val[0]['poNumber'] + setV['itemCode'] = val[0]['itemCode'] + setV['itemName'] = val[0]['itemName'] + setV['itemDesc1'] = val[0]['itemDesc1'] + setV['itemDesc2'] = val[0]['itemDesc2'] + setV['batch'] = val[0]['toBatch'] + setV['altBatch'] = val[0]['altBatch'] + setV['packingNumber'] = val[0]['toPackingNumber'] + setV['containerNumber'] = val[0]['toContainerNumber'] + setV['qty'] = val[0]['qty'] + setV['uom'] = val[0]['uom'] + setV['supplierQty'] = val[0]['supplierQty'] + setV['supplierUom'] = val[0]['supplierUom'] + setV['inventoryStatus'] = val[0]['inventoryStatus'] + setV['fromLocationCode'] = val[0]['locationCode'] + setV['toLocationCode'] = null + setV['fromLocationGroupCode'] = val[0]['locationGroupCode'] + setV['toLocationGroupCode'] = null + setV['toWarehouseCode'] = null + setV['toLocationTypes'] = null + setV['fromAreaCode'] = val[0]['areaCode'] + setV['toAreaCode'] = val[0]['toAreaCode'] + setV['fromQwnerCode'] = val[0]['fromQwnerCode'] + setV['toOwnerCode'] = val[0]['toOwnerCode'] + setV['arriveDate'] = val[0]['arriveDate'] + setV['produceDate'] = val[0]['produceDate'] + setV['expireDate'] = val[0]['expireDate'] + setV['convertRate'] = val[0]['convertRate'] + setV['visualInspectResult'] = val[0]['visualInspectResult'] + setV['visualInspectPhotos'] = val[0]['visualInspectPhotos'] + setV['failedReason'] = val[0]['failedReason'] + setV['singlePrice'] = val[0]['singlePrice'] + setV['amount'] = val[0]['amount'] + setV['projectCode'] = val[0]['projectCode'] + }else { + setV[formField] = val[0][searchField] + } formRef.setValues(setV) }) } diff --git a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/purchasereturnRequestMain.data.ts b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/purchasereturnRequestMain.data.ts index 7a27b1bcc..2102f5cea 100644 --- a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/purchasereturnRequestMain.data.ts +++ b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/purchasereturnRequestMain.data.ts @@ -3,9 +3,15 @@ import { dateFormatter } from '@/utils/formatTime' const { t } = useI18n() // 国际化 import * as getRequestsettingApi from '@/api/wms/requestsetting/index' import * as PurchasereceiptRecordMainApi from '@/api/wms/purchasereceiptRecordMain' -import { PurchasereceiptRecordMain } from '../../purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data' +import { + PurchasereceiptRecordDetail, + PurchasereceiptRecordMain +} from '../../purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data' import * as BalanceApi from '@/api/wms/balance' import { Balance } from '@/views/wms/inventoryManage/balance/balance.data' +import * as PurchasereceiptRecordDetailApi from '@/api/wms/purchasereceiptRecordDetail' + + // 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值 const queryParams = { @@ -18,6 +24,11 @@ const queryParams = { // 获取当前操作人的部门 import { useUserStore } from '@/store/modules/user' +import { + PurchaseDetail +} from "@/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data"; +import * as PurchaseDetailApi from "@/api/wms/purchaseDetail"; +import {getPurchasereceiptRecordDetailPage} from "@/api/wms/purchasereceiptRecordDetail"; const userStore = useUserStore() const userDept = userStore.userSelfInfo.dept @@ -465,6 +476,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -476,7 +492,27 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true - } + }, + form: { + // labelMessage: '信息提示说明!!!', + componentProps: { + isSearchList: true, + searchListPlaceholder: '请选择订单行', + searchField: 'poLine', + searchTitle: '采购收货记录信息', + searchAllSchemas: PurchasereceiptRecordDetail.allSchemas, + searchPage: PurchasereceiptRecordDetailApi.getPurchasereceiptRecordDetailPage, + searchCondition: [{ + key: 'number', + value: 'purchaseReceiptRecordNumber', + isMainValue: true + },{ + key: 'available', + value: 'TRUE', + isMainValue: false + }] + } + }, }, { label: '物品代码', @@ -486,19 +522,13 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive width: 150 }, tableForm:{ - disabled:true, - isInpuFocusShow: true, - earchListPlaceholder: '请选择包装号', - searchField: 'packingNumber', - searchTitle: '库存余额信息', - searchAllSchemas: Balance.allSchemas, - searchPage: BalanceApi.getBalancePageReturn, - searchCondition:[{ - key: 'workshopCode', - value: 'workshopCode', - isMainValue: true - }] + disabled:true }, + form: { + componentProps:{ + disabled:true + } + } }, { label: '物品名称', @@ -509,6 +539,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -520,6 +555,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -531,6 +571,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, // { @@ -553,6 +598,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -564,6 +614,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -575,6 +630,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -586,6 +646,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -597,6 +662,9 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, form: { component: 'InputNumber', + componentProps:{ + disabled:true + } }, tableForm:{ disabled:true, @@ -618,71 +686,13 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive tableForm:{ disabled:true, type: 'Select', - } - }, - - { - label: '标包数量', - field: 'stdPackQty', - sort: 'custom', - table: { - width: 150 - }, - form: { - component: 'InputNumber', - }, - tableForm:{ - disabled:true - } - }, - { - label: '标包单位', - field: 'stdPackUnit', - dictType: DICT_TYPE.PACK_UNIT, - dictClass: 'string', - isSearch: true, - isTable: true, - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true, - type: 'Select', - } - }, - - { - label: '供应商计量数量', - field: 'supplierQty', - sort: 'custom', - table: { - width: 150 }, form: { - component: 'InputNumber', - }, - tableForm:{ - disabled:true - } - }, - { - label: '供应商计量单位', - field: 'supplierUom', - dictType: DICT_TYPE.UOM, - dictClass: 'string', - isSearch: true, - isTable: true, - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true, - type: 'Select', + componentProps:{ + disabled:true + } } }, - { label: '库存状态', field: 'inventoryStatus', @@ -697,17 +707,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive tableForm:{ disabled:true, type: 'Select', - } - }, - { - label: '从库位代码', - field: 'fromLocationCode', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -719,51 +723,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true - } - }, - { - label: '从库位组代码', - field: 'fromLocationGroupCode', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true - } - }, - { - label: '到库位组代码', - field: 'toLocationGroupCode', - sort: 'custom', - table: { - width: 150 - }, - isTableForm:false, - tableForm:{ - disabled:true - } - }, - { - label: '从库区代码', - field: 'fromAreaCodes', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true - } - }, - { - label: '到库区代码', - field: 'toAreaCodes', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -775,6 +739,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -786,6 +755,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true + }, + form: { + componentProps:{ + disabled:true + } } }, { @@ -802,6 +776,7 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive form: { component: 'DatePicker', componentProps: { + disabled: true, type: 'datetime', dateFormat: 'YYYY-MM-DD HH:mm:ss', valueFormat: 'x', @@ -828,6 +803,7 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive form: { component: 'DatePicker', componentProps: { + disabled: true, type: 'datetime', dateFormat: 'YYYY-MM-DD HH:mm:ss', valueFormat: 'x', @@ -854,6 +830,7 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive form: { component: 'DatePicker', componentProps: { + disabled: true, type: 'datetime', format: 'YYYY-MM-DD HH:mm:ss', valueFormat: 'x', @@ -866,86 +843,6 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive valueFormat: 'x', } }, - { - label: '转换率', - field: 'convertRate', - sort: 'custom', - table: { - width: 150 - }, - form: { - component: 'InputNumber', - }, - tableForm:{ - disabled:true - } - }, - { - label: '目检结果', - field: 'visualInspectResult', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true - } - }, - { - label: '目检照片', - field: 'visualInspectPhotos', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true - } - }, - { - label: '不合格原因', - field: 'reason', - dictType: DICT_TYPE.PURCHASE_RETURN_REASON, - dictClass: 'string', - isSearch: true, - isTable: true, - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled: false, - type: 'Select' - } - }, - { - label: '单价', - field: 'singlePrice', - sort: 'custom', - table: { - width: 150 - }, - form: { - component: 'InputNumber', - }, - tableForm:{ - disabled:true - } - }, - { - label: '金额', - field: 'amount', - sort: 'custom', - table: { - width: 150 - }, - form: { - component: 'InputNumber', - }, - tableForm:{ - disabled:true - } - }, { label: '任务明细ID', field: 'jobDetailId', @@ -957,7 +854,12 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive disabled:true }, isTableForm:false, - isForm:false + isForm:false, + form: { + componentProps:{ + disabled:true + } + }, }, { @@ -969,7 +871,12 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true - } + }, + form: { + componentProps:{ + disabled:true + } + }, }, { @@ -985,19 +892,6 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive isTableForm:false, isForm:false }, - { - label: '代码', - field: 'code', - sort: 'custom', - table: { - width: 150 - }, - tableForm:{ - disabled:true - }, - isTableForm:false, - isForm:false - }, { label: '接口类型', field: 'interfaceType', @@ -1013,7 +907,12 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive disabled:true }, isForm:false, - isTableForm:false + isTableForm:false, + form: { + componentProps:{ + disabled:true + } + }, }, { label: '备注', @@ -1024,7 +923,12 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, tableForm:{ disabled:true - } + }, + form: { + componentProps:{ + disabled:true + } + }, }, { label: '创建时间', @@ -1063,6 +967,17 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive }, isTableForm:false, isForm:false + }, + { + label: '操作', + field: 'action', + isDetail: false, + isForm: false , + table: { + width: 150, + fixed: 'right' + }, + isTableForm:false, } ]))