From 7be58c4649fa8de327988819c74e33d676324f29 Mon Sep 17 00:00:00 2001
From: fengyuan_yang <1976974459@qq.com>
Date: Tue, 24 Sep 2024 14:13:59 +0800
Subject: [PATCH] =?UTF-8?q?2024-09-24=20RFQ=20=E5=8A=9F=E8=83=BD=E4=BC=98?=
=?UTF-8?q?=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/modules/part/bomManagement.vue | 55 ++-
src/views/modules/part/partInformation.vue | 388 +++++++++++++------
src/views/modules/part/routingManagement.vue | 89 ++---
3 files changed, 329 insertions(+), 203 deletions(-)
diff --git a/src/views/modules/part/bomManagement.vue b/src/views/modules/part/bomManagement.vue
index e25faeb..4b2f9c1 100644
--- a/src/views/modules/part/bomManagement.vue
+++ b/src/views/modules/part/bomManagement.vue
@@ -2752,24 +2752,26 @@ export default {
// 物料编码失焦事件
partNoBlur () {
- this.partData.limit = this.pageSize2
- this.partData.page = this.pageIndex2
- this.partData.site = this.modalData.bu.split('_')[0]
- this.partData.buNo = this.modalData.bu.split('_')[1]
- this.partData.partNo = this.modalData.partNo
- queryPartList(this.partData).then(({data}) => {
- if (data && data.code === 0) {
- if (data.page.list.length === 1) {
- this.modalData.partDesc = data.page.list[0].partDesc
- this.modalData.printUnit = data.page.list[0].printUnit
- this.modalData.printUnitName = data.page[0].printUnitName
- } else {
- this.modalData.partDesc = ''
- this.modalData.printUnit = ''
- this.modalData.printUnitName = ''
+ if (this.modalData.partNo != null && this.modalData.partNo !== '') {
+ this.partData.limit = this.pageSize2
+ this.partData.page = this.pageIndex2
+ this.partData.site = this.modalData.bu.split('_')[0]
+ this.partData.buNo = this.modalData.bu.split('_')[1]
+ this.partData.partNo = this.modalData.partNo
+ queryPartList(this.partData).then(({data}) => {
+ if (data && data.code === 0) {
+ if (data.page.list.length === 1) {
+ this.modalData.partDesc = data.page.list[0].partDesc
+ this.modalData.printUnit = data.page.list[0].printUnit
+ this.modalData.printUnitName = data.page[0].printUnitName
+ return
+ }
}
- }
- })
+ })
+ }
+ this.modalData.partDesc = ''
+ this.modalData.printUnit = ''
+ this.modalData.printUnitName = ''
},
/**
@@ -2917,15 +2919,14 @@ export default {
this.componentData.componentPartDesc = data.page.list[0].partDesc
this.componentData.printUnit = data.page.list[0].printUnit
this.componentData.printUnitName = data.page.list[0].printUnitName
- } else {
- this.$message.warning('该子物料不存在!')
- this.componentData.componentPartDesc = ''
- this.componentData.printUnit = ''
- this.componentData.printUnitName = ''
+ return
}
}
})
}
+ this.componentData.componentPartDesc = ''
+ this.componentData.printUnit = ''
+ this.componentData.printUnitName = ''
},
// copy物料编码失焦事件
@@ -2939,13 +2940,12 @@ export default {
if (data && data.code === 0) {
if (data.page.list.length === 1) {
this.copyBomData.partDesc = data.page.list[0].partDesc
- } else {
- this.$message.warning('该物料编码不存在或制造类型不合规!')
- this.copyBomData.partDesc = ''
+ return
}
}
})
}
+ this.copyBomData.partDesc = ''
} else {
if (this.copyAlternativeData.partNo != null && this.copyAlternativeData.partNo !== '') {
this.copyPartData.limit = this.pageSize4
@@ -2955,13 +2955,12 @@ export default {
if (data && data.code === 0) {
if (data.page.list.length === 1) {
this.copyAlternativeData.partDesc = data.page.list[0].partDesc
- } else {
- this.$message.warning('该物料编码不存在或制造类型不合规!')
- this.copyAlternativeData.partDesc = ''
+ return
}
}
})
}
+ this.copyAlternativeData.partDesc = ''
}
},
diff --git a/src/views/modules/part/partInformation.vue b/src/views/modules/part/partInformation.vue
index cac4da5..2b6ceeb 100644
--- a/src/views/modules/part/partInformation.vue
+++ b/src/views/modules/part/partInformation.vue
@@ -139,14 +139,14 @@
-
+
- {{ i.sitename }}
- {{ i.buDesc }}
+
+
@@ -156,74 +156,75 @@
+
+
+
+
+
+
+
+
Copy
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
- 计量单位 / Inventory UoM
+ 计量单位
-
-
- 默认仓库
-
-
+ 物料分类
+
+
+
+
+
+
+
+
+
+
+
商品组1
-
-
-
- 物料分类
-
-
-
商品组2
@@ -231,16 +232,16 @@
-
- 属性模板
-
-
-
商品组3
+
+ 属性模板
+
+
+
@@ -265,16 +266,15 @@
-
-
+
+
- 同步
- 保存
+ 保存
关闭
@@ -1259,6 +1259,24 @@
fileList: [],
// ======== 列表表头 ========
columnList: [
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1Bu',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'buDesc',
+ headerAlign: 'center',
+ align: 'center',
+ columnLabel: 'BU',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 100
+ },
{
userId: this.$store.state.user.name,
functionId: 601001,
@@ -1298,20 +1316,20 @@
{
userId: this.$store.state.user.name,
functionId: 601001,
- serialNumber: '601001Table1StatusDesc',
+ serialNumber: '601001Table1PartDesceEn',
tableId: '601001Table1',
tableName: '物料信息表',
- columnProp: 'statusDesc',
+ columnProp: 'partDesceEn',
headerAlign: 'center',
- align: 'center',
- columnLabel: '物料状态',
+ align: 'left',
+ columnLabel: '物料描述(英文)',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 100
+ columnWidth: 300
},
{
userId: this.$store.state.user.name,
@@ -1322,7 +1340,7 @@
columnProp: 'spec',
headerAlign: 'center',
align: 'left',
- columnLabel: '规格型号',
+ columnLabel: '规格',
columnHidden: false,
columnImage: false,
columnSortable: false,
@@ -1334,20 +1352,20 @@
{
userId: this.$store.state.user.name,
functionId: 601001,
- serialNumber: '601001Table1UmId',
+ serialNumber: '601001Table1ActiveDesc',
tableId: '601001Table1',
tableName: '物料信息表',
- columnProp: 'umId',
+ columnProp: 'activeDesc',
headerAlign: 'center',
align: 'center',
- columnLabel: '计量单位',
+ columnLabel: '是否在用',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 80
+ columnWidth: 100
},
{
userId: this.$store.state.user.name,
@@ -1367,6 +1385,60 @@
fixed: '',
columnWidth: 150
},
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1UmId',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'umId',
+ headerAlign: 'center',
+ align: 'center',
+ columnLabel: '计量单位编码',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 150
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1UmName',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'umName',
+ headerAlign: 'center',
+ align: 'left',
+ columnLabel: '计量单位名称',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 200
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1FamilyID',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'familyID',
+ headerAlign: 'center',
+ align: 'center',
+ columnLabel: '物料分类编码',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 150
+ },
{
userId: this.$store.state.user.name,
functionId: 601001,
@@ -1375,15 +1447,33 @@
tableName: '物料信息表',
columnProp: 'familyName',
headerAlign: 'center',
+ align: 'left',
+ columnLabel: '物料分类名称',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 200
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1OtherGroup1',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'otherGroup1',
+ headerAlign: 'center',
align: 'center',
- columnLabel: '物料分类',
+ columnLabel: '商品组1编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 120
+ columnWidth: 150
},
{
userId: this.$store.state.user.name,
@@ -1393,15 +1483,33 @@
tableName: '物料信息表',
columnProp: 'otherGroupName1',
headerAlign: 'center',
+ align: 'left',
+ columnLabel: '商品组1名称',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 200
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1OtherGroup2',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'otherGroup2',
+ headerAlign: 'center',
align: 'center',
- columnLabel: '商品组1',
+ columnLabel: '商品组2编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 100
+ columnWidth: 150
},
{
userId: this.$store.state.user.name,
@@ -1409,17 +1517,35 @@
serialNumber: '601001Table1OtherGroupName2',
tableId: '601001Table1',
tableName: '物料信息表',
- columnProp: 'otherGroupName1',
+ columnProp: 'otherGroupName2',
+ headerAlign: 'center',
+ align: 'left',
+ columnLabel: '商品组2名称',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 200
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1OtherGroup3',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'otherGroup3',
headerAlign: 'center',
align: 'center',
- columnLabel: '商品组2',
+ columnLabel: '商品组3编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 100
+ columnWidth: 150
},
{
userId: this.$store.state.user.name,
@@ -1427,17 +1553,53 @@
serialNumber: '601001Table1OtherGroupName3',
tableId: '601001Table1',
tableName: '物料信息表',
- columnProp: 'otherGroupName1',
+ columnProp: 'otherGroupName3',
+ headerAlign: 'center',
+ align: 'left',
+ columnLabel: '商品组3名称',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 200
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1CodeNo',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'codeNo',
headerAlign: 'center',
align: 'center',
- columnLabel: '商品组3',
+ columnLabel: '属性模板编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 100
+ columnWidth: 150
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 601001,
+ serialNumber: '601001Table1CodeDesc',
+ tableId: '601001Table1',
+ tableName: '物料信息表',
+ columnProp: 'codeDesc',
+ headerAlign: 'center',
+ align: 'left',
+ columnLabel: '属性模板名称',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 200
},
{
userId: this.$store.state.user.name,
@@ -1455,7 +1617,7 @@
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 200
+ columnWidth: 300
},
{
userId: this.$store.state.user.name,
@@ -1491,7 +1653,7 @@
sortLv: 0,
status: true,
fixed: '',
- columnWidth: 80
+ columnWidth: 100
},
],
columnItemList: [
@@ -2573,7 +2735,7 @@
umId: '',
umName: '',
spec: '',
- active: '',
+ active: 'Y',
cinvSourceCode: '',
sku: '',
qtyBoxRoll: '',
@@ -3367,16 +3529,12 @@
if (data.baseListData.length > 0) {
this.modalData.umId = data.baseListData[0].UMID
this.modalData.umName = data.baseListData[0].UMName
- } else {
- this.$message.warning('该计量单位不存在!')
- this.modalData.umName = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.umName = ''
}
})
}
+ this.modalData.umName = ''
},
// 商品组1输入校验
@@ -3391,16 +3549,12 @@
if (data.baseListData.length > 0) {
this.modalData.otherGroup1 = data.baseListData[0].product_group_id
this.modalData.otherGroupName1 = data.baseListData[0].product_group_name
- } else {
- this.$message.warning('该商品组1不存在!')
- this.modalData.otherGroupName1 = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.otherGroupName1 = ''
}
})
}
+ this.modalData.otherGroupName1 = ''
},
// 商品组2输入校验
@@ -3415,16 +3569,12 @@
if (data.baseListData.length > 0) {
this.modalData.otherGroup2 = data.baseListData[0].product_group_id
this.modalData.otherGroupName2 = data.baseListData[0].product_group_name
- } else {
- this.$message.warning('该商品组2不存在!')
- this.modalData.otherGroupName2 = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.otherGroupName2 = ''
}
})
}
+ this.modalData.otherGroupName2 = ''
},
// 商品组3输入校验
@@ -3439,16 +3589,12 @@
if (data.baseListData.length > 0) {
this.modalData.otherGroup3 = data.baseListData[0].product_group_id
this.modalData.otherGroupName3 = data.baseListData[0].product_group_name
- } else {
- this.$message.warning('该商品组3不存在!')
- this.modalData.otherGroupName3 = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.otherGroupName3 = ''
}
})
}
+ this.modalData.otherGroupName3 = ''
},
// 默认仓库输入校验
@@ -3463,16 +3609,12 @@
if (data.baseListData.length > 0) {
this.modalData.defaultWarehouseID = data.baseListData[0].warehouse_id
this.modalData.defaultWarehouseName = data.baseListData[0].warehouse_name
- } else {
- this.$message.warning('该默认仓库不存在!')
- this.modalData.defaultWarehouseName = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.defaultWarehouseName = ''
}
})
}
+ this.modalData.defaultWarehouseName = ''
},
// 物料分类输入校验
@@ -3487,16 +3629,12 @@
if (data.baseListData.length > 0) {
this.modalData.familyID = data.baseListData[0].family_id
this.modalData.familyName = data.baseListData[0].family_name
- } else {
- this.$message.warning('该物料分类不存在!')
- this.modalData.familyName = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.familyName = ''
}
})
}
+ this.modalData.familyName = ''
},
// 属性输入校验
@@ -3511,16 +3649,12 @@
if (data.baseListData.length > 0) {
this.modalData.codeNo = data.baseListData[0].code_no
this.modalData.codeDesc = data.baseListData[0].code_desc
- } else {
- this.$message.warning('该属性模板不存在!')
- this.modalData.codeDesc = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.modalData.codeDesc = ''
}
})
}
+ this.modalData.codeDesc = ''
},
// ======== chooseList相关方法 ========
@@ -3543,7 +3677,7 @@
}
if (val === 510) {
strVal = this.modalData.umId
- conSql = ''
+ conSql = " and site = '" + this.modalData.bu.split('_')[0] + "'"
} else if (val === 211) {
strVal = this.modalData.otherGroup1
} else if (val === 212) {
diff --git a/src/views/modules/part/routingManagement.vue b/src/views/modules/part/routingManagement.vue
index d8e956e..db1a719 100644
--- a/src/views/modules/part/routingManagement.vue
+++ b/src/views/modules/part/routingManagement.vue
@@ -2094,13 +2094,12 @@ export default {
if (data && data.code === 0) {
if (data.page.list.length === 1) {
this.copyRoutingData.partDesc = data.page.list[0].partDesc
- } else {
- this.$message.warning('该物料不存在!')
- this.copyRoutingData.partDesc = ''
+ return
}
}
})
}
+ this.copyRoutingData.partDesc = ''
} else {
if (this.copyAlternativeData.partNo != null && this.copyAlternativeData.partNo !== '') {
this.copyPartData.limit = this.pageSize4
@@ -2110,13 +2109,12 @@ export default {
if (data && data.code === 0) {
if (data.page.list.length === 1) {
this.copyAlternativeData.partDesc = data.page.list[0].partDesc
- } else {
- this.$message.warning('该物料不存在!')
- this.copyAlternativeData.partDesc = ''
+ return
}
}
})
}
+ this.copyAlternativeData.partDesc = ''
}
},
@@ -2706,31 +2704,38 @@ export default {
// 物料编码失焦事件
partNoBlur () {
- this.partData.limit = this.pageSize2
- this.partData.page = this.pageIndex2
- this.partData.partNo = this.modalData.partNo
- queryPartList(this.partData).then(({data}) => {
- if (data && data.code === 0) {
- if (data.page.list.length === 1) {
- this.modalData.partDesc = data.page.list[0].partDesc
- this.modalData.printUnit = data.page.list[0].printUnit
- this.modalData.printUnitName = data.page.list[0].printUnitName
- // 获取物料的routing版本号
- getRottingRevision(this.modalData).then(({data}) => {
- if (data && data.code === 0) {
- this.modalData.routingRevision = data.routingRevision
- } else {
- this.modalData.routingRevision = ''
- }
- })
- } else {
- this.modalData.partDesc = ''
- this.modalData.printUnit = ''
- this.modalData.printUnitName = ''
- this.modalData.routingRevision = ''
+ if (this.modalData.partNo != null && this.modalData.partNo !== '') {
+ this.partData.limit = this.pageSize2
+ this.partData.page = this.pageIndex2
+ this.partData.partNo = this.modalData.partNo
+ queryPartList(this.partData).then(({data}) => {
+ if (data && data.code === 0) {
+ if (data.page.list.length === 1) {
+ this.modalData.partDesc = data.page.list[0].partDesc
+ this.modalData.printUnit = data.page.list[0].printUnit
+ this.modalData.printUnitName = data.page.list[0].printUnitName
+ // 获取物料的routing版本号
+ getRottingRevision(this.modalData).then(({data}) => {
+ if (data && data.code === 0) {
+ this.modalData.routingRevision = data.routingRevision
+ } else {
+ this.modalData.routingRevision = ''
+ }
+ })
+ } else {
+ this.modalData.partDesc = ''
+ this.modalData.printUnit = ''
+ this.modalData.printUnitName = ''
+ this.modalData.routingRevision = ''
+ }
}
- }
- })
+ })
+ } else {
+ this.modalData.partDesc = ''
+ this.modalData.printUnit = ''
+ this.modalData.printUnitName = ''
+ this.modalData.routingRevision = ''
+ }
},
/**
@@ -3455,16 +3460,12 @@ export default {
if (data.baseListData.length > 0) {
this.componentData.workCenterNo = data.baseListData[0].work_center_no
this.componentData.workCenterDesc = data.baseListData[0].work_center_desc
- } else {
- this.$message.warning('该加工中心不存在!')
- this.componentData.workCenterDesc = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.componentData.workCenterDesc = ''
}
})
}
+ this.componentData.workCenterDesc = ''
},
// 人员等级
@@ -3479,16 +3480,12 @@ export default {
if (data.baseListData.length > 0) {
this.componentData.setupLaborClassNo = data.baseListData[0].class_no
this.componentData.setupLaborClassDesc = data.baseListData[0].class_desc
- } else {
- this.$message.warning('该人员等级不存在!')
- this.componentData.setupLaborClassDesc = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.componentData.setupLaborClassDesc = ''
}
})
}
+ this.componentData.setupLaborClassDesc = ''
},
// 人员等级
@@ -3503,16 +3500,12 @@ export default {
if (data.baseListData.length > 0) {
this.componentData.laborClassNo = data.baseListData[0].class_no
this.componentData.laborClassDesc = data.baseListData[0].class_desc
- } else {
- this.$message.warning('该人员等级不存在!')
- this.componentData.laborClassDesc = ''
+ return
}
- } else {
- this.$message.warning(data.msg)
- this.componentData.laborClassDesc = ''
}
})
}
+ this.componentData.laborClassDesc = ''
},
// ======== 导出相关方法 ========