Browse Source

采购退货申请修改

master
zhaoxuebing 10 months ago
parent
commit
254ec8aaf9
  1. 47
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue
  2. 347
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/purchasereturnRequestMain.data.ts

47
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 = {}
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)
})
}

347
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<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -476,8 +492,28 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
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: '物品代码',
field: 'itemCode',
@ -486,19 +522,13 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
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<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -520,6 +555,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -531,6 +571,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
// {
@ -553,6 +598,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -564,6 +614,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -575,6 +630,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -586,6 +646,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -597,6 +662,9 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
form: {
component: 'InputNumber',
componentProps:{
disabled:true
}
},
tableForm:{
disabled:true,
@ -618,71 +686,13 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
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:{
componentProps:{
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',
}
},
{
label: '库存状态',
field: 'inventoryStatus',
@ -697,18 +707,12 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
tableForm:{
disabled:true,
type: 'Select',
}
},
{
label: '从库位代码',
field: 'fromLocationCode',
sort: 'custom',
table: {
width: 150
},
tableForm:{
form: {
componentProps:{
disabled:true
}
}
},
{
label: '到库位代码',
@ -719,62 +723,27 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
}
},
{
label: '从库位组代码',
field: 'fromLocationGroupCode',
sort: 'custom',
table: {
width: 150
},
tableForm:{
form: {
componentProps:{
disabled:true
}
},
{
label: '到库位组代码',
field: 'toLocationGroupCode',
sort: 'custom',
table: {
width: 150
},
isTableForm:false,
tableForm:{
disabled:true
}
},
{
label: '从库区代码',
field: 'fromAreaCodes',
label: '从货主代码',
field: 'fromOwnerCode',
sort: 'custom',
table: {
width: 150
},
tableForm:{
disabled:true
}
},
{
label: '到库区代码',
field: 'toAreaCodes',
sort: 'custom',
table: {
width: 150
},
tableForm:{
form: {
componentProps:{
disabled:true
}
},
{
label: '从货主代码',
field: 'fromOwnerCode',
sort: 'custom',
table: {
width: 150
},
tableForm:{
disabled:true
}
},
{
@ -786,6 +755,11 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
}
},
{
@ -802,6 +776,7 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
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<CrudSchema[]>
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<CrudSchema[]>
form: {
component: 'DatePicker',
componentProps: {
disabled: true,
type: 'datetime',
format: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
@ -867,97 +844,22 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
}
},
{
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',
label: '任务明细ID',
field: 'jobDetailId',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
},
tableForm:{
disabled:true
}
},
{
label: '金额',
field: 'amount',
sort: 'custom',
table: {
width: 150
},
isTableForm:false,
isForm:false,
form: {
component: 'InputNumber',
},
tableForm:{
componentProps:{
disabled:true
}
},
{
label: '任务明细ID',
field: 'jobDetailId',
sort: 'custom',
table: {
width: 150
},
tableForm:{
disabled:true
},
isTableForm:false,
isForm:false
},
{
@ -969,8 +871,13 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
},
},
{
label: '单据号',
@ -985,19 +892,6 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
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<CrudSchema[]>
disabled:true
},
isForm:false,
isTableForm:false
isTableForm:false,
form: {
componentProps:{
disabled:true
}
},
},
{
label: '备注',
@ -1024,8 +923,13 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
tableForm:{
disabled:true
},
form: {
componentProps:{
disabled:true
}
},
},
{
label: '创建时间',
field: 'createTime',
@ -1063,6 +967,17 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
},
isTableForm:false,
isForm:false
},
{
label: '操作',
field: 'action',
isDetail: false,
isForm: false ,
table: {
width: 150,
fixed: 'right'
},
isTableForm:false,
}
]))

Loading…
Cancel
Save