|
@ -43,120 +43,10 @@ const userDept = userStore.userSelfInfo.dept |
|
|
userDept.id = userDept.id.toString() |
|
|
userDept.id = userDept.id.toString() |
|
|
const userDeptArray: any = [userDept] |
|
|
const userDeptArray: any = [userDept] |
|
|
|
|
|
|
|
|
// 采购收货记录展示列
|
|
|
|
|
|
export const PurchasereceiptRecordMain1 = useCrudSchemas( |
|
|
|
|
|
reactive<CrudSchema[]>([ |
|
|
|
|
|
{ |
|
|
|
|
|
label: '物料代码', |
|
|
|
|
|
field: 'itemCode', |
|
|
|
|
|
fixed: 'left', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
isSearch: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '采购收货记录单号', |
|
|
|
|
|
field: 'number', |
|
|
|
|
|
fixed: 'left', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 200 |
|
|
|
|
|
}, |
|
|
|
|
|
isSearch: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '发货单号', |
|
|
|
|
|
field: 'asnNumber', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 180 |
|
|
|
|
|
}, |
|
|
|
|
|
sortTableDefault: 2, |
|
|
|
|
|
isSearch: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '采购订单号', |
|
|
|
|
|
field: 'poNumber', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
isSearch: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '订单行', |
|
|
|
|
|
field: 'poLine', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
{ |
|
|
|
|
|
label: '物料名称', |
|
|
|
|
|
field: 'itemName', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '批次', // 实际是子表的从批次,为了不影响页面,单独放上面
|
|
|
|
|
|
field: 'fromBatch', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
isForm: false, |
|
|
|
|
|
isTableForm: false, |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '计量单位', |
|
|
|
|
|
field: 'uom', |
|
|
|
|
|
dictType: DICT_TYPE.UOM, |
|
|
|
|
|
dictClass: 'string', |
|
|
|
|
|
isTable: true, |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
// {
|
|
|
|
|
|
// label: '包装规格',
|
|
|
|
|
|
// field: 'packUnit',
|
|
|
|
|
|
// dictClass: 'string',
|
|
|
|
|
|
// isTable: true,
|
|
|
|
|
|
// sort: 'custom',
|
|
|
|
|
|
// table: {
|
|
|
|
|
|
// width: 150
|
|
|
|
|
|
// },
|
|
|
|
|
|
// },
|
|
|
|
|
|
// {
|
|
|
|
|
|
// label: '从库位代码',
|
|
|
|
|
|
// field: 'fromLocationCode',
|
|
|
|
|
|
// sort: 'custom',
|
|
|
|
|
|
// table: {
|
|
|
|
|
|
// width: 150
|
|
|
|
|
|
// },
|
|
|
|
|
|
//
|
|
|
|
|
|
// },
|
|
|
|
|
|
{ |
|
|
|
|
|
label: '到库位代码', |
|
|
|
|
|
field: 'toLocationCode', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
]) |
|
|
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* @returns {Array} 采购退货申请主表 |
|
|
* @returns {Array} 采购退货申请主表 |
|
|
*/ |
|
|
*/ |
|
|
export const PurchasereturnRequestMain = useCrudSchemas( |
|
|
export const PurchasereturnRequestMainNew = useCrudSchemas( |
|
|
reactive<CrudSchema[]>([ |
|
|
reactive<CrudSchema[]>([ |
|
|
{ |
|
|
{ |
|
|
label: '物料代码', |
|
|
label: '物料代码', |
|
@ -431,9 +321,53 @@ export const PurchasereturnRequestMain = useCrudSchemas( |
|
|
} |
|
|
} |
|
|
]) |
|
|
]) |
|
|
) |
|
|
) |
|
|
|
|
|
//表单校验
|
|
|
|
|
|
export const PurchasereturnRequestMainRulesNew = reactive({ |
|
|
|
|
|
supplierCode: [ |
|
|
|
|
|
{ required: true, message: '请输入供应商代码', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
dueTime: [ |
|
|
|
|
|
{ required: true, message: '请选择截止时间', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
// purchaseReceiptRecordNumber: [
|
|
|
|
|
|
// { required: true, message: '请输入采购收货记录单号', trigger: 'blur' }
|
|
|
|
|
|
// ],
|
|
|
|
|
|
carrierCode: [ |
|
|
|
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' }, |
|
|
|
|
|
], |
|
|
|
|
|
vehiclePlateNumber: [ |
|
|
|
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' }, |
|
|
|
|
|
], |
|
|
|
|
|
remark: [ |
|
|
|
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
fromWarehouseCode: [ |
|
|
|
|
|
{ required: true, message: '请输入从仓库代码', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
fromAreaTypes: [ |
|
|
|
|
|
{ required: true, message: '请选择从库区类型范围', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
departmentCode: [ |
|
|
|
|
|
{ required: true, message: '请输入部门', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
autoCommit: [ |
|
|
|
|
|
{ required: true, message: '请选择是否自动提交', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
autoAgree: [ |
|
|
|
|
|
{ required: true, message: '请选择是否自动通过', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
autoExecute: [ |
|
|
|
|
|
{ required: true, message: '请选择是否自动执行', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
directCreateRecord: [ |
|
|
|
|
|
{ required: true, message: '请选择是否跳过任务直接生成记录', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
businessType: [ |
|
|
|
|
|
{ required: true, message: '请输入业务类型', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
export const PurchasereturnPurchasereceiptRecordNew = useCrudSchemas( |
|
|
export const PurchasereturnPurchasereceiptRecord = useCrudSchemas( |
|
|
|
|
|
reactive<CrudSchema[]>([ |
|
|
reactive<CrudSchema[]>([ |
|
|
{ |
|
|
{ |
|
|
label: '收货日期', |
|
|
label: '收货日期', |
|
@ -556,56 +490,12 @@ export const PurchasereturnPurchasereceiptRecord = useCrudSchemas( |
|
|
]) |
|
|
]) |
|
|
) |
|
|
) |
|
|
|
|
|
|
|
|
//表单校验
|
|
|
|
|
|
export const PurchasereturnRequestMainRules = reactive({ |
|
|
|
|
|
supplierCode: [ |
|
|
|
|
|
{ required: true, message: '请输入供应商代码', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
dueTime: [ |
|
|
|
|
|
{ required: true, message: '请选择截止时间', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
// purchaseReceiptRecordNumber: [
|
|
|
|
|
|
// { required: true, message: '请输入采购收货记录单号', trigger: 'blur' }
|
|
|
|
|
|
// ],
|
|
|
|
|
|
carrierCode: [ |
|
|
|
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' }, |
|
|
|
|
|
], |
|
|
|
|
|
vehiclePlateNumber: [ |
|
|
|
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' }, |
|
|
|
|
|
], |
|
|
|
|
|
remark: [ |
|
|
|
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
fromWarehouseCode: [ |
|
|
|
|
|
{ required: true, message: '请输入从仓库代码', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
fromAreaTypes: [ |
|
|
|
|
|
{ required: true, message: '请选择从库区类型范围', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
departmentCode: [ |
|
|
|
|
|
{ required: true, message: '请输入部门', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
autoCommit: [ |
|
|
|
|
|
{ required: true, message: '请选择是否自动提交', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
autoAgree: [ |
|
|
|
|
|
{ required: true, message: '请选择是否自动通过', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
autoExecute: [ |
|
|
|
|
|
{ required: true, message: '请选择是否自动执行', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
directCreateRecord: [ |
|
|
|
|
|
{ required: true, message: '请选择是否跳过任务直接生成记录', trigger: 'change' } |
|
|
|
|
|
], |
|
|
|
|
|
businessType: [ |
|
|
|
|
|
{ required: true, message: '请输入业务类型', trigger: 'blur' } |
|
|
|
|
|
], |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* @returns {Array} 采购退货申请子表 |
|
|
* @returns {Array} 采购退货申请子表 |
|
|
*/ |
|
|
*/ |
|
|
export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>([ |
|
|
export const PurchasereturnRequestDetailNew = useCrudSchemas(reactive<CrudSchema[]>([ |
|
|
{ |
|
|
{ |
|
|
label: '批次', |
|
|
label: '批次', |
|
|
field: 'batch', |
|
|
field: 'batch', |
|
@ -731,264 +621,7 @@ export const PurchasereturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]> |
|
|
])) |
|
|
])) |
|
|
|
|
|
|
|
|
//表单校验
|
|
|
//表单校验
|
|
|
export const PurchasereturnRequestDetailRules = reactive({ |
|
|
export const PurchasereturnRequestDetailRulesNew = reactive({ |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
export const PurchasereReturnRequestDetailLabel = useCrudSchemas(reactive<CrudSchema[]>([ |
|
|
|
|
|
{ |
|
|
|
|
|
label: '物料代码', |
|
|
|
|
|
field: 'itemCode', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm:{ |
|
|
|
|
|
disabled: true |
|
|
|
|
|
}, |
|
|
|
|
|
form: { |
|
|
|
|
|
componentProps: { |
|
|
|
|
|
disabled: true |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '物料名称', |
|
|
|
|
|
field: 'itemName', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm:{ |
|
|
|
|
|
disabled:true |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: true, |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '物料描述1', |
|
|
|
|
|
field: 'itemDesc1', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm:{ |
|
|
|
|
|
disabled:true |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: true, |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '物料描述2', |
|
|
|
|
|
field: 'itemDesc2', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: false, |
|
|
|
|
|
isForm: false |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '包装号', |
|
|
|
|
|
field: 'packingNumber', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
isTable:false, |
|
|
|
|
|
isTableForm: false, |
|
|
|
|
|
isForm: false |
|
|
|
|
|
}, |
|
|
|
|
|
// {
|
|
|
|
|
|
// label: '器具号',
|
|
|
|
|
|
// field: 'containerNumber',
|
|
|
|
|
|
// sort: 'custom',
|
|
|
|
|
|
// table: {
|
|
|
|
|
|
// width: 150
|
|
|
|
|
|
// },
|
|
|
|
|
|
// isTableForm: false,
|
|
|
|
|
|
// isForm: false
|
|
|
|
|
|
// },
|
|
|
|
|
|
{ |
|
|
|
|
|
label: '数量', |
|
|
|
|
|
field: 'qty', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
form: { |
|
|
|
|
|
component: 'InputNumber', |
|
|
|
|
|
componentProps: { |
|
|
|
|
|
disabled:true, |
|
|
|
|
|
min: 1, |
|
|
|
|
|
precision: 6 |
|
|
|
|
|
}, |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm: { |
|
|
|
|
|
disabled:true, |
|
|
|
|
|
type: 'InputNumber', |
|
|
|
|
|
min: 1, |
|
|
|
|
|
precision: 6 |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '计量单位', |
|
|
|
|
|
field: 'uom', |
|
|
|
|
|
dictType: DICT_TYPE.UOM, |
|
|
|
|
|
dictClass: 'string', |
|
|
|
|
|
isTable: true, |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm: { |
|
|
|
|
|
type: 'Select', |
|
|
|
|
|
disabled: true |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '从库位代码1', |
|
|
|
|
|
field: 'fromLocationCode', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: false, |
|
|
|
|
|
isForm: false |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '生产日期', |
|
|
|
|
|
field: 'produceDate', |
|
|
|
|
|
formatter: dateFormatter2, |
|
|
|
|
|
detail: { |
|
|
|
|
|
dateFormat: 'YYYY-MM-DD' |
|
|
|
|
|
}, |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 180 |
|
|
|
|
|
}, |
|
|
|
|
|
form: { |
|
|
|
|
|
component: 'DatePicker', |
|
|
|
|
|
componentProps: { |
|
|
|
|
|
disabled:true, |
|
|
|
|
|
style: {width: '100%'}, |
|
|
|
|
|
type: 'date', |
|
|
|
|
|
dateFormat: 'YYYY-MM-DD', |
|
|
|
|
|
valueFormat: 'x', |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm:{ |
|
|
|
|
|
disabled:true, |
|
|
|
|
|
type:'FormDate', |
|
|
|
|
|
placeholder: '请选择生产日期', |
|
|
|
|
|
valueFormat: 'x', |
|
|
|
|
|
}, |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
// label: '替代批次',
|
|
|
|
|
|
// field: 'altBatch',
|
|
|
|
|
|
// sort: 'custom',
|
|
|
|
|
|
// table: {
|
|
|
|
|
|
// width: 150
|
|
|
|
|
|
// },
|
|
|
|
|
|
// isTableForm: false,
|
|
|
|
|
|
// isForm: false
|
|
|
|
|
|
// },
|
|
|
|
|
|
{ |
|
|
|
|
|
label: '库存状态', |
|
|
|
|
|
field: 'inventoryStatus', |
|
|
|
|
|
dictType: DICT_TYPE.INVENTORY_STATUS, |
|
|
|
|
|
dictClass: 'string', |
|
|
|
|
|
isTable: true, |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: false, |
|
|
|
|
|
isForm: false, |
|
|
|
|
|
tableForm: { |
|
|
|
|
|
type: 'Select' |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '批次', |
|
|
|
|
|
field: 'batch', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '包装数量', |
|
|
|
|
|
field: 'packQty', |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150 |
|
|
|
|
|
}, |
|
|
|
|
|
form: { |
|
|
|
|
|
componentProps: { |
|
|
|
|
|
disabled: true, |
|
|
|
|
|
isSearchList: true, |
|
|
|
|
|
searchListPlaceholder: '请选择包装', |
|
|
|
|
|
searchField: 'packQty', |
|
|
|
|
|
searchTitle: '物品包装信息', |
|
|
|
|
|
searchAllSchemas: Itempackaging.allSchemas, |
|
|
|
|
|
searchPage: ItemPackageApi.getItempackagingPageBySupplierdeliver, |
|
|
|
|
|
searchCondition: [ |
|
|
|
|
|
{ |
|
|
|
|
|
key: 'itemCode', |
|
|
|
|
|
value: 'itemCode', |
|
|
|
|
|
message: '请选择订单行', |
|
|
|
|
|
isMainValue: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
key: 'available', |
|
|
|
|
|
value: 'TRUE', |
|
|
|
|
|
isMainValue: false |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
] |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm: { |
|
|
|
|
|
disabled: true, |
|
|
|
|
|
isInpuFocusShow: true, |
|
|
|
|
|
searchListPlaceholder: '请选择包装', |
|
|
|
|
|
searchField: 'packQty', |
|
|
|
|
|
searchTitle: '物品包装信息', |
|
|
|
|
|
searchAllSchemas: Itempackaging.allSchemas, |
|
|
|
|
|
searchPage: ItemPackageApi.getItempackagingPageBySupplierdeliver, |
|
|
|
|
|
searchCondition: [ |
|
|
|
|
|
{ |
|
|
|
|
|
key: 'itemCode', |
|
|
|
|
|
value: 'itemCode', |
|
|
|
|
|
message: '请选择订单行', |
|
|
|
|
|
isMainValue: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
key: 'available', |
|
|
|
|
|
value: 'TRUE', |
|
|
|
|
|
isMainValue: false |
|
|
|
|
|
}] |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: true, |
|
|
|
|
|
isForm: true |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
label: '包装规格', |
|
|
|
|
|
field: 'packUnit', |
|
|
|
|
|
dictClass: 'string', |
|
|
|
|
|
isTable: true, |
|
|
|
|
|
sort: 'custom', |
|
|
|
|
|
table: { |
|
|
|
|
|
width: 150, |
|
|
|
|
|
componentProps: { |
|
|
|
|
|
disabled: true |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
tableForm:{ |
|
|
|
|
|
disabled:true |
|
|
|
|
|
}, |
|
|
|
|
|
isTableForm: true, |
|
|
|
|
|
isForm: true |
|
|
|
|
|
}, |
|
|
|
|
|
])) |
|
|
|
|
|
|
|
|
|