diff --git a/src/views/qms/aql/aql.data.ts b/src/views/qms/aql/aql.data.ts
index f60bf83b7..fc961f603 100644
--- a/src/views/qms/aql/aql.data.ts
+++ b/src/views/qms/aql/aql.data.ts
@@ -536,6 +536,28 @@ export const Aql = useCrudSchemas(
width: 105
}
},
+ {
+ label: '是否可用',
+ field: 'available',
+ sort: 'custom',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ isSearch: true,
+ dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
+ form: {
+ component: 'Switch',
+ value: 'TRUE',
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE'
+ }
+ },
+ table: {
+ width: 110
+ }
+ },
{
label: '创建时间',
field: 'createTime',
diff --git a/src/views/qms/aql/index.vue b/src/views/qms/aql/index.vue
index c72299829..e04873b03 100644
--- a/src/views/qms/aql/index.vue
+++ b/src/views/qms/aql/index.vue
@@ -305,6 +305,9 @@ const onChange = async (field, value, formRef) => {
};
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await AqlApi.importTemplate()
})
diff --git a/src/views/qms/counter/counter.data.ts b/src/views/qms/counter/counter.data.ts
index 9723b65a8..5e8459bd3 100644
--- a/src/views/qms/counter/counter.data.ts
+++ b/src/views/qms/counter/counter.data.ts
@@ -153,10 +153,10 @@ export const Counter = useCrudSchemas(
field: 'nextStage',
sort: 'custom',
isSearch: false,
- form:{
+ form: {
component: 'Select',
componentProps: {
- options:[],
+ options: [],
optionsAlias: {
labelField: 'stage',
valueField: 'stage'
@@ -167,6 +167,28 @@ export const Counter = useCrudSchemas(
width: 140
}
},
+ {
+ label: '是否可用',
+ field: 'available',
+ sort: 'custom',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ isSearch: true,
+ dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
+ form: {
+ component: 'Switch',
+ value: 'TRUE',
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE'
+ }
+ },
+ table: {
+ width: 110
+ }
+ },
{
label: '创建时间',
field: 'createTime',
@@ -231,7 +253,7 @@ export const Counter = useCrudSchemas(
width: 150
}
},
-
+
{
label: '操作',
field: 'action',
diff --git a/src/views/qms/counter/index.vue b/src/views/qms/counter/index.vue
index d71c9c1c8..cd789a436 100644
--- a/src/views/qms/counter/index.vue
+++ b/src/views/qms/counter/index.vue
@@ -151,11 +151,13 @@ const buttonTableClick = async (val, row) => {
const basicFormRef = ref()
const openForm = async (type: string, row?: any) => {
+ const obj = await CounterApi.getNextStage(row.id)
for (const item of Counter.allSchemas.formSchema) {
if (item.field === 'nextStage') {
- item.componentProps.options = await CounterApi.getNextStage(row.id)
+ item.componentProps.options = obj.nextStageList
}
}
+ row.available = obj.available
basicFormRef.value.open(type, row)
}
@@ -244,6 +246,9 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await CounterApi.importTemplate()
})
diff --git a/src/views/qms/dynamicRule/dynamicRule.data.ts b/src/views/qms/dynamicRule/dynamicRule.data.ts
index 3bf0ed6ca..d585f1d91 100644
--- a/src/views/qms/dynamicRule/dynamicRule.data.ts
+++ b/src/views/qms/dynamicRule/dynamicRule.data.ts
@@ -39,7 +39,11 @@ export const DynamicRule = useCrudSchemas(
field: 'available',
sort: 'custom',
dictType: DICT_TYPE.TRUE_FALSE,
+ isSearch: true,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/qms/dynamicRule/index.vue b/src/views/qms/dynamicRule/index.vue
index bdb959e6d..58c82c277 100644
--- a/src/views/qms/dynamicRule/index.vue
+++ b/src/views/qms/dynamicRule/index.vue
@@ -411,6 +411,9 @@ const validateNotRepetition = (data) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await DynamicRuleApi.importTemplate()
})
diff --git a/src/views/qms/inspectionJob/index.vue b/src/views/qms/inspectionJob/index.vue
index 06f266f48..13b11b967 100644
--- a/src/views/qms/inspectionJob/index.vue
+++ b/src/views/qms/inspectionJob/index.vue
@@ -419,6 +419,9 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
// importTemplateData.templateUrl = await InspectionJobMainApi.importTemplate()
})
diff --git a/src/views/qms/inspectionJob/inspectionJobMain.data.ts b/src/views/qms/inspectionJob/inspectionJobMain.data.ts
index 389bd9f99..baef7aaa7 100644
--- a/src/views/qms/inspectionJob/inspectionJobMain.data.ts
+++ b/src/views/qms/inspectionJob/inspectionJobMain.data.ts
@@ -56,14 +56,14 @@ export const InspectionJobMain = useCrudSchemas(
label: '发货单号',
field: 'asnNumber',
sort: 'custom',
- isSearch: false,
+ isSearch: true,
form: {
componentProps: {
disabled: true
}
},
table: {
- width: 150
+ width: 180
}
},
{
@@ -225,6 +225,21 @@ export const InspectionJobMain = useCrudSchemas(
width: 150
}
},
+ {
+ label: '供应商批次',
+ field: 'supplierBatch',
+ sort: 'custom',
+ isSearch: false,
+ isDetail: true,
+ form: {
+ componentProps: {
+ disabled: true
+ }
+ },
+ table: {
+ width: 150
+ }
+ },
{
label: '检验批数量',
field: 'inspectionBatchAmount',
@@ -545,6 +560,40 @@ export const InspectionJobMain = useCrudSchemas(
}
}
},
+ {
+ label: '状态',
+ field: 'status',
+ dictType: DICT_TYPE.JOB_STATUS,
+ dictClass: 'string',
+ isForm: false,
+ isTable: true,
+ sort: 'custom',
+ table: {
+ width: 150
+ }
+ },
+ {
+ label: '是否可用',
+ field: 'available',
+ sort: 'custom',
+ isSearch: true,
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
+ form: {
+ component: 'Switch',
+ value: 'TRUE',
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE'
+ }
+ },
+ table: {
+ width: 110
+ }
+ },
{
label: '创建时间',
field: 'createTime',
@@ -609,6 +658,7 @@ export const InspectionJobMain = useCrudSchemas(
width: 150
}
},
+
{
label: '操作',
field: 'action',
diff --git a/src/views/qms/inspectionMethod/index.vue b/src/views/qms/inspectionMethod/index.vue
index 646e65198..d0d67276d 100644
--- a/src/views/qms/inspectionMethod/index.vue
+++ b/src/views/qms/inspectionMethod/index.vue
@@ -301,6 +301,9 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await InspectionMethodApi.importTemplate()
})
diff --git a/src/views/qms/inspectionMethod/inspectionMethod.data.ts b/src/views/qms/inspectionMethod/inspectionMethod.data.ts
index 821f809d9..9bfe757b0 100644
--- a/src/views/qms/inspectionMethod/inspectionMethod.data.ts
+++ b/src/views/qms/inspectionMethod/inspectionMethod.data.ts
@@ -55,8 +55,12 @@ export const InspectionMethod = useCrudSchemas(
label: '是否可用',
field: 'available',
sort: 'custom',
+ isSearch: true,
dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/qms/inspectionRecord/index.vue b/src/views/qms/inspectionRecord/index.vue
index a8871e9bf..4bce94b0c 100644
--- a/src/views/qms/inspectionRecord/index.vue
+++ b/src/views/qms/inspectionRecord/index.vue
@@ -279,7 +279,10 @@ import { DICT_TYPE, getStrDictOptions } from '@/utils/dict'
}
/** 初始化 **/
- onMounted(async () => {
+onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
})
diff --git a/src/views/qms/inspectionRecord/inspectionRecordMain.data.ts b/src/views/qms/inspectionRecord/inspectionRecordMain.data.ts
index 88dbba0de..8732b2aa3 100644
--- a/src/views/qms/inspectionRecord/inspectionRecordMain.data.ts
+++ b/src/views/qms/inspectionRecord/inspectionRecordMain.data.ts
@@ -45,14 +45,14 @@ export const InspectionRecordMain = useCrudSchemas(
label: '发货单号',
field: 'asnNumber',
sort: 'custom',
- isSearch: false,
+ isSearch: true,
form: {
componentProps: {
disabled: true
}
},
table: {
- width: 150
+ width: 180
}
},
{
@@ -120,6 +120,16 @@ export const InspectionRecordMain = useCrudSchemas(
width: 150
}
},
+ {
+ label: '供应商批次',
+ field: 'supplierBatch',
+ sort: 'custom',
+ isSearch: false,
+ isForm: false,
+ table: {
+ width: 150
+ }
+ },
{
label: '检验方案编码',
field: 'inspectionSchemeCode',
@@ -370,6 +380,7 @@ export const InspectionRecordMain = useCrudSchemas(
sort: 'custom',
formatter: dateFormatter,
isSearch: false,
+ isForm: false,
search: {
component: 'DatePicker',
componentProps: {
@@ -379,7 +390,6 @@ export const InspectionRecordMain = useCrudSchemas(
}
},
form: {
- component: 'DatePicker',
componentProps: {
type: 'datetime',
valueFormat: 'x'
@@ -424,6 +434,39 @@ export const InspectionRecordMain = useCrudSchemas(
width: 150
}
},
+ {
+ label: '执行结果',
+ field: 'estimateCode',
+ dictType: DICT_TYPE.EVALUATION_CODE,
+ sort: 'custom',
+ isSearch: false,
+ isForm: false,
+ table: {
+ width: 150
+ }
+ },
+ {
+ label: '是否可用',
+ field: 'available',
+ sort: 'custom',
+ isSearch: true,
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
+ form: {
+ component: 'Switch',
+ value: 'TRUE',
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE'
+ }
+ },
+ table: {
+ width: 110
+ }
+ },
{
label: '创建时间',
field: 'createTime',
diff --git a/src/views/qms/inspectionRequest/index.vue b/src/views/qms/inspectionRequest/index.vue
index 586355240..0d2adf9f3 100644
--- a/src/views/qms/inspectionRequest/index.vue
+++ b/src/views/qms/inspectionRequest/index.vue
@@ -397,7 +397,10 @@ console.log(formType,data)
list.value = await InspectionRequestPackageApi.getInspectionRequestPackageList(data.masterId)
}
/** 初始化 **/
- onMounted(async () => {
+onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await InspectionMainApi.importTemplate()
})
diff --git a/src/views/qms/inspectionRequest/inspectionRequestMain.data.ts b/src/views/qms/inspectionRequest/inspectionRequestMain.data.ts
index 90ba50ea2..845e4d999 100644
--- a/src/views/qms/inspectionRequest/inspectionRequestMain.data.ts
+++ b/src/views/qms/inspectionRequest/inspectionRequestMain.data.ts
@@ -44,7 +44,7 @@ export const InspectionMain = useCrudSchemas(
label: '发货单号',
field: 'asnNumber',
sort: 'custom',
- isSearch: false,
+ isSearch: true,
isForm: false,
form: {
componentProps: {
@@ -52,7 +52,7 @@ export const InspectionMain = useCrudSchemas(
}
},
table: {
- width: 150
+ width: 180
}
},
{
@@ -306,7 +306,7 @@ export const InspectionMain = useCrudSchemas(
}
},
{
- label: '批次',
+ label: '检验批次',
field: 'batch',
sort: 'custom',
isSearch: false,
@@ -314,6 +314,16 @@ export const InspectionMain = useCrudSchemas(
width: 150
}
},
+ {
+ label: '供应商批次',
+ field: 'supplierBatch',
+ sort: 'custom',
+ isSearch: false,
+ isForm: false,
+ table: {
+ width: 150
+ }
+ },
{
label: '待检数量',
field: 'requestInspectionNum',
@@ -415,6 +425,28 @@ export const InspectionMain = useCrudSchemas(
width: 150
}
},
+ {
+ label: '是否可用',
+ field: 'available',
+ sort: 'custom',
+ isSearch: true,
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
+ form: {
+ component: 'Switch',
+ value: 'TRUE',
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE'
+ }
+ },
+ table: {
+ width: 110
+ }
+ },
{
label: '创建时间',
field: 'createTime',
diff --git a/src/views/qms/inspectionScheme/index.vue b/src/views/qms/inspectionScheme/index.vue
index 1442fa9e0..1bd6b50e3 100644
--- a/src/views/qms/inspectionScheme/index.vue
+++ b/src/views/qms/inspectionScheme/index.vue
@@ -269,6 +269,9 @@ const importSuccess = () => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await InspectionSchemeApi.importTemplate()
})
diff --git a/src/views/qms/inspectionScheme/inspectionScheme.data.ts b/src/views/qms/inspectionScheme/inspectionScheme.data.ts
index 041851697..fce02545b 100644
--- a/src/views/qms/inspectionScheme/inspectionScheme.data.ts
+++ b/src/views/qms/inspectionScheme/inspectionScheme.data.ts
@@ -184,8 +184,12 @@ export const InspectionSchemeMain = useCrudSchemas(
label: '是否可用',
field: 'available',
sort: 'custom',
+ isSearch: true,
dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/qms/inspectionTemplate/index.vue b/src/views/qms/inspectionTemplate/index.vue
index 1d59f1568..578a526c1 100644
--- a/src/views/qms/inspectionTemplate/index.vue
+++ b/src/views/qms/inspectionTemplate/index.vue
@@ -246,6 +246,9 @@ const importSuccess = () => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await InspectionProcessPageApi.importTemplate()
})
diff --git a/src/views/qms/inspectionTemplate/inspectionTemplate.data.ts b/src/views/qms/inspectionTemplate/inspectionTemplate.data.ts
index 03ba803a2..631e9a887 100644
--- a/src/views/qms/inspectionTemplate/inspectionTemplate.data.ts
+++ b/src/views/qms/inspectionTemplate/inspectionTemplate.data.ts
@@ -59,8 +59,12 @@ export const InspectionTemplateMain = useCrudSchemas(
label: '是否可用',
field: 'available',
sort: 'custom',
+ isSearch: true,
dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/qms/qualityNotice/index.vue b/src/views/qms/qualityNotice/index.vue
index 54b0b8409..064613a52 100644
--- a/src/views/qms/qualityNotice/index.vue
+++ b/src/views/qms/qualityNotice/index.vue
@@ -228,7 +228,10 @@ const handleOrderPub = async (row : object) => {
}
/** 初始化 **/
- onMounted(async () => {
+onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
})
diff --git a/src/views/qms/qualityNotice/qualityNoticeMain.data.ts b/src/views/qms/qualityNotice/qualityNoticeMain.data.ts
index 00d24e626..c5e1104ba 100644
--- a/src/views/qms/qualityNotice/qualityNoticeMain.data.ts
+++ b/src/views/qms/qualityNotice/qualityNoticeMain.data.ts
@@ -317,6 +317,28 @@ export const QualityNoticeMain = useCrudSchemas(
width: 175
}
},
+ {
+ label: '是否可用',
+ field: 'available',
+ sort: 'custom',
+ isSearch: true,
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
+ form: {
+ component: 'Switch',
+ value: 'TRUE',
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE'
+ }
+ },
+ table: {
+ width: 110
+ }
+ },
{
label: '创建时间',
field: 'createTime',
diff --git a/src/views/qms/sampleCode/index.vue b/src/views/qms/sampleCode/index.vue
index 5025694e6..5c1b55904 100644
--- a/src/views/qms/sampleCode/index.vue
+++ b/src/views/qms/sampleCode/index.vue
@@ -288,6 +288,9 @@ const onChange = async (field, value, formRef) => {
}
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await SampleCodeApi.importTemplate()
})
diff --git a/src/views/qms/sampleCode/sampleCode.data.ts b/src/views/qms/sampleCode/sampleCode.data.ts
index 330f5dec9..2409000a6 100644
--- a/src/views/qms/sampleCode/sampleCode.data.ts
+++ b/src/views/qms/sampleCode/sampleCode.data.ts
@@ -102,7 +102,11 @@ export const SampleCode = useCrudSchemas(
field: 'available',
sort: 'custom',
dictType: DICT_TYPE.TRUE_FALSE,
+ isSearch: true,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/qms/samplingProcess/index.vue b/src/views/qms/samplingProcess/index.vue
index ad482a907..1045a90b2 100644
--- a/src/views/qms/samplingProcess/index.vue
+++ b/src/views/qms/samplingProcess/index.vue
@@ -344,6 +344,9 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await SamplingProcessApi.importTemplate()
})
diff --git a/src/views/qms/samplingProcess/samplingProcess.data.ts b/src/views/qms/samplingProcess/samplingProcess.data.ts
index 08d418c6e..7bdcf8dcc 100644
--- a/src/views/qms/samplingProcess/samplingProcess.data.ts
+++ b/src/views/qms/samplingProcess/samplingProcess.data.ts
@@ -85,7 +85,11 @@ export const SamplingProcess = useCrudSchemas(
field: 'available',
sort: 'custom',
dictType: DICT_TYPE.TRUE_FALSE,
+ isSearch: true,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
@@ -93,6 +97,9 @@ export const SamplingProcess = useCrudSchemas(
inactiveValue: 'FALSE',
activeValue: 'TRUE'
}
+ },
+ table: {
+ width: 110
}
},
{
diff --git a/src/views/qms/samplingScheme/index.vue b/src/views/qms/samplingScheme/index.vue
index 3b7d6260f..25ff8c6b5 100644
--- a/src/views/qms/samplingScheme/index.vue
+++ b/src/views/qms/samplingScheme/index.vue
@@ -266,6 +266,9 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await SamplingSchemeApi.importTemplate()
})
diff --git a/src/views/qms/samplingScheme/samplingScheme.data.ts b/src/views/qms/samplingScheme/samplingScheme.data.ts
index 7ede5cd2f..4f5f121ea 100644
--- a/src/views/qms/samplingScheme/samplingScheme.data.ts
+++ b/src/views/qms/samplingScheme/samplingScheme.data.ts
@@ -28,8 +28,12 @@ export const SamplingScheme = useCrudSchemas(
label: '是否可用',
field: 'available',
sort: 'custom',
+ isSearch:true,
dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE',
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/qms/selectedSet/index.vue b/src/views/qms/selectedSet/index.vue
index d2a498651..ffecc38ef 100644
--- a/src/views/qms/selectedSet/index.vue
+++ b/src/views/qms/selectedSet/index.vue
@@ -433,6 +433,9 @@ const formSelectChange = (a,b,c,d) => {
/** 初始化 **/
onMounted(async () => {
+ tableObject.params = {
+ available: true
+ }
getList()
importTemplateData.templateUrl = await SelectedSetApi.importTemplate()
})
diff --git a/src/views/qms/selectedSet/selectedSet.data.ts b/src/views/qms/selectedSet/selectedSet.data.ts
index b13c7af2d..1fcfd94bd 100644
--- a/src/views/qms/selectedSet/selectedSet.data.ts
+++ b/src/views/qms/selectedSet/selectedSet.data.ts
@@ -30,8 +30,12 @@ export const SelectedSet = useCrudSchemas(
label: '是否可用',
field: 'available',
sort: 'custom',
+ isSearch: true,
dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
+ search: {
+ value: 'TRUE'
+ },
form: {
component: 'Switch',
value: 'TRUE',
diff --git a/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue b/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue
index 5c2e536c8..93c2b87b2 100644
--- a/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue
+++ b/src/views/wms/basicDataManage/itemManage/relegate/relegateRequest/index.vue
@@ -112,6 +112,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) =>
nextTick(() => {
if (type == 'tableForm') {
if (formField == 'itemCode') {
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['itemCode']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['itemCode'] = item['itemCode']
diff --git a/src/views/wms/countManage/count/countJobMain/countJobMain.data.ts b/src/views/wms/countManage/count/countJobMain/countJobMain.data.ts
index bd5868bdc..660c23a4c 100644
--- a/src/views/wms/countManage/count/countJobMain/countJobMain.data.ts
+++ b/src/views/wms/countManage/count/countJobMain/countJobMain.data.ts
@@ -766,22 +766,22 @@ export const CountJobDetail = useCrudSchemas(reactive
([
width: 150
},
},
- {
- label: '盘点描述',
- field: 'countDescription',
- sort: 'custom',
- table: {
- width: 150
- },
- },
- {
- label: '备注',
- field: 'remark',
- sort: 'custom',
- table: {
- width: 150
- },
- },
+ // {
+ // label: '盘点描述',
+ // field: 'countDescription',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // },
+ // {
+ // label: '备注',
+ // field: 'remark',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // },
{
label: '创建时间',
field: 'createTime',
diff --git a/src/views/wms/countManage/count/countJobMain/index.vue b/src/views/wms/countManage/count/countJobMain/index.vue
index 225bf62d5..a30736267 100644
--- a/src/views/wms/countManage/count/countJobMain/index.vue
+++ b/src/views/wms/countManage/count/countJobMain/index.vue
@@ -74,6 +74,7 @@
:coverIsDisable="true"
:mode="1"
:extend="rowMasterIdRef"
+ :isShowDownloadBtn="true"
/>
diff --git a/src/views/wms/countManage/count/countPlanMain/countPlanMain.data.ts b/src/views/wms/countManage/count/countPlanMain/countPlanMain.data.ts
index efda01683..087d2cc37 100644
--- a/src/views/wms/countManage/count/countPlanMain/countPlanMain.data.ts
+++ b/src/views/wms/countManage/count/countPlanMain/countPlanMain.data.ts
@@ -128,6 +128,7 @@ export const CountPlanMain = useCrudSchemas(reactive([
table: {
width: 150
},
+ isForm:false,
form: {
componentProps: {
isSearchList: true, // 开启查询弹窗
@@ -147,6 +148,7 @@ export const CountPlanMain = useCrudSchemas(reactive([
table: {
width: 150
},
+ isForm: false,
form: {
componentProps: {
isSearchList: true, // 开启查询弹窗
diff --git a/src/views/wms/countManage/count/countPlanMain/index.vue b/src/views/wms/countManage/count/countPlanMain/index.vue
index eaf2b9d63..cda7d8619 100644
--- a/src/views/wms/countManage/count/countPlanMain/index.vue
+++ b/src/views/wms/countManage/count/countPlanMain/index.vue
@@ -57,6 +57,7 @@
:tableData="tableData"
:apiUpdate="CountPlanMainApi.updateCountPlanMain"
:apiCreate="CountPlanMainApi.createCountPlanMain"
+ :CountPlanMain1FormAllSchemas="CountPlanMain1.allSchemas"
fromeWhere="countPlan"
:countScopeType="getStrDictOptions(DICT_TYPE.COUNT_SCOPE_TYPE)"
@handleAddTable="handleAddTable"
@@ -111,7 +112,8 @@ import {
CountPlanDetail,
CountPlanDetailRules,
CountPlanMain,
- CountPlanMainRules
+ CountPlanMainRules,
+ CountPlanMain1
} from './countPlanMain.data'
import * as CountPlanMainApi from '@/api/wms/countPlanMain'
import * as CountPlanDetailApi from '@/api/wms/countPlanDetail'
@@ -468,7 +470,7 @@ const detailOpenForm = (type, row) => {
row.type == 'ABC' ||
row.type == 'ITEMS_TYPE' ||
row.type == 'ITEMS_GROUP' ||
- row.type == 'ITEMS_CODE' ||
+ row.type == 'ITEM_CODE' ||
row.type == 'WAREHOUSE_CODE' ||
row.type == 'AREABASIC_CODE' ||
row.type == 'LOCATIONGROUP_CODE' ||
@@ -536,7 +538,7 @@ const detailOpenForm = (type, row) => {
}
})
break
- case 'ITEMS_CODE':
+ case 'ITEM_CODE':
CountPlanDetail.allSchemas.formSchema.forEach((item) => {
if (item.field == 'value') {
item.componentProps.isInpuFocusShow = true
@@ -788,7 +790,7 @@ const selectChangeDetail = (field, val) => {
val == 'ABC' ||
val == 'ITEMS_TYPE' ||
val == 'ITEMS_GROUP' ||
- val == 'ITEMS_CODE' ||
+ val == 'ITEM_CODE' ||
val == 'WAREHOUSE_CODE' ||
val == 'AREABASIC_CODE' ||
val == 'LOCATIONGROUP_CODE' ||
@@ -856,7 +858,7 @@ const selectChangeDetail = (field, val) => {
}
})
break
- case 'ITEMS_CODE':
+ case 'ITEM_CODE':
CountPlanDetail.allSchemas.formSchema.forEach((item) => {
if (item.field == 'value') {
item.componentProps.isSearchList = true
@@ -925,7 +927,7 @@ const tableFormChange = async (field, val, row) => {
row.type == 'ABC' ||
row.type == 'ITEMS_TYPE' ||
row.type == 'ITEMS_GROUP' ||
- row.type == 'ITEMS_CODE' ||
+ row.type == 'ITEM_CODE' ||
row.type == 'WAREHOUSE_CODE' ||
row.type == 'AREABASIC_CODE' ||
row.type == 'LOCATIONGROUP_CODE' ||
@@ -990,7 +992,7 @@ const tableFormChange = async (field, val, row) => {
}
})
break
- case 'ITEMS_CODE':
+ case 'ITEM_CODE':
row.searchTable = {
isInpuFocusShow: true,
searchTitle: '物品信息',
diff --git a/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue b/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue
index f46c3e11d..f8e1430c4 100644
--- a/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue
+++ b/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue
@@ -143,6 +143,7 @@ const updataTableColumns = (val) => {
// 查询页面返回
const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => {
+ console.log('searchTableSuccess',formField, searchField, val, formRef, type, row )
nextTick(async () => {
if (type == 'tableForm') {
if(formField == 'itemCode') {
@@ -150,8 +151,14 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =
DeliverRequestDetail.allSchemas.tableFormColumns.forEach(item => {
tableFormKeys[item.field] = item.default ? item.default : ''
})
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['itemCode']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(val.length==0) return
val.forEach(item=>{
- if(tableData.value.find(item1=>item1['itemCode'] == item['itemCode'])) return
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['uom'] = item['customerUom']
newRow['id'] = item['id']
diff --git a/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/index.vue b/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/index.vue
index 043524a2a..47f96799d 100644
--- a/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/index.vue
+++ b/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/index.vue
@@ -157,8 +157,14 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
})
if (type == 'tableForm') {
if(formField == 'itemCode') {
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['itemCode']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(val.length==0) return
val.forEach(item=>{
- if(tableData.value.find(item1=>item1['itemCode'] == item['itemCode'])) return
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
row[formField] = item[searchField]
newRow['uom'] = item['customerUom']
diff --git a/src/views/wms/deliversettlementManage/saleShipmentMainRequest/index.vue b/src/views/wms/deliversettlementManage/saleShipmentMainRequest/index.vue
index e0eecb53b..9fd7dda33 100644
--- a/src/views/wms/deliversettlementManage/saleShipmentMainRequest/index.vue
+++ b/src/views/wms/deliversettlementManage/saleShipmentMainRequest/index.vue
@@ -111,6 +111,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
nextTick(() => {
if (type == 'tableForm') {
if(formField == 'soLine') {
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['soLine']==item['lineNumber']&&item1['soNumber']==item['number']&&item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item.itemCode))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['soLine']==item['lineNumber']&&item1['soNumber']==item['number']&&item1['itemCode']==item['itemCode']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['soLine'] = item['lineNumber']
diff --git a/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/index.vue b/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/index.vue
index 9cc571da8..3edbc9158 100644
--- a/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/index.vue
+++ b/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/index.vue
@@ -128,6 +128,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
// row['uom'] = val[0]['uom']
// }
if(formField == 'itemCode') {
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['code']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['code']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['code']))
+ if(val.length==0) return
val.forEach(item=>{
if(tableData.value.find(item1=>item1['itemCode'] == item['code'])) return
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
diff --git a/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts b/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts
index 373e50f03..26fb57890 100644
--- a/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts
+++ b/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts
@@ -649,6 +649,7 @@ export const StockupDetailRequest = useCrudSchemas(reactive([
width: 150
},
tableForm:{
+ multiple:true,
isInpuFocusShow: false, // 开启查询弹窗
searchListPlaceholder: '请选择物料代码',
searchField: 'code',
diff --git a/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts b/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts
index dabab54a5..9afba26c7 100644
--- a/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts
+++ b/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts
@@ -402,23 +402,43 @@ export const ContainerDetailRequest = useCrudSchemas(reactive([
table: {
width: 150
},
- tableForm:{
+ tableForm: {
+ enterSearch: true,
isInpuFocusShow: true, // 开启查询弹窗
searchListPlaceholder: '请选择到库位代码',
searchField: 'code',
searchTitle: '库位信息',
searchAllSchemas: Location.allSchemas,
searchPage: LocationApi.selectBusinessTypeToLocation,
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
+ }]
},
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
+ enterSearch: true,
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择到库位代码',
searchField: 'code',
searchTitle: '库位信息',
searchAllSchemas: Location.allSchemas,
searchPage: LocationApi.selectBusinessTypeToLocation,
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
+ }]
}
}
},
diff --git a/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/index.vue b/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/index.vue
index 6226545d9..56c7fe1f9 100644
--- a/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/index.vue
+++ b/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/index.vue
@@ -157,7 +157,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) =>
nextTick(() => {
if (type == 'tableForm') {
if(formField == 'containerNumber') {
-
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['containerNumber']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['itemCode']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['containerNumber']==item['itemCode']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['containerNumber'] = item['itemCode']
diff --git a/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/index.vue b/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/index.vue
index 6024c640f..20028f7e2 100644
--- a/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/index.vue
+++ b/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/index.vue
@@ -132,6 +132,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) =>
nextTick(() => {
if (type == 'tableForm') {
if(formField == 'containerNumber') {
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['containerNumber']==item['code']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['code']))
+ message.warning(`器具号${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['containerNumber']==item['code']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['containerNumber'] = item['code']
diff --git a/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts b/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts
index 97a6dc837..766ad8056 100644
--- a/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts
+++ b/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts
@@ -359,7 +359,8 @@ export const ContainerDetailRequest = useCrudSchemas(reactive([
sort: 'custom',
tableForm:{
multiple:true,
- isInpuFocusShow: true, // 开启查询弹窗
+ isInpuFocusShow: false, // 开启查询弹窗
+ disabled: true,
searchListPlaceholder: '请选择器具号',
searchField: 'itemCode',
searchTitle: '器具信息',
diff --git a/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/index.vue b/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/index.vue
index 1eaca15ea..2255710a7 100644
--- a/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/index.vue
+++ b/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/index.vue
@@ -133,6 +133,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) =>
nextTick(() => {
if (type == 'tableForm') {
if(formField == 'containerNumber') {
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['containerNumber']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['itemCode']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['containerNumber']==item['itemCode']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['containerNumber'] = item['itemCode']
diff --git a/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts b/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts
index 5516b76cb..58338a454 100644
--- a/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts
+++ b/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts
@@ -403,22 +403,42 @@ export const ContainerDetailRequest = useCrudSchemas(reactive([
width: 150
},
tableForm: {
+ enterSearch:true,
isInpuFocusShow: true, // 开启查询弹窗
searchListPlaceholder: '请选择到库位代码',
searchField: 'code',
searchTitle: '库位信息',
searchAllSchemas: Location.allSchemas,
searchPage: LocationApi.selectPageItemAreaToLocation,
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
+ }]
},
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
+ enterSearch: true,
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择到库位代码',
searchField: 'code',
searchTitle: '库位信息',
searchAllSchemas: Location.allSchemas,
searchPage: LocationApi.selectPageItemAreaToLocation,
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
+ }]
}
}
},
diff --git a/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRequestMain/index.vue b/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRequestMain/index.vue
index 79694b38a..c659954a2 100644
--- a/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRequestMain/index.vue
+++ b/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRequestMain/index.vue
@@ -115,6 +115,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
// 明细查询页赋值
if(formField=='itemCode'){
//物料代码
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['code']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['code']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['code']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow[formField] = item[searchField]
diff --git a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts
index 91bbeb867..4dbe716a4 100644
--- a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts
+++ b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts
@@ -112,6 +112,7 @@ export const PackageoverRequestMain = useCrudSchemas(reactive([
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
+ enterSearch: true,
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择仓库代码', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段
@@ -122,6 +123,15 @@ export const PackageoverRequestMain = useCrudSchemas(reactive([
key: 'available',
value: 'TRUE',
isMainValue: false
+ }],
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
}]
}
}
@@ -578,6 +588,15 @@ export const PackageoverRequestDetail = useCrudSchemas(reactive([
key: 'itemCode',
value: 'itemCode',
isMainValue: true
+ }],
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'packUnit',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
}]
},
form: {
@@ -598,6 +617,15 @@ export const PackageoverRequestDetail = useCrudSchemas(reactive([
value: 'itemCode',
message: '请先选择物料代码!', // 当前置条件为空时 弹出信息提示
isMainValue: true
+ }],
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'packUnit',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
}]
}
}
@@ -628,6 +656,15 @@ export const PackageoverRequestDetail = useCrudSchemas(reactive([
value: 'itemCode',
message: '请先选择物料代码!', // 当前置条件为空时 弹出信息提示
isMainValue: true
+ }],
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'packUnit',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
}]
},
form: {
@@ -647,6 +684,15 @@ export const PackageoverRequestDetail = useCrudSchemas(reactive([
key: 'itemCode',
value: 'itemCode',
isMainValue: true
+ }],
+ // 失去焦点校验参数
+ verificationParams: [{
+ key: 'packUnit',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: 'true',
+ isFormModel: true,
}]
}
}
diff --git a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue
index d4ad79678..69d31a86d 100644
--- a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue
+++ b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue
@@ -114,6 +114,8 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if (type == 'tableForm') {
// 明细查询页赋值
if(formField=='itemCode'){
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']&&item1['batch']==item['batch']&&item1['packingNumber']==item['packingNumber']&&item1['fromLocationCode']==item['locationCode']&&item1['inventoryStatus']==item['inventoryStatus']))
+ if(val.length==0) return
val.forEach(item=>{
let newRow = JSON.parse(JSON.stringify(tableFormKeys))
newRow['packingNumber'] = item['packingNumber']
diff --git a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/sparepartsrequisitionRequestMain.data.ts b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/sparepartsrequisitionRequestMain.data.ts
index 91a2ea81c..587d96949 100644
--- a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/sparepartsrequisitionRequestMain.data.ts
+++ b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/sparepartsrequisitionRequestMain.data.ts
@@ -115,6 +115,7 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
+ enterSearch: true,
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择成本中心代码', // 输入框占位文本
searchField: 'costcentreCode', // 查询弹窗赋值字段
@@ -125,7 +126,15 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
key: 'available',
value: 'TRUE',
isMainValue: false
- }]
+ }],
+ verificationParams: [{
+ key: 'costcentreCode',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: true,
+ isFormModel: true,
+ }], // 失去焦点校验参数
}
}
},
@@ -150,6 +159,7 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
width: 150
},
tableForm: {
+ enterSearch: true,
isInpuFocusShow: true, // 开启查询弹窗
searchListPlaceholder: '请选择成领用原因代码',
searchField: 'code',
@@ -165,11 +175,20 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
value: 'costCenterType',
message: '成本中心类型不能为空!',
isMainValue: true
- }]
+ }],
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: true,
+ isFormModel: true,
+ }], // 失去焦点校验参数
},
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
+ enterSearch: true,
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择成本中心代码', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段
@@ -185,7 +204,15 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
value: 'costCenterType',
message: '成本中心类型不能为空!',
isMainValue: true
- }]
+ }],
+ verificationParams: [{
+ key: 'code',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: true,
+ isFormModel: true,
+ }], // 失去焦点校验参数
}
}
},
@@ -197,16 +224,26 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
width: 150
},
tableForm: {
+ enterSearch: true,
isInpuFocusShow: true, // 开启查询弹窗
searchListPlaceholder: '请选择QAD项目信息',
searchField: 'projectCode',
searchTitle: '领用原因代码',
searchAllSchemas: QadProject.allSchemas,
- searchPage: QadProjectApi.getQadProjectPage
+ searchPage: QadProjectApi.getQadProjectPage,
+ verificationParams: [{
+ key: 'projectCode',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: true,
+ isFormModel: true,
+ }], // 失去焦点校验参数
},
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
+ enterSearch: true,
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择QAD项目信息', // 输入框占位文本
searchField: 'projectCode', // 查询弹窗赋值字段
@@ -217,7 +254,15 @@ export const UnplannedissueRequestMain = useCrudSchemas(reactive([
key: 'available',
value: 'TRUE',
isMainValue: false
- }]
+ }],
+ verificationParams: [{
+ key: 'projectCode',
+ action: '==',
+ value: '',
+ isMainValue: false,
+ isSearch: true,
+ isFormModel: true,
+ }], // 失去焦点校验参数
}
}
},
diff --git a/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue b/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue
index 55b13a0a2..ac6b09607 100644
--- a/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue
+++ b/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue
@@ -114,6 +114,8 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if (type == 'tableForm') {
// 明细查询页赋值
if(formField === 'itemCode'){
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']&&item1['batch']==item['batch']&&item1['packingNumber']==item['packingNumber']&&item1['fromLocationCode']==item['locationCode']&&item1['inventoryStatus']==item['inventoryStatus']))
+ if(val.length==0) return
val.forEach(item=>{
let newRow = JSON.parse(JSON.stringify(tableFormKeys))
newRow[formField] =item[searchField]
diff --git a/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue b/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue
index ae42c44cb..91d5fb334 100644
--- a/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue
+++ b/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue
@@ -199,6 +199,12 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if(formField == 'toLocationCode'){
row['toLocationCode'] = val[0]['code']
} else if(formField == 'itemCode'){
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['code']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item['code']))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
if(val.length==0){
return
}
diff --git a/src/views/wms/issueManage/issue/issueJobMain/index.vue b/src/views/wms/issueManage/issue/issueJobMain/index.vue
index c751f298b..a0fc82fce 100644
--- a/src/views/wms/issueManage/issue/issueJobMain/index.vue
+++ b/src/views/wms/issueManage/issue/issueJobMain/index.vue
@@ -288,7 +288,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"jobIssueMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/issue/issueRecordMain/index.vue b/src/views/wms/issueManage/issue/issueRecordMain/index.vue
index e8d26b0f9..61c8326cd 100644
--- a/src/views/wms/issueManage/issue/issueRecordMain/index.vue
+++ b/src/views/wms/issueManage/issue/issueRecordMain/index.vue
@@ -144,7 +144,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"recordIssueMain")
}
/** 导出按钮操作 */
@@ -176,4 +176,4 @@ const searchFormClick = (searchData) => {
onMounted(async () => {
getList()
})
-
\ No newline at end of file
+
diff --git a/src/views/wms/issueManage/issue/issueRequestMain/index.vue b/src/views/wms/issueManage/issue/issueRequestMain/index.vue
index f8406acad..db8125f6d 100644
--- a/src/views/wms/issueManage/issue/issueRequestMain/index.vue
+++ b/src/views/wms/issueManage/issue/issueRequestMain/index.vue
@@ -80,7 +80,7 @@
/>
-
@@ -364,7 +364,7 @@ const buttonTableClick = async (val, row) => {
tableObject.loading = false
console.log(err)
})
- } else if (val == 'edit') { // 编辑
+ } else if (val == 'edit') { // 编辑
openForm('update', row)
} else if (val == 'delete') { // 删除
handleDelete(row.masterId)
@@ -403,7 +403,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"requestIssueMain")
}
/** 删除按钮操作 */
diff --git a/src/views/wms/issueManage/onlinesettlement/onlinesettlementRecordMain/index.vue b/src/views/wms/issueManage/onlinesettlement/onlinesettlementRecordMain/index.vue
index d5d90e77b..b4f8a8d89 100644
--- a/src/views/wms/issueManage/onlinesettlement/onlinesettlementRecordMain/index.vue
+++ b/src/views/wms/issueManage/onlinesettlement/onlinesettlementRecordMain/index.vue
@@ -139,7 +139,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"recordOnlinesettlementMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue
index bdb8faf57..8a2b05fab 100644
--- a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue
+++ b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue
@@ -116,7 +116,7 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if(tableData.value.find(item1=>item1['itemCode'] == val[0]['componentItemCode'])){
message.warning(`物料${val[0]['componentItemCode']}已经存在`)
return
- }
+ }
row['itemCode'] = val[0]['componentItemCode']
row['uom'] = val[0]['componentUom']
} else if(formField == 'workStation'){
@@ -419,7 +419,7 @@ const openForm =async (type: string, row?: number) => {
/** 详情操作 */
const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"planPreparetoissueMain")
}
/** 删除按钮操作 */
@@ -489,20 +489,21 @@ const submitForm = async (formType, submitData) => {
data.subList = tableData.value // 拼接子表数据参数
try {
if (formType === 'create') {
- await PreparetoissueMainApi.createPreparetoissueMain(data).then((res) => {
+ await PreparetoissueMainApi.createPreparetoissueMain(data).then(async (res) => {
if (res.status == '6') {
// 生成发料申请
- PreparetoissueMainApi.generateIssueRequest(res.number)
+ await PreparetoissueMainApi.generateIssueRequest(res.number)
}
+ getList()
})
message.success(t('common.createSuccess'))
} else {
await PreparetoissueMainApi.updatePreparetoissueMain(data)
message.success(t('common.updateSuccess'))
+ getList()
}
formRef.value.dialogVisible = false
// 刷新当前列表
- getList()
} finally {
formRef.value.formLoading = false
}
diff --git a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts
index 45148f84e..a709b6926 100644
--- a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts
+++ b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts
@@ -524,8 +524,7 @@ export const PreparetoissueDetail = useCrudSchemas(reactive([
form: {
// labelMessage: '信息提示说明!!!',
componentProps: {
- enterSearch:true,
- isSearchList: true, // 开启查询弹窗
+ isSearchList: false, // 开启查询弹窗
searchListPlaceholder: '请选择工位', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段
searchTitle: '工位信息', // 查询弹窗标题
@@ -557,16 +556,17 @@ export const PreparetoissueDetail = useCrudSchemas(reactive([
}
},
tableForm: {
- enterSearch: true,
isShowTableFormSearch:true,
multiple: true,
- isInpuFocusShow: true,
+ disabled: true,
+ isInpuFocusShow: false,
searchListPlaceholder: '请选择工位', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段
searchTitle: '工位信息', // 查询弹窗标题
searchAllSchemas: Workstation.allSchemas, // 查询弹窗所需类
searchPage: WorkStationApi.getWorkstationPage, // 查询弹窗所需分页方法
verificationPage: WorkStationApi.getWorkstationByCodes,// 失去焦点校验输入框的数据内容存在
+ isRepeat: true,//tableForm下方输入框是否可以重复添加该条数据
searchCondition: [{
key: 'productionLineCode',
value: 'prodLine',
diff --git a/src/views/wms/issueManage/productionreceipt/productionreceiptJobMain/index.vue b/src/views/wms/issueManage/productionreceipt/productionreceiptJobMain/index.vue
index feaba54ef..611dd428c 100644
--- a/src/views/wms/issueManage/productionreceipt/productionreceiptJobMain/index.vue
+++ b/src/views/wms/issueManage/productionreceipt/productionreceiptJobMain/index.vue
@@ -288,7 +288,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"jobProductionreceiptMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/productionreceipt/productionreceiptRecordMain/index.vue b/src/views/wms/issueManage/productionreceipt/productionreceiptRecordMain/index.vue
index 7adfda3b6..23ce2913b 100644
--- a/src/views/wms/issueManage/productionreceipt/productionreceiptRecordMain/index.vue
+++ b/src/views/wms/issueManage/productionreceipt/productionreceiptRecordMain/index.vue
@@ -144,7 +144,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"recordProductionreceiptMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/productionreturn/productionreturnJobMain/index.vue b/src/views/wms/issueManage/productionreturn/productionreturnJobMain/index.vue
index fc7c9400a..2d64cb732 100644
--- a/src/views/wms/issueManage/productionreturn/productionreturnJobMain/index.vue
+++ b/src/views/wms/issueManage/productionreturn/productionreturnJobMain/index.vue
@@ -260,7 +260,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"jobProductionreturnMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/productionreturn/productionreturnRecordMain/index.vue b/src/views/wms/issueManage/productionreturn/productionreturnRecordMain/index.vue
index cd2f00442..ae8aebbeb 100644
--- a/src/views/wms/issueManage/productionreturn/productionreturnRecordMain/index.vue
+++ b/src/views/wms/issueManage/productionreturn/productionreturnRecordMain/index.vue
@@ -144,7 +144,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"recordProductionreturnMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue b/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue
index a77b1ffdb..82d8d0dfa 100644
--- a/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue
+++ b/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue
@@ -191,7 +191,7 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if(tableData.value.find(item1=>item1['itemCode'] == val[0]['itemCode'])){
message.warning(`物料${val[0]['itemCode']}已经存在`)
return
- }
+ }
const isType = await isItemType(val[0]['itemCode'], labelType.value)
if(!isType){
@@ -574,7 +574,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"requestProductionreturnMain")
}
/** 详情操作——子表表单 */
const detailOpenForm = (type, row) => {
diff --git a/src/views/wms/issueManage/productionreturn/productionreturnRequestMainNo/index.vue b/src/views/wms/issueManage/productionreturn/productionreturnRequestMainNo/index.vue
index 660783b9f..529e57f8a 100644
--- a/src/views/wms/issueManage/productionreturn/productionreturnRequestMainNo/index.vue
+++ b/src/views/wms/issueManage/productionreturn/productionreturnRequestMainNo/index.vue
@@ -177,24 +177,30 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if (type == 'tableForm') {
// 明细查询页赋值
if(formField == 'itemCode') {
+ if(tableData.value.find(item1=>item1['itemCode'] == val[0]['itemCode'])){
+ message.warning(`物料${val[0]['itemCode']}已经存在`)
+ return
+ }
+
const isType = await isItemType(val[0]['itemCode'], labelType.value)
if(!isType){
message.warning('当前物料可制造与其他数据不一致,请重新选择!')
} else {
+
row['batch'] = val[0]['batch']==''?formatTime(new Date(), 'yyyyMMdd'):val[0]['batch']
row['itemCode'] = val[0]['itemCode']
row['uom'] = val[0]['uom']
row['inventoryStatus'] = val[0]['inventoryStatus']
- row['qty'] = val[0]['qty']
+ row['qty'] = Number(val[0]['qty'])
// 修改 tableform 属性 数量最大值设置为库存余额中数量
- ProductionreturnRequestDetail.allSchemas.tableFormColumns.map(item => {
- if(item.field == 'qty') {
- item.tableForm.max = val[0]['qty']
- }
- if(item.field == 'batch') {
- item.tableForm.disabled = false
- }
- })
+ ProductionreturnRequestDetail.allSchemas.tableFormColumns.forEach(item => {
+ if(item.field == 'qty' && Number(val[0]['qty'])>item.tableForm.min) {
+ item.tableForm.max = Number(val[0]['qty'])
+ }
+ if(item.field == 'batch') {
+ item.tableForm.disabled = false
+ }
+ })
}
} else if(formField == 'workStationCode') {
val.forEach(item=>{
@@ -518,7 +524,7 @@ const openForm =async (type: string, row?: number) => {
/** 详情操作 */
const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"requestProductionreturnMainNo")
}
/** 删除按钮操作 */
@@ -710,7 +716,7 @@ const labelPrint = async (row) => {
// 批量打印--生产退料
const searchTableSuccess1 = async (formField, searchField, val, formRef, type, row) => {
-
+
console.log('批量打印',val)
// let rows:any = []
// val.forEach(item=>{
diff --git a/src/views/wms/issueManage/repleinsh/repleinshJobMain/index.vue b/src/views/wms/issueManage/repleinsh/repleinshJobMain/index.vue
index e9c5c7b07..d780368bc 100644
--- a/src/views/wms/issueManage/repleinsh/repleinshJobMain/index.vue
+++ b/src/views/wms/issueManage/repleinsh/repleinshJobMain/index.vue
@@ -316,7 +316,7 @@ const buttonTableClick = async (val, row) => {
/** 详情操作 */
const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"jobRepleinshMain")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/repleinsh/repleinshRecordMain/index.vue b/src/views/wms/issueManage/repleinsh/repleinshRecordMain/index.vue
index f88f486ac..5f1e898c8 100644
--- a/src/views/wms/issueManage/repleinsh/repleinshRecordMain/index.vue
+++ b/src/views/wms/issueManage/repleinsh/repleinshRecordMain/index.vue
@@ -141,7 +141,7 @@ const buttonTableClick = async (val, row) => {
/** 详情操作 */
const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"record_repleinsh_main")
}
/** 导出按钮操作 */
diff --git a/src/views/wms/issueManage/repleinsh/repleinshRequestMain/index.vue b/src/views/wms/issueManage/repleinsh/repleinshRequestMain/index.vue
index 47f275fad..b01025176 100644
--- a/src/views/wms/issueManage/repleinsh/repleinshRequestMain/index.vue
+++ b/src/views/wms/issueManage/repleinsh/repleinshRequestMain/index.vue
@@ -76,7 +76,7 @@
/>
-
@@ -116,7 +116,7 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
if(tableData.value.find(item1=>item1['itemCode'] == item['code'])){
message.warning(`物料${item['code']}已经存在`)
return
- }
+ }
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['itemCode'] = item['code']
newRow['uom'] = item['uom']
@@ -317,7 +317,7 @@ const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
- detailRef.value.openDetail(row, titleName, titleValue)
+ detailRef.value.openDetail(row, titleName, titleValue,"requestRepleinshMain")
}
/** 删除按钮操作 */
@@ -363,7 +363,7 @@ const tableData = ref([])
// 添加明细
const handleAddTable = () => {
tableData.value.push(JSON.parse(JSON.stringify(tableFormKeys)))
-
+
}
// 删除明细
const handleDeleteTable = (item, index) => {
diff --git a/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/index.vue b/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/index.vue
index 0aa1d217f..7c0b349df 100644
--- a/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/index.vue
+++ b/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/index.vue
@@ -133,6 +133,8 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
//到货主代码
row['toOwnerCode'] = val[0]['code']
}else if(formField == 'fromPackingNumber'){
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']&&item1['fromBatch']==item['batch']&&item1['fromPackingNumber']==item['packingNumber']&&item1['locationCode']==item['locationCode']&&item1['fromInventoryStatus']==item['inventoryStatus']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow[formField] = item[searchField]
diff --git a/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/inventorychangeRequestMain.data.ts b/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/inventorychangeRequestMain.data.ts
index b6e8cc592..5f543209e 100644
--- a/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/inventorychangeRequestMain.data.ts
+++ b/src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/inventorychangeRequestMain.data.ts
@@ -682,23 +682,41 @@ export const InventorychangeRequestDetail = useCrudSchemas(reactive
nextTick(() => {
if (type == 'tableForm') {
if(formField == 'fromPackingNumber'){
-
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']&&item1['fromBatch']==item['batch']&&item1['fromPackingNumber']==item['packingNumber']&&item1['fromLocationCode']==item['locationCode']&&item1['fromInventoryStatus']==item['inventoryStatus']))
+ if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow['fromPackingNumber'] = item['packingNumber']
diff --git a/src/views/wms/productionManage/productionplan/productionMain/index.vue b/src/views/wms/productionManage/productionplan/productionMain/index.vue
index c53a2a76f..e44583cff 100644
--- a/src/views/wms/productionManage/productionplan/productionMain/index.vue
+++ b/src/views/wms/productionManage/productionplan/productionMain/index.vue
@@ -120,6 +120,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
// })
if(formField=='itemCode'){
// row[formField] = val[0][searchField]
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item.itemCode))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(val.length==0) return
val.forEach(async item=>{
if(tableData.value.find(item1=>item1['id'] == item['id'])) return
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
diff --git a/src/views/wms/productionManage/productionplan/productionMainAssemble/index.vue b/src/views/wms/productionManage/productionplan/productionMainAssemble/index.vue
index 7e2c041af..c27dcfade 100644
--- a/src/views/wms/productionManage/productionplan/productionMainAssemble/index.vue
+++ b/src/views/wms/productionManage/productionplan/productionMainAssemble/index.vue
@@ -118,6 +118,13 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
// console.log(err);
// })
if(formField == 'itemCode'){
+ let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item.itemCode))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
+ if(val.length==0) return
val.forEach(async item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
newRow[formField] = item[searchField]
diff --git a/src/views/wms/productionManage/productionplan/productionMainAssemble/productionMainAssemble.data.ts b/src/views/wms/productionManage/productionplan/productionMainAssemble/productionMainAssemble.data.ts
index 6ba9cca28..32159d869 100644
--- a/src/views/wms/productionManage/productionplan/productionMainAssemble/productionMainAssemble.data.ts
+++ b/src/views/wms/productionManage/productionplan/productionMainAssemble/productionMainAssemble.data.ts
@@ -691,7 +691,8 @@ export const ProductionDetail = useCrudSchemas(reactive([
},
tableForm:{
multiple: true,
- enterSearch:true,
+ disabled: true,
+ // enterSearch:true,
// isInpuFocusShow: true,
searchListPlaceholder: '请选择物料代码', // 输入框占位文本
searchField: 'itemCode', // 查询弹窗赋值字段
diff --git a/src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue b/src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue
index 1e9dde54f..5006d4d04 100644
--- a/src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue
+++ b/src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue
@@ -210,6 +210,10 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
row['packQty'] = val[0]['packQty']
row[formField] = val[0][searchField]
}else if (formField == 'itemCode') {
+ if(tableData.value.find(item1=>item1['itemCode'] == val[0]['itemCode'])){
+ message.warning(`物料${val[0]['itemCode']}已经存在`)
+ return
+ }
row['uom'] = val[0]['uom']
row['produceDate'] = dayjs().valueOf()
row[formField] = val[0][searchField]
diff --git a/src/views/wms/productionManage/productreceiptAssemble/productreceiptAssembleRequestMain/index.vue b/src/views/wms/productionManage/productreceiptAssemble/productreceiptAssembleRequestMain/index.vue
index 491dc8daf..0ce049b13 100644
--- a/src/views/wms/productionManage/productreceiptAssemble/productreceiptAssembleRequestMain/index.vue
+++ b/src/views/wms/productionManage/productreceiptAssemble/productreceiptAssembleRequestMain/index.vue
@@ -211,6 +211,10 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
row['packQty'] = val[0]['packQty']
row[formField] = val[0][searchField]
}else if (formField == 'itemCode') {
+ if(tableData.value.find(item1=>item1['itemCode'] == val[0]['itemCode'])){
+ message.warning(`物料${val[0]['itemCode']}已经存在`)
+ return
+ }
row['uom'] = val[0]['uom']
row['produceDate'] = dayjs().valueOf()
row[formField] = val[0][searchField]
diff --git a/src/views/wms/productionManage/productredress/productredressRequestMain/index.vue b/src/views/wms/productionManage/productredress/productredressRequestMain/index.vue
index 086524541..85d9c1a37 100644
--- a/src/views/wms/productionManage/productredress/productredressRequestMain/index.vue
+++ b/src/views/wms/productionManage/productredress/productredressRequestMain/index.vue
@@ -131,6 +131,8 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
// 明细查询页赋值
row[formField] = val[0][searchField]
if (formField == 'itemCode') {
+ val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']&&item1['batch']==item['batch']&&item1['packingNumber']==item['packingNumber']&&item1['locationCode']==item['locationCode']&&item1['inventoryStatus']==item['inventoryStatus']))
+ if(val.length==0) return
val.forEach(item=>{
if(tableData.value.find(item1=>item1['itemCode'] == item['itemCode']&&item1['batch'] == item['batch']&&item1['packingNumber'] == item['packingNumber']&&item1['toLocationCode'] == item['locationCode']&&item1['inventoryStatus'] == item['inventoryStatus'])) return
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
diff --git a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue
index f32d747da..16f684f64 100644
--- a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue
+++ b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue
@@ -92,11 +92,11 @@
-
+
@@ -189,10 +189,12 @@ const buttonTableClick = async (val, row) => {
}
}
// 查看质检报告
+const reportHeight = ref(window.innerHeight - 120)
const showQualityReport = ref(false)
const qualityReport = ref('')
const checkQualityReport = async (row)=>{
showQualityReport.value = true
+ // qualityReport.value = "http://localhost/purchasereceiptReport?asnNumber=ASNS20240720-0002"
qualityReport.value = `${getReportUrl()}/purchasereceiptReport?asnNumber=${row.asnNumber}`
}
diff --git a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestMain/index.vue
index 761fe31c3..47aba1611 100644
--- a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestMain/index.vue
+++ b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestMain/index.vue
@@ -510,6 +510,13 @@ const searchTableSuccess1 = async (formField, searchField, val, formRef, type, r
}
const updateTableData = (tableList)=>{
+ let itemCodes = tableList.filter(item=>tableData.value.find(item1=>item1['poNumber']==item['number']&&item1['supplierCode']==item['supplierCode']&&item1['poLine']==item['lineNumber']&&item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item.itemCode))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ tableList = tableList.filter(item=>!tableData.value.find(item1=>item1['poNumber']==item['number']&&item1['supplierCode']==item['supplierCode']&&item1['poLine']==item['lineNumber']&&item1['itemCode']==item['itemCode']))
+ if(tableList.length==0) return
tableList.forEach(row=>{
//poNumber poLine itemCode batch
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...row}))
diff --git a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestOrderMTypeMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestOrderMTypeMain/index.vue
index 8863f857d..3aececbe4 100644
--- a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestOrderMTypeMain/index.vue
+++ b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestOrderMTypeMain/index.vue
@@ -487,6 +487,13 @@ const searchTableSuccess1 = async (formField, searchField, val, formRef, type, r
}
const updateTableData = (tableList)=>{
+ let itemCodes = tableList.filter(item=>tableData.value.find(item1=>item1['poNumber']==item['number']&&item1['supplierCode']==item['supplierCode']&&item1['poLine']==item['lineNumber']&&item1['itemCode']==item['itemCode']))
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item.itemCode))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ tableList = tableList.filter(item=>!tableData.value.find(item1=>item1['poNumber']==item['number']&&item1['supplierCode']==item['supplierCode']&&item1['poLine']==item['lineNumber']&&item1['itemCode']==item['itemCode']))
+ if(tableList.length==0) return
tableList.forEach(row=>{
//poNumber poLine itemCode batch
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...row}))
diff --git a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue
index 7875f9402..c63cf0ccf 100644
--- a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue
+++ b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMain/index.vue
@@ -719,7 +719,10 @@ const handleSubmit = async (id: number) => {
message.success(t('common.submitSuccess'))
await getList()
tableObject.loading = false
- } catch {}
+ } catch {
+ } finally {
+ tableObject.loading = false
+ }
}
/** 导出按钮操作 */
@@ -915,9 +918,11 @@ const submitForm = async (formType, submitData) => {
formRef.value.formLoading = false
return
}
+ data.returnSourceType='1'
await PurchasereturnRequestMainApi.createPurchasereturnRequestMain(data)
message.success(t('common.createSuccess'))
} else {
+ data.returnSourceType='1'
await PurchasereturnRequestMainApi.updatePurchasereturnRequestMain(data)
message.success(t('common.updateSuccess'))
}
diff --git a/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRecordSpareMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRecordSpareMain/index.vue
new file mode 100644
index 000000000..b45a912ed
--- /dev/null
+++ b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRecordSpareMain/index.vue
@@ -0,0 +1,198 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ row.number }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRecordSpareMain/purchasereturnRecordSpareMain.data.ts b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRecordSpareMain/purchasereturnRecordSpareMain.data.ts
new file mode 100644
index 000000000..98ed4935a
--- /dev/null
+++ b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRecordSpareMain/purchasereturnRecordSpareMain.data.ts
@@ -0,0 +1,903 @@
+import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
+import { dateFormatter,dateFormatter2 } from '@/utils/formatTime'
+
+/**
+ * @returns {Array} 采购退货记录主表
+ */
+export const PurchasereturnRecordMain = useCrudSchemas(reactive([
+ {
+ label: '单据号',
+ field: 'number',
+ sort: 'custom',
+ table: {
+ width: 190,
+ fixed: 'left'
+ },
+ sortTableDefault: 1012,
+ sortSearchDefault:1,
+ isSearch: true
+ },
+ {
+ label: '申请单号',
+ field: 'requestNumber',
+ sort: 'custom',
+ table: {
+ width: 190
+ },
+ isTable: true
+ },
+ // {
+ // label: '任务单号',
+ // field: 'jobNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // isTable: false
+ // },
+ // {
+ // label: '采购收货记录单号',
+ // field: 'purchaseReceiptRecordNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // isSearch: true,
+ // sortTableDefault: 3,
+ // sortSearchDefault: 5,
+ // },
+ // {
+ // label: 'qad采购退货记录单号',
+ // field: 'qadPurchaseReturnRecordCode',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // sortSearchDefault:3,
+ // sortTableDefault: 4,
+ // isTable: false
+ // },
+ // {
+ // label: '发货单号',
+ // field: 'asnNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // sortSearchDefault:3,
+ // isSearch: false,
+ // sortTableDefault: 2
+ // },
+ // {
+ // label: '要货计划单号',
+ // field: 'ppNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // isTable: false
+ // },
+ // {
+ // label: '供应商代码',
+ // field: 'supplierCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1,
+ // sortSearchDefault:2,
+ // isSearch: true
+ // },
+ {
+ label: '从月台代码',
+ field: 'fromDockCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '承运商',
+ field: 'carrierCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '运输方式',
+ field: 'transferMode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '车牌号',
+ field: 'vehiclePlateNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '从仓库代码',
+ field: 'fromWarehouseCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '到仓库代码',
+ field: 'toWarehouseCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '出库事务类型',
+ field: 'outTransactionType',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '入库事务类型',
+ field: 'inTransactionType',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false
+ },
+ {
+ label: '从库区类型范围',
+ field: 'fromAreaTypes',
+ dictType: DICT_TYPE.AREA_TYPE,
+ dictClass: 'string',
+ isTable: false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '到库区类型范围',
+ field: 'toAreaTypes',
+ dictType: DICT_TYPE.AREA_TYPE,
+ dictClass: 'string',
+ isTable: false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '从库区代码范围',
+ field: 'fromAreaCodes',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false,
+ },
+ {
+ label: '到库区代码范围',
+ field: 'toAreaCodes',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false,
+ },
+ {
+ label: '执行时间',
+ field: 'executeTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ isTable: false,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ },
+ {
+ label: '生效日期',
+ field: 'activeDate',
+ formatter: dateFormatter2,
+ detail: {
+ dateFormat: 'YYYY-MM-DD'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ isTable: false,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ style: {width: '100%'},
+ type: 'date',
+ dateFormat: 'YYYY-MM-DD',
+ valueFormat: 'x',
+ }
+ },
+ },
+ {
+ label: '申请时间',
+ field: 'requestTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ isTable: false,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ },
+ {
+ label: '截止时间',
+ field: 'dueTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ isTable: false,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ },
+ {
+ label: '部门',
+ field: 'departmentCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false,
+ },
+ // {
+ // label: '代码',
+ // field: 'code',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // },
+ {
+ label: '接口类型',
+ field: 'interfaceType',
+ dictType: DICT_TYPE.INTERFACE_TYPE,
+ dictClass: 'string',
+ isTable: false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '业务类型',
+ field: 'businessType',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false,
+ },
+ {
+ label: '是否可用',
+ field: 'available',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string',
+ isTable: false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '原因',
+ field: 'available',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '创建时间',
+ field: 'createTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ isTable: false,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ },
+ {
+ label: '创建者',
+ field: 'creator',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable: false,
+ },
+ // {
+ // label: '操作',
+ // field: 'action',
+ // isDetail: false,
+ // isForm: false,
+ // table: {
+ // width: 150,
+ // fixed: 'right'
+ // },
+ // }
+]))
+
+//表单校验
+export const PurchasereturnRecordMainRules = reactive({
+ requestNumber: [
+ { required: true, message: '请选择申请单号', trigger: 'change' }
+ ],
+ supplierCode: [
+ { required: true, message: '请选择供应商代码', trigger: 'change' }
+ ],
+ fromWarehouseCode: [
+ { required: true, message: '请选择从仓库代码', trigger: 'change' }
+ ],
+ fromAreaTypes: [
+ { required: true, message: '请选择从库区类型范围', trigger: 'change' }
+ ],
+ outTransaction: [
+ { required: true, message: '请输入出库事务类型', trigger: 'blur' }
+ ],
+ inTransaction: [
+ { required: true, message: '请输入入库事务类型', trigger: 'blur' }
+ ],
+ executeTime: [
+ { required: true, message: '请输入执行时间', trigger: 'change' }
+ ],
+ activeDate: [
+ { required: true, message: '请输入生效日期', trigger: 'change' }
+ ],
+ available: [
+ { required: true, message: '请输入是否可用', trigger: 'blur' }
+ ],
+ departmentCode: [
+ { required: true, message: '请输入部门', trigger: 'blur' }
+ ],
+ interfaceType: [
+ { required: true, message: '请选择接口类型', trigger: 'change' }
+ ],
+ number: [
+ { required: true, message: '请输入单据号', trigger: 'blur' }
+ ],
+ businessType: [
+ { required: true, message: '请输入业务类型', trigger: 'blur' }
+ ],
+ createTime: [
+ { required: true, message: '请选择创建时间', trigger: 'change' }
+ ],
+ creator: [
+ { required: true, message: '请输入创建者', trigger: 'blur' }
+ ],
+})
+
+/**
+ * @returns {Array} 采购退货记录子表
+ */
+export const PurchasereturnRecordDetail = useCrudSchemas(reactive([
+
+ {
+ label: '从包装号',
+ field: 'fromPackingNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isSearch: true,
+ sortTableDefault: 1001,
+ sortSearchDefault: 1001,
+ },
+ {
+ label: '到包装号',
+ field: 'toPackingNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isSearch: true,
+ hiddenInMain: true,
+ sortSearchDefault: 1002,
+ sortTableDefault: 1001,
+ },
+ // {
+ // label: '包装规格',
+ // field: 'packUnit',
+ // dictClass: 'string',
+ // isTable: true,
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1004,
+ // },
+ // {
+ // label: '包装数量',
+ // field: 'packQty',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1004,
+ // form: {
+ // component: 'InputNumber',
+ // }
+ // },
+ {
+ label: '退货数量',
+ field: 'qty',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'InputNumber',
+ componentProps: {
+ min: 0,
+ precision: 6,
+ disabled:false
+ }
+ },
+ sortTableDefault: 1004,
+ hiddenInMain:true,
+ isForm:false,
+ tableForm:{
+ type:'InputNumber',
+ min:0,
+ precision: 6,
+ disabled:false
+ }
+ },
+ {
+ label: '从器具号',
+ field: 'fromContainerNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable:false,
+ hiddenInMain: true
+ },
+ {
+ label: '到器具号',
+ field: 'toContainerNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable:false,
+ hiddenInMain: true
+ },
+ {
+ label: '从批次',
+ field: 'fromBatch',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isSearch: true,
+ sortTableDefault: 1000,
+ },
+ {
+ label: '到批次',
+ field: 'toBatch',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isSearch: true,
+ sortTableDefault: 1000,
+ hiddenInMain: true
+ },
+ {
+ label: '替代批次',
+ field: 'altBatch',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTable:false,
+ hiddenInMain: true
+ },
+ {
+ label: '从库位代码',
+ field: 'fromLocationCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1009,
+ hiddenInMain: true
+ },
+ // {
+ // label: '到库位代码',
+ // field: 'toLocationCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1009,
+ // hiddenInMain: true
+ // },
+ {
+ label: '从库位组代码',
+ field: 'fromLocationGroupCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1010,
+ hiddenInMain: true
+ },
+ // {
+ // label: '到库位组代码',
+ // field: 'toLocationGroupCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1010,
+ // hiddenInMain: true
+ // },
+ {
+ label: '从库区代码',
+ field: 'fromAreaCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1010,
+ hiddenInMain: true
+ },
+ // {
+ // label: '到库区代码',
+ // field: 'toAreaCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1010,
+ // hiddenInMain: true
+ // },
+ // {
+ // label: '从货主代码',
+ // field: 'fromOwnerCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1010,
+ // hiddenInMain: true
+ // },
+ // {
+ // label: '到货主代码',
+ // field: 'toOwnerCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 1010,
+ // hiddenInMain: true
+ // },
+ {
+ label: '库存状态',
+ field: 'inventoryStatus',
+ dictType: DICT_TYPE.INVENTORY_STATUS,
+ dictClass: 'string',
+ isTable: true,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1008,
+ hiddenInMain: true
+ },
+ // {
+ // label: '订单号',
+ // field: 'poNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 4,
+ // },
+ // {
+ // label: '订单行',
+ // field: 'poLine',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault: 5,
+ // },
+ {
+ label: '单据号',
+ field: 'number',
+ sort: 'custom',
+ table: {
+ width: 180,
+ },
+ sortTableDefault: 1013,
+ hiddenInMain: true,
+ isSearch: false
+ },
+ {
+ label: '原因',
+ field: 'reason',
+ dictType: DICT_TYPE.PURCHASE_RETURN_REASON,
+ dictClass: 'string',
+ isTable: true,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1013,
+ hiddenInMain: true
+ },
+
+ {
+ label: '物料代码',
+ field: 'itemCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isSearch: true,
+ sortSearchDefault: 6,
+ },
+ {
+ label: '物料名称',
+ field: 'itemName',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortSearchDefault: 6,
+ },
+ {
+ label: '物料描述1',
+ field: 'itemDesc1',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortSearchDefault: 7,
+ hiddenInMain: true
+ },
+ {
+ label: '物料描述2',
+ field: 'itemDesc2',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortSearchDefault: 7,
+ hiddenInMain: true
+ },
+ // {
+ // label: '数量',
+ // field: 'qty',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isTable:true,
+ // sortTableDefault: 1005,
+ // form: {
+ // component: 'InputNumber',
+ // }
+ // },
+ {
+ label: '计量单位',
+ field: 'uom',
+ dictType: DICT_TYPE.UOM,
+ dictClass: 'string',
+ isTable: true,
+ sortTableDefault: 1006,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '单价',
+ field: 'singlePrice',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ hiddenInMain:true,
+ sortTableDefault: 1006,
+ form: {
+ component: 'InputNumber',
+ }
+ },
+ {
+ label: '金额',
+ field: 'amount',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ hiddenInMain:true,
+ sortTableDefault: 1006,
+ form: {
+ component: 'InputNumber',
+ }
+ },
+ {
+ label: '项目代码',
+ field: 'projectCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1011,
+ hiddenInMain: true
+ },
+ // {
+ // label: '代码',
+ // field: 'code',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // },
+ {
+ label: '接口类型',
+ field: 'interfaceType',
+ dictType: DICT_TYPE.INTERFACE_TYPE,
+ dictClass: 'string',
+ isTable: false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ hiddenInMain: true
+ },
+ // {
+ // label: '任务明细ID',
+ // field: 'jobDetailId',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // },
+ {
+ label: '原因',
+ field: 'remark',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1007,
+ hiddenInMain: true
+ },
+ {
+ label: '创建者',
+ field: 'creator',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault: 1014,
+ },
+ {
+ label: '创建时间',
+ field: 'createTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ sortTableDefault: 1014,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ },
+]))
+
+//表单校验
+export const PurchasereturnRecordDetailRules = reactive({
+ fromPackingNumber: [
+ { required: true, message: '请选择从包装号', trigger: 'change' }
+ ],
+ toPackingNumber: [
+ { required: true, message: '请选择到包装号', trigger: 'change' }
+ ],
+ fromBatch: [
+ { required: true, message: '请输入从批次', trigger: 'blur' }
+ ],
+ toBatch: [
+ { required: true, message: '请输入到批次', trigger: 'blur' }
+ ],
+ reason: [
+ { required: true, message: '请选择原因', trigger: 'change' }
+ ],
+ fromLocationCode: [
+ { required: true, message: '请选择从库位代码', trigger: 'change' }
+ ],
+ fromLocationGroupCode: [
+ { required: true, message: '请选择从库位组代码', trigger: 'change' }
+ ],
+ fromAreaCode: [
+ { required: true, message: '请选择从库区代码', trigger: 'change' }
+ ],
+ inventoryStatus: [
+ { required: true, message: '请选择库存状态', trigger: 'change' }
+ ],
+ poNumber: [
+ { required: true, message: '请选择订单号', trigger: 'change' }
+ ],
+ poline: [
+ { required: true, message: '请选择订单行', trigger: 'change' }
+ ],
+})
diff --git a/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRequestSpareMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRequestSpareMain/index.vue
new file mode 100644
index 000000000..758a5cfff
--- /dev/null
+++ b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRequestSpareMain/index.vue
@@ -0,0 +1,1017 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ row.number }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRequestSpareMain/purchasereturnRequestSpareMain.data.ts b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRequestSpareMain/purchasereturnRequestSpareMain.data.ts
new file mode 100644
index 000000000..cfe8ea285
--- /dev/null
+++ b/src/views/wms/purchasereceiptManage/purchasereturnspare/purchasereturnRequestSpareMain/purchasereturnRequestSpareMain.data.ts
@@ -0,0 +1,1674 @@
+import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
+import { dateFormatter,dateFormatter2 } from '@/utils/formatTime'
+const { t } = useI18n() // 国际化
+import * as getRequestsettingApi from '@/api/wms/requestsetting/index'
+import { Itempackaging } from '@/views/wms/basicDataManage/itemManage/itempackage/itempackage.data'
+import * as ItemPackageApi from '@/api/wms/itempackage/index'
+import * as LocationApi from "@/api/wms/location";
+import {Location} from "@/views/wms/basicDataManage/factoryModeling/location/location.data";
+import * as BalanceApi from '@/api/wms/balance'
+import { Balance } from '@/views/wms/inventoryManage/balance/balance.data'
+
+
+
+// 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值
+const queryParams = {
+ pageSize:10,
+ pageNo:1,
+ code:'PurchaseReturnRequest'
+}
+ const data = await getRequestsettingApi.getRequestsettingPage(queryParams)
+ const requestsettingData =data?.list[0]||{}
+
+ // 获取当前操作人的部门
+ import { useUserStore } from '@/store/modules/user'
+ import { TableColumn } from '@/types/table'
+ const userStore = useUserStore()
+ const userDept = userStore.userSelfInfo.dept
+ // id 转str 否则form回显匹配不到
+ userDept.id = userDept.id.toString()
+ const userDeptArray:any = [userDept]
+
+
+// 采购收货记录展示列
+export const PurchasereceiptRecordMain1 = useCrudSchemas(reactive([
+ {
+ 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
+ },
+ 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} 采购退货申请主表
+ */
+export const PurchasereturnRequestMain = useCrudSchemas(reactive([
+ {
+ label: '单据号',
+ field: 'number',
+ sort: 'custom',
+ table: {
+ width: 180,
+ fixed: 'left'
+ },
+ isForm: false,
+ isSearch: true,
+ },
+ {
+ label: '状态',
+ field: 'status',
+ dictType: DICT_TYPE.REQUEST_STATUS,
+ dictClass: 'string',
+ isSearch: true,
+ isTable: true,
+ isForm:false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ sortTableDefault:1,
+ form: {
+ value: '1',
+ componentProps: {
+ disabled: true
+ }
+ }
+ },
+ // {
+ // label: '供应商代码',
+ // field: 'supplierCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // sortTableDefault:1,
+ // isSearch: true,
+ // form:{
+ // componentProps:{
+ // enterSearch: true,
+ // isSearchList: true, // 开启查询弹窗
+ // searchListPlaceholder: '请选择供应商代码', // 输入框占位文本
+ // searchField: 'code', // 查询弹窗赋值字段
+ // searchTitle: '供应商信息', // 查询弹窗标题
+ // searchAllSchemas: Supplier.allSchemas, // 查询弹窗所需类
+ // searchPage: SupplierApi.getSupplierPage, // 查询弹窗所需分页方法
+ // verificationParams: [{
+ // key: 'code',
+ // action: '==',
+ // value: '',
+ // isMainValue: false,
+ // isSearch: true,
+ // isFormModel: true,
+ // }], // 失去焦点校验参数
+ // }
+ // }
+ // },
+ // {
+ // label: '维修备件收货记录单号',
+ // field: 'purchaseReceiptRecordNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // form: {
+ // // labelMessage: '信息提示说明!!!',
+ // componentProps: {
+ // enterSearch: true,
+ // disabled:true,
+ // isSearchList: true, // 开启查询弹窗
+ // searchListPlaceholder: '请选择采购收货记录单号', // 输入框占位文本
+ // searchField: 'number', // 查询弹窗赋值字段
+ // searchTitle: '采购收货记录', // 查询弹窗标题
+ // searchAllSchemas: PurchasereceiptRecordMain1.allSchemas, // 查询弹窗所需类
+ // searchPage: PurchasereceiptRecordDetailApi.getPurchasereceiptRecordDetailPageReturn, // 查询弹窗所需分页方法
+ // searchCondition: [
+ // {
+ // key: 'supplierCode',
+ // value: 'supplierCode',
+ // isMainValue: true
+ // }],
+ // verificationParams: [{
+ // key: 'number',
+ // action: '==',
+ // value: '',
+ // isMainValue: false,
+ // isSearch: true,
+ // isFormModel: true,
+ // }], // 失去焦点校验参数
+ // }
+ // }
+ // },
+ // {
+ // label: '发货单号',
+ // field: 'asnNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // isForm: false,
+ // sortTableDefault:2
+ // },
+ // {
+ // label: '要货计划单号',
+ // field: 'ppNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // isForm: false,
+ // isTable: false,
+ // },
+ // {
+ // label: '承运商',
+ // field: 'carrierCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isTable: false,
+ // },
+ // {
+ // label: '运输方式',
+ // field: 'transferMode',
+ // sort: 'custom',
+ // dictType: DICT_TYPE.TRANSFER_MODE,
+ // dictClass: 'string',
+ // table: {
+ // width: 150
+ // },
+ // isTable: false,
+ // },
+ // {
+ // label: '车牌号',
+ // field: 'vehiclePlateNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isTable: false,
+ // },
+ // {
+ // label: '从仓库代码',
+ // field: 'fromWarehouseCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isForm: false,
+ // isTable: false,
+ // },
+ // {
+ // label: '到仓库代码',
+ // field: 'toWarehouseCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isTableForm:false,
+ // isForm: false,
+ // isTable: false,
+ // },
+ // {
+ // label: '从库区类型范围',
+ // field: 'fromAreaTypes',
+ // dictType: DICT_TYPE.AREA_TYPE,
+ // dictClass: 'string',
+ // isTable: false,
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isForm: false,
+ // },
+ // {
+ // label: '到库区类型范围',
+ // field: 'toAreaTypes',
+ // dictType: DICT_TYPE.AREA_TYPE,
+ // dictClass: 'string',
+ // isTable: false,
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isTableForm:false,
+ // isForm: false,
+ // },
+ // {
+ // label: '从库区代码范围',
+ // field: 'fromAreaCodes',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isForm: false,
+ // isTable: false,
+ // },
+ // {
+ // label: '到库区代码范围',
+ // field: 'toAreaCodes',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isForm: false,
+ // isTable: false,
+ // isTableForm:false,
+ // },
+ // {
+ // label: '从月台代码',
+ // field: 'fromDockCode',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isForm: false,
+ // isTable: false,
+
+ // },
+ {
+ label: '业务类型',
+ field: 'businessType',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ value: 'PurchaseReturn',
+ componentProps: {
+ disabled: true
+ }
+ },
+ isForm: false,
+ isTable: false,
+ },
+ // {
+ // label: '申请时间',
+ // field: 'requestTime',
+ // formatter: dateFormatter,
+ // detail: {
+ // dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ // },
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // form: {
+ // component: 'DatePicker',
+ // componentProps: {
+ // style: {width:'100%'},
+ // type: 'datetime',
+ // dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ // valueFormat: 'x',
+ // }
+ // },
+ // isForm: false,
+ // isTable: false,
+ // },
+ {
+ label: '截止时间',
+ field: 'dueTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ isForm:false,
+ isTableForm:false,
+ isTable: false,
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ style: {width:'100%'},
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ },
+ {
+ label: '部门',
+ field: 'departmentCode',
+ sort: 'custom',
+ isForm:false,
+ table: {
+ width: 150
+ },
+ isTable: false,
+ formatter: (_: Recordable, __: TableColumn, cellValue: number) => {
+ return userDeptArray.find((account) => account.id == cellValue)?.name
+ },
+ form: {
+ value: userDept.id,
+ component: 'Select',
+ api: () => userDeptArray,
+ componentProps: {
+ disabled: true,
+ optionsAlias: {
+ labelField: 'name',
+ valueField: 'id'
+ }
+ }
+ }
+ },
+ {
+ label: '原因',
+ field: 'remark',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ },
+ {
+ label: '创建时间',
+ field: 'createTime',
+ isForm: false,
+ table: {
+ width: 180
+ },
+ formatter: dateFormatter,
+ detail: {
+ dateFormat : 'YYYY-MM-DD HH:mm:ss'
+ },
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ style: {width:'100%'},
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ isTable:false,
+ },
+ {
+ label: '创建者',
+ field: 'creator',
+ table: {
+ width: 130
+ },
+ isForm: false,
+ isTable: false
+ },
+ {
+ label: '最后更新时间',
+ field: 'updateTime',
+ sort: 'custom',
+ isDetail: true,
+ isForm: false,
+ isTable: false,
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ table: {
+ width: 180
+ },
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ style: {width:'100%'},
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ }
+ },
+ {
+ label: '最后更新者',
+ field: 'updater',
+ isDetail: true,
+ isForm: false,
+ isTable: false,
+ table: {
+ width: 150
+ }
+ },
+ {
+ label: '自动提交',
+ field: 'autoCommit',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string',
+ isTable: false,
+ isForm:false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'Switch',
+ value: requestsettingData.autoCommit,
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE',
+ disabled: true
+ }
+ }
+ },
+ {
+ label: '自动通过',
+ field: 'autoAgree',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string',
+ isTable: false,
+ isForm:false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'Switch',
+ value: requestsettingData.autoAgree,
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE',
+ disabled: true
+ }
+ }
+ },
+ {
+ label: '自动执行',
+ field: 'autoExecute',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string',
+ isTable: false,
+ isForm:false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'Switch',
+ value: requestsettingData.autoExecute,
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE',
+ disabled: true
+ }
+ }
+ },
+ {
+ label: '直接生成记录',
+ field: 'directCreateRecord',
+ dictType: DICT_TYPE.TRUE_FALSE,
+ dictClass: 'string',
+ isForm: false,
+ isTable: false,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'Switch',
+ value: requestsettingData.directCreateRecord,
+ componentProps: {
+ inactiveValue: 'FALSE',
+ activeValue: 'TRUE',
+ disabled: true
+ }
+ }
+ },
+ {
+ label: '操作',
+ field: 'action',
+ isDetail: false,
+ isForm: false,
+ table: {
+ width: 300,
+ fixed: 'right'
+ },
+ }
+]))
+
+//表单校验
+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} 采购退货申请子表
+ */
+export const PurchasereturnRequestDetail = useCrudSchemas(reactive([
+ // {
+ // label: '订单号',
+ // field: 'poNumber',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // tableForm:{
+ // disabled:true
+ // },
+ // form: {
+ // componentProps:{
+ // disabled:true
+ // }
+ // }
+ // },
+ // {
+ // label: '订单行',
+ // field: 'poLine',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // tableForm:{
+ // isInpuFocusShow: false, // 开启查询弹窗
+ // searchListPlaceholder: '请选择订单行',
+ // searchField: 'poLine',
+ // searchTitle: '采购收货记录信息',
+ // searchAllSchemas: PurchasereceiptRecordDetail.allSchemas,
+ // searchPage: PurchasereceiptRecordDetailApi.getPurchasereceiptRecordDetailPage,
+ // searchCondition: [{
+ // key: 'number',
+ // value: 'purchaseReceiptRecordNumber',
+ // message: '请填写采购收货记录号!',
+ // isMainValue: true
+ // }]
+ // },
+ // form: {
+ // // labelMessage: '信息提示说明!!!',
+ // componentProps: {
+ // isSearchList: false,
+ // searchListPlaceholder: '请选择订单行',
+ // searchField: 'poLine',
+ // searchTitle: '采购收货记录信息',
+ // searchAllSchemas: PurchasereceiptRecordDetail.allSchemas,
+ // searchPage: PurchasereceiptRecordDetailApi.getPurchasereceiptRecordDetailPage,
+ // searchCondition: [{
+ // key: 'number',
+ // value: 'purchaseReceiptRecordNumber',
+ // message: '请填写采购收货记录号!',
+ // isMainValue: true
+ // }]
+ // }
+ // },
+ // },
+ {
+ label: '物料代码',
+ field: 'itemCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ isInpuFocusShow: true, // 开启查询弹窗
+ searchListPlaceholder: '请选择包装号',
+ searchField: 'packingNumber',
+ searchTitle: '库存余额信息',
+ searchAllSchemas: Balance.allSchemas,
+ searchPage: BalanceApi.getBalancePageSpare,
+ searchCondition: [{
+ key: 'available',
+ value: 'TRUE',
+ action: '==',
+ isSearch: true,
+ isMainValue: false
+ },{
+ key: 'businessType',
+ value: 'PurchaseReturnSpare',
+ action: '==',
+ isSearch: true,
+ isMainValue: false
+ },{
+ key: 'inOrOut',
+ value: 'out',
+ action: '==',
+ isSearch: true,
+ isMainValue: false
+ }]
+ },
+ form: {
+ // labelMessage: '信息提示说明!!!',
+ componentProps: {
+ disabled:true,
+ isSearchList: true, // 开启查询弹窗
+ searchListPlaceholder: '请选择包装号',
+ searchField: 'packingNumber',
+ searchTitle: '库存余额信息',
+ searchAllSchemas: Balance.allSchemas,
+ searchPage: BalanceApi.getBalancePageSpare,
+ searchCondition: [{
+ key: 'available',
+ value: 'TRUE',
+ action: '==',
+ isSearch: true,
+ isMainValue: false
+ },{
+ key: 'businessType',
+ value: 'PurchaseReturnSpare',
+ action: '==',
+ isSearch: true,
+ isMainValue: false
+ },{
+ key: 'inOrOut',
+ value: 'out',
+ action: '==',
+ isSearch: true,
+ isMainValue: false
+ }]
+ }
+ }
+ },
+ {
+ label: '物料名称',
+ field: 'itemName',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '物料描述1',
+ field: 'itemDesc1',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTableForm:false,
+ isTable:false,
+ hiddenInMain: true,
+ isForm: false,
+ tableForm:{
+ disabled:true
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '物料描述2',
+ field: 'itemDesc2',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ isTableForm:false,
+ isTable:false,
+ hiddenInMain: true,
+ isForm: false,
+ tableForm:{
+ disabled:true
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '批次',
+ field: 'batch',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '替代批次',
+ field: 'altBatch',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ hiddenInMain: true,
+ isTableForm: false,
+ isTable: false,
+ isForm: false,
+ tableForm:{
+ disabled:true
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '器具号',
+ field: 'containerNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ hiddenInMain: true,
+ tableForm:{
+ disabled:true
+ },
+ isTableForm: false,
+ isTable: false,
+ isForm: false,
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '计量单位',
+ field: 'uom',
+ dictType: DICT_TYPE.UOM,
+ dictClass: 'string',
+ // isSearch: true,
+ isTable: true,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true,
+ type: 'Select',
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '退货数量',
+ field: 'qty',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'InputNumber',
+ componentProps: {
+ min: 0,
+ precision: 6,
+ disabled:false
+ }
+ },
+ isTable:false,
+ isTableForm:false,
+ tableForm:{
+ disabled:true,
+ type:'InputNumber',
+ min:0,
+ precision: 6
+ }
+ },
+ // { //与国强联调的时候发现退货数量用的是qty
+ // label: '退货数量',
+ // field: 'returnedQty',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // form: {
+ // component: 'InputNumber',
+ // componentProps: {
+ // min: 0,
+ // precision: 6,
+ // disabled:false
+ // }
+ // },
+ // isTable: false,
+ // isTableForm: false,
+ // isForm:false,
+ // tableForm:{
+ // type:'InputNumber',
+ // min:0,
+ // precision: 6,
+ // disabled:false
+ // }
+ // },
+ {
+ label: '从库位代码',
+ field: 'fromLocationCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true,
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '包装号',
+ field: 'packingNumber',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true,
+ },
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '库存余额',
+ field: 'inventoryBalance',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'InputNumber',
+ componentProps: {
+ disabled: true,
+ min: 0,
+ precision: 6
+ }
+ },
+ tableForm:{
+ hidden:false,//控制列是否展示
+ type:'InputNumber',
+ min:0,
+ precision: 6,
+ disabled:true,
+ },
+ hiddenInMain: true,
+ isTable: false,
+ isDetail: false,
+ },
+ {
+ label: '退货数量',
+ field: 'qty',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ form: {
+ component: 'InputNumber',
+ componentProps: {
+ min: 0,
+ precision: 6
+ }
+ },
+ isForm:false,
+ tableForm:{
+ type:'InputNumber',
+ min:0,
+ precision: 6
+ }
+ },
+ {
+ label: '库存状态',
+ field: 'inventoryStatus',
+ dictType: DICT_TYPE.INVENTORY_STATUS,
+ dictClass: 'string',
+ isSearch: true,
+ hiddenInMain: true,
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true,
+ type: 'Select',
+ },
+ isTableForm: false,
+ isTable: false,
+ isForm: false,
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '到库位代码',
+ field: 'toLocationCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ hiddenInMain: true,
+ isTableForm: false,
+ isTable: false,
+ isForm: false,
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '从货主代码',
+ field: 'fromOwnerCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ hiddenInMain: true,
+ isTableForm: false,
+ isTable: false,
+ isForm: false,
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ {
+ label: '到货主代码',
+ field: 'toOwnerCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ hiddenInMain: true,
+ isTableForm: false,
+ isTable: false,
+ isForm: false,
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ }
+ },
+ // {
+ // label: '到货日期',
+ // field: 'arriveDate',
+ // formatter: dateFormatter2,
+ // detail: {
+ // dateFormat: 'YYYY-MM-DD'
+ // },
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // hiddenInMain: true,
+ // form: {
+ // component: 'DatePicker',
+ // componentProps: {
+ // style: {width: '100%'},
+ // type: 'date',
+ // dateFormat: 'YYYY-MM-DD',
+ // valueFormat: 'x',
+ // }
+ // },
+ // tableForm:{
+ // disabled:true,
+ // type: 'FormDate',
+ // dateFormat: 'YYYY-MM-DD',
+ // valueFormat: 'x',
+ // },
+ // isTableForm: false
+ // },
+ // {
+ // label: '生产日期',
+ // field: 'produceDate',
+ // formatter: dateFormatter2,
+ // detail: {
+ // dateFormat: 'YYYY-MM-DD'
+ // },
+ // hiddenInMain: true,
+ // 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',
+ // format: 'YYYY-MM-DD',
+ // valueFormat: 'x',
+ // },
+ // isTableForm: false
+ // },
+ // {
+ // label: '过期日期',
+ // field: 'expireDate',
+ // formatter: dateFormatter2,
+ // detail: {
+ // dateFormat: 'YYYY-MM-DD'
+ // },
+ // sort: 'custom',
+ // table: {
+ // width: 180
+ // },
+ // hiddenInMain: true,
+ // form: {
+ // component: 'DatePicker',
+ // componentProps: {
+ // disabled: true,
+ // style: {width: '100%'},
+ // type: 'date',
+ // dateFormat: 'YYYY-MM-DD',
+ // valueFormat: 'x',
+ // }
+ // },
+ // isTableForm: false,
+ // isTable: false,
+ // tableForm:{
+ // disabled:true,
+ // type: 'FormDate',
+ // format: 'YYYY-MM-DD',
+ // valueFormat: 'x',
+ // }
+ // },
+ // {
+ // label: '任务明细ID',
+ // field: 'jobDetailId',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // tableForm:{
+ // disabled:true
+ // },
+ // isTableForm:false,
+ // hiddenInMain: true,
+ // isForm:false,
+ // form: {
+ // componentProps:{
+ // disabled:true
+ // }
+ // },
+ // },
+ {
+ label: '项目代码',
+ field: 'projectCode',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ isForm: false,
+ isTableForm: false,
+ isTable: false,
+ hiddenInMain: true,
+ form: {
+ componentProps:{
+ disabled:true
+ }
+ },
+ },
+
+ {
+ label: '单据号',
+ field: 'number',
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ hiddenInMain: true,
+ tableForm:{
+ disabled:true
+ },
+ isForm: false,
+ isTableForm:false,
+ },
+ // {
+ // label: '接口类型',
+ // field: 'interfaceType',
+ // dictType: DICT_TYPE.INTERFACE_TYPE,
+ // dictClass: 'string',
+ // isSearch: true,
+ // isTable: true,
+ // hiddenInMain: true,
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // tableForm:{
+ // disabled:true
+ // },
+ // isForm:false,
+ // isTableForm:false,
+ // form: {
+ // componentProps:{
+ // disabled:true
+ // }
+ // },
+ // },
+ // {
+ // label: '备注',
+ // field: 'remark',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // tableForm:{
+ // disabled:true
+ // },
+ // isTableForm: false,
+ // isTable: false,
+ // hiddenInMain: true,
+ // isForm: false,
+ // form: {
+ // componentProps:{
+ // disabled:true
+ // }
+ // },
+ // },
+ {
+ label: '创建者',
+ field: 'creator',
+ sort: 'custom',
+ table: {
+ width: 150
+ },
+ tableForm:{
+ disabled:true
+ },
+ isTableForm:false,
+ isForm:false
+ },
+ {
+ label: '创建时间',
+ field: 'createTime',
+ formatter: dateFormatter,
+ detail: {
+ dateFormat: 'YYYY-MM-DD HH:mm:ss'
+ },
+ sort: 'custom',
+ table: {
+ width: 180
+ },
+ form: {
+ component: 'DatePicker',
+ componentProps: {
+ type: 'datetime',
+ dateFormat: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'x',
+ }
+ },
+ tableForm:{
+ disabled:true
+ },
+ isTableForm:false,
+ isForm:false
+ },
+ // {
+ // label: '原因',
+ // field: 'remark',
+ // sort: 'custom',
+ // table: {
+ // width: 150
+ // },
+ // isTable: false,
+ // },
+ {
+ label: '操作',
+ hiddenInMain:true,
+ field: 'action',
+ isDetail: false,
+ isForm: false ,
+ table: {
+ width: 150,
+ fixed: 'right'
+ },
+ isTableForm:false,
+ }
+]))
+
+//表单校验
+export const PurchasereturnRequestDetailRules = reactive({
+ // packingNumber: [
+ // { required: true, message: '请输入包装号', trigger: 'blur' }
+ // ],
+ // batch: [
+ // { required: true, message: '请输入批次', trigger: 'blur' }
+ // ],
+ // inventoryStatus: [
+ // { required: true, message: '请选择库存状态', trigger: 'change' }
+ // ],
+ // poNumber: [
+ // { required: true, message: '请输入订单号', trigger: 'blur' }
+ // ],
+ // poLine: [
+ // { required: true, message: '请输入订单行', trigger: 'blur' }
+ // ],
+ // reason: [
+ // { required: true, message: '请选择原因', trigger: 'change' }
+ // ],
+ itemCode: [
+ { required: true, message: '请输入物料代码', trigger: 'blur' }
+ ],
+ remark: [
+ { max: 50, message: '不得超过50个字符', trigger: 'blur' }
+ ],
+})
+
+export const PurchasereReturnRequestDetailLabel = useCrudSchemas(reactive([
+ {
+ 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
+ },
+]))
+
diff --git a/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/index.vue b/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/index.vue
index ffd5f3682..79b6e7f5e 100644
--- a/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/index.vue
+++ b/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/index.vue
@@ -221,6 +221,16 @@ const onEnter = async (field,value)=>{
getSearchTableData(value,true)
}
const updateTableData = (tableList)=>{
+ console.log('tableList',tableList)
+ let itemCodes = tableList.filter(item=>tableData.value.find(item1=>item1['poNumber']==item['number']&&item1['supplierCode']==item['supplierCode']&&item1['poLine']==item['lineNumber']&&item1['itemCode']==item['itemCode']))
+ console.log('itemCodes',itemCodes)
+
+ if(itemCodes.length>0){
+ itemCodes = itemCodes.map(item=>(item.itemCode))
+ message.warning(`物料${itemCodes.join(',')}已经存在`)
+ }
+ tableList = tableList.filter(item=>!tableData.value.find(item1=>item1['poNumber']==item['number']&&item1['supplierCode']==item['supplierCode']&&item1['poLine']==item['lineNumber']&&item1['itemCode']==item['itemCode']))
+ if(tableList.length==0) return
tableList.forEach(row=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...row}))
newRow['poLine'] = row['lineNumber']
diff --git a/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts b/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts
index c3e136109..428dbde25 100644
--- a/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts
+++ b/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts
@@ -619,6 +619,7 @@ export const PurchasereceiptRequestDetail = useCrudSchemas(reactive
+ :allSchemas="PurchasePlanMain.allSchemas" :detailAllSchemas="PurchasePlanDetail.allSchemas">
+
+
+ 计划数量包含0
+
+
+
+
@@ -80,7 +87,7 @@
/>
+ @success="importSuccess" :updateIsDisable="false" :appendIsDisable="true" :coverIsDisable="true" :mode="1" :coverIsShow="false" :appendIsShow="false"/>
@@ -281,6 +288,7 @@ const getSearchTableData = async (number,formField,searchField)=>{
}
const { tableObject, tableMethods } = useTable({
+ defaultParams:{isZero:1},
getListApi: PurchasePlanDetailApi.getPurchasePlanDetailPage // 分页接口
})
@@ -332,6 +340,7 @@ const getSearchTableData = async (number,formField,searchField)=>{
} else if (val=='mainOrderSelectionPub'){// 批量发布
handleSelectionPublish()
} else if (val == 'filtrate') { // 筛选
+ console.log('筛选',tableObject)
} else { // 其他按钮
console.log('其他按钮', item)
}
@@ -510,7 +519,26 @@ const { wsCache } = useCache()
tableObject.loading = false
}
}
+
+ const isZero = ref(false)
+ const zeroChange = ()=>{
+ // isZero.value
+ if(tableObject.params.isSearch){
+ tableObject.params.filters = tableObject.params.filters.filter(item=>item.column!='isZero')
+ tableObject.params.filters = [...tableObject.params.filters,{
+ action: "==",
+ column: "isZero",
+ value: isZero.value?0:1
+ }]
+ }else{
+ tableObject.params.isZero = isZero.value?0:1
+ }
+ getList()
+ console.log('tableObject',tableObject)
+ }
const searchList = (model)=>{
+ model.isZero = isZero.value?0:1
+ console.log('model',model)
selectionRows.value = []
setSearchParams(model)
}
@@ -634,6 +662,7 @@ const handleSelectionPublish = async ()=>{
}
const handleExportDetails = async () => {
+ console.log('tableObject.params',tableObject.params)
try {
// 导出的二次确认
await message.exportConfirm()
@@ -807,9 +836,14 @@ const handleSelectionPublish = async ()=>{
// 筛选提交
const searchFormClick = (searchData) => {
+ searchData.filters = searchData.filters.filter(item=>item.column!='isZero')
tableObject.params = {
isSearch: true,
- filters: searchData.filters
+ filters: [...searchData.filters,{
+ action: "==",
+ column: "isZero",
+ value: isZero.value?0:1
+ }]
}
getList() // 刷新当前列表
}
diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts b/src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts
index 2f5c2006f..5657b9cb8 100644
--- a/src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts
+++ b/src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts
@@ -75,7 +75,8 @@ export const PurchasePlanMain = useCrudSchemas(reactive([
component: 'DatePicker',
componentProps: {
valueFormat: 'YYYY-MM-DD HH:mm:ss',
- type: 'datetimerange',
+ // type: 'datetimerange',
+ type: 'daterange',
defaultTime: [new Date('1 '), new Date('1 ')]
}
},
@@ -518,6 +519,7 @@ export const PurchasePlanDetail = useCrudSchemas(reactive([
componentProps: {
dialogWidth:'1085px',//搜索出来弹窗的宽度
isSearchList: true,
+ enterSearch: true,
searchListPlaceholder: '请选择采购订单',
searchField: 'number',
searchTitle: '采购订单信息',