From 02ce4fc07d1830ca0bbac01e3a375fac8e97584e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B8=B8=E7=86=9F=E5=90=B4=E5=BD=A6=E7=A5=96?= Date: Sun, 21 Sep 2025 17:01:38 +0800 Subject: [PATCH] 1 --- .../modules/orderIssure/newSoIssueNotify.vue | 53 +- .../orderIssure/searchIssureNotify.vue | 2168 +----------- .../orderIssure/searchIssureNotify_old.vue | 3085 +++++++++++++++++ 3 files changed, 3234 insertions(+), 2072 deletions(-) create mode 100644 src/views/modules/orderIssure/searchIssureNotify_old.vue diff --git a/src/views/modules/orderIssure/newSoIssueNotify.vue b/src/views/modules/orderIssure/newSoIssueNotify.vue index 702e70b..33ae6e0 100644 --- a/src/views/modules/orderIssure/newSoIssueNotify.vue +++ b/src/views/modules/orderIssure/newSoIssueNotify.vue @@ -6,11 +6,11 @@ 新建申请单 选择工单 - 下达申请单 删除申请单 - {{'导入'}} + {{'导入'}} @@ -243,29 +243,6 @@ 关闭 - -
- - - - - - - - - - - - -
- - 确定下达 - 取消 - -
@@ -1571,16 +1548,22 @@ export default { this.xiadaModelFlag = true }, xiadaNotify() { - xiadaNotify(this.notifyData).then(({ data }) => { - if (data.code === 0) { - this.xiadaModelFlag = false - this.getUserNotifyNo() - this.$message.success('操作成功') - } else { - this.$alert(data.msg, '错误', { - confirmButtonText: '确定', - }) - } + this.$confirm(`确定进行下达操作?`, '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + xiadaNotify(this.notifyData).then(({data}) => { + if (data.code === 0) { + this.xiadaModelFlag = false + this.getUserNotifyNo() + this.$message.success('操作成功') + } else { + this.$alert(data.msg, '错误', { + confirmButtonText: '确定', + }) + } + }) }) }, saveOtherPart() { diff --git a/src/views/modules/orderIssure/searchIssureNotify.vue b/src/views/modules/orderIssure/searchIssureNotify.vue index 6e67439..3d748b1 100644 --- a/src/views/modules/orderIssure/searchIssureNotify.vue +++ b/src/views/modules/orderIssure/searchIssureNotify.vue @@ -11,8 +11,8 @@ - - + + @@ -121,12 +121,6 @@ - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -339,514 +254,6 @@ - - - - - - - - {{ i.sitename }} - - {{ i.buDesc }} - - - - - - - - - - - - - - - - - - - - - - - - 保存 - 关闭 - - - - - - - - - - - - - - - - - - - - - - - - - 查询 - - - - - - - - - - - - - - - - - - 关闭 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 查询 - - - - - - - - - - - - - - 关闭 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 查询 - - - - - - - - - - - - - - - - 关闭 - - - - - - - - - - - - - - 查询 - - - - - - - - - - - - - - 关闭 - - - - - - - - - - - - - - - - - - - 查询 - - - - - - - - - - - - - - 关闭 - - - - - - - - - - - BOM物料 - 非BOM物料 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 保存 - 关闭 - - - @@ -863,23 +270,9 @@ , deleteNotifyMaterial , searchNotifyLog , searchNotifyLogClose - , getSiteAndBuByUserName - , createNotify - , getSOScheduledRoutingListForIssure - , getPartList + } from "@/api/orderIssure/soIssueNotify.js" - import { - searchShopOrderByPaging - , getRouteInShopOrder - } from "@/api/shopOrder/shopOrder.js" - import { - searchAllResource - } from "@/api/base/site.js" - import { - getTableDefaultListLanguage, - getTableUserListLanguage, - } from "@/api/table.js" export default { @@ -957,23 +350,6 @@ status: true, fixed: '', columnWidth: 100 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table1Bu', - tableId: "701002Table1", - tableName: "领料申请主表", - columnProp: "bu", - 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: 701002, @@ -1076,6 +452,23 @@ status: true, fixed: '', columnWidth: 80 + },{ + userId: this.$store.state.user.name, + functionId: 701002, + serialNumber: '701002Table1WcsPushFlag', + tableId: "701002Table1", + tableName: "领料申请主表", + columnProp: "wcsPushFlag", + headerAlign: "center", + align: "left", + columnLabel: "推送WCS", + columnHidden: false, + columnImage: false, + columnSortable: false, + sortLv: 0, + status: true, + fixed: '', + columnWidth: 80 },{ userId: this.$store.state.user.name, functionId: 701002, @@ -1148,183 +541,63 @@ status: true, fixed: '', columnWidth: 120 - },{ + }, { userId: this.$store.state.user.name, functionId: 701002, - serialNumber: '701002Table2OpsItemNo', + serialNumber: '701002Table2FGPartNo', tableId: "701002Table2", tableName: "申请单派工单明细表", - columnProp: "opsItemNo", + columnProp: "fGPartNo", headerAlign: "center", - align: "right", - columnLabel: "工序", + align: "left", + columnLabel: "工单物料", columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 50 - },{ + columnWidth: 80 + + }, + + ], + columnList3:[ + { userId: this.$store.state.user.name, functionId: 701002, - serialNumber: '701002Table2ItemDesc', - tableId: "701002Table2", - tableName: "申请单派工单明细表", - columnProp: "itemDesc", + serialNumber: '701002Table3ItemNo', + tableId: "701002Table3", + tableName: "申请单材料明细表", + columnProp: "itemNo", headerAlign: "center", - align: "left", - columnLabel: "工序名称", + align: "right", + columnLabel: "申请单序号", columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 120 + columnWidth: 80 },{ userId: this.$store.state.user.name, functionId: 701002, - serialNumber: '701002Table2SeqNo', - tableId: "701002Table2", - tableName: "申请单派工单明细表", - columnProp: "seqNo", + serialNumber: '701002Table3ComponentPartNo', + tableId: "701002Table3", + tableName: "申请单材料明细表", + columnProp: "componentPartNo", headerAlign: "center", - align: "left", - columnLabel: "派工单号", + align: "center", + columnLabel: "材料编码", columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 150 - }, { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table2FGPartNo', - tableId: "701002Table2", - tableName: "申请单派工单明细表", - columnProp: "fGPartNo", - headerAlign: "center", - align: "left", - columnLabel: "派工单物料", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - }, { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table2PartDesc', - tableId: "701002Table2", - tableName: "申请单派工单明细表", - columnProp: "partDesc", - 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: 701002, - serialNumber: '701002Table2LocationNo', - tableId: "701002Table2", - tableName: "领料申请派工单子表", - columnProp: 'locationNo', - headerAlign: "center", - align: "left", - columnLabel: '库位编码', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80, - - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table2IssureQty', - tableId: "701002Table2", - tableName: "申请单派工单明细表", - columnProp: "issureQty", - headerAlign: "center", - align: "right", - columnLabel: "发料数量", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - }, - ], - columnList3:[ - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table3ItemNo', - tableId: "701002Table3", - tableName: "申请单材料明细表", - columnProp: "itemNo", - headerAlign: "center", - align: "right", - columnLabel: "申请单序号", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table3ComponentPartNo', - tableId: "701002Table3", - tableName: "申请单材料明细表", - columnProp: "componentPartNo", - headerAlign: "center", - align: "center", - columnLabel: "材料编码", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table3PartDesc', - tableId: "701002Table3", - tableName: "申请单材料明细表", - columnProp: "partDesc", - headerAlign: "center", - align: "left", - columnLabel: "材料名称", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 130 - },{ + columnWidth: 100 + },{ userId: this.$store.state.user.name, functionId: 701002, serialNumber: '701002Table3NeedDate', @@ -1426,57 +699,6 @@ status: true, fixed: '', columnWidth: 120 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table3OpsItemNo', - tableId: "701002Table3", - tableName: "申请单材料明细表", - columnProp: "opsItemNo", - headerAlign: "center", - align: "right", - columnLabel: "工序", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 50 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table3SeqNo', - tableId: "701002Table3", - tableName: "申请单材料明细表", - columnProp: "seqNo", - headerAlign: "center", - align: "left", - columnLabel: "派工单号", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 150 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table3LocationNo', - tableId: "701002Table3", - tableName: "申请单材料明细表", - columnProp: "locationNo", - headerAlign: "center", - align: "left", - columnLabel: "机台", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 },{ userId: this.$store.state.user.name, functionId: 701002, @@ -1556,637 +778,103 @@ serialNumber: '701002Table4QtyToIssue', tableId: "701002Table4", tableName: "申请单材料明细表", - columnProp: "qtyToIssue", - headerAlign: "center", - align: "right", - columnLabel: "合计申请数量", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - },{ - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table4QtyToIssueOriginal', - tableId: "701002Table4", - tableName: "申请单材料明细表", - columnProp: "qtyToIssueOriginal", - headerAlign: "center", - align: "right", - columnLabel: "合计已发数量", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - }, - ], - columnList5:[ - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5UpdateType', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "updateType", - headerAlign: "center", - align: "center", - columnLabel: "删除类型", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5ItemNo', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "itemNo", - headerAlign: "center", - align: "right", - columnLabel: "领料单序号", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5SOOrderNo', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "sOOrderNo", - headerAlign: "center", - align: "left", - columnLabel: "生产订单", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5SeqNo', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "seqNo", - headerAlign: "center", - align: "left", - columnLabel: "派工单", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5ComponentPartNo', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "componentPartNo", - headerAlign: "center", - align: "left", - columnLabel: "材料物料编码", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5IssueType', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "issueType", - headerAlign: "center", - align: "left", - columnLabel: "材料类型", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5QtyToIssue', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "qtyToIssue", - headerAlign: "center", - align: "right", - columnLabel: "要求领料数量", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5UpdateBy', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "updateBy", - headerAlign: "center", - align: "left", - columnLabel: "删除账号", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table5UpdateDate', - tableId: "701002Table5", - tableName: "申请单材料删除记录表", - columnProp: "updateDate", - headerAlign: "center", - align: "center", - columnLabel: "删除时间", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120 - }, - ], - columnList6:[ - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table6UserDisplay', - tableId: "701002Table6", - tableName: "申请单材料关闭明细", - columnProp: "userDisplay", - headerAlign: "center", - align: "left", - columnLabel: "操作人", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table6ActionTime', - tableId: "701002Table6", - tableName: "申请单材料关闭明细", - columnProp: "actionTime", - headerAlign: "center", - align: "left", - columnLabel: "操作时间", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 130 - }, - { - userId: this.$store.state.user.name, - functionId: 701002, - serialNumber: '701002Table6ActionRemark', - tableId: "701002Table6", - tableName: "申请单材料关闭明细", - columnProp: "actionRemark", - headerAlign: "center", - align: "left", - columnLabel: "关闭原因", - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 300 - }, - ], - - // 导出 start - exportData: [], - exportName: '发料申请单'+this.dayjs().format('YYYYMMDDHHmmss'), - exportHeader: ["发料申请单"], - exportFooter: [], - // 导出 end - orderDetailData:{ - orderNo:'', - seqNo:'', - locationNo:'', - qtyrequired:'', - issureQty:0, - partDesc:'', - partNo:'', - resourceId:'', - resourceDesc:'', - needDate:'', - itemDesc:'', - workCenterNo:'', - itemNo:0, - materialType:'BOM物料', - }, - chooseSOSModalFlag: false, - chooseSOSData: { - orderno: '', - seqno: '', - sResourceid: '', - startDate: '', - endDate: '', - }, - chooseOrderModalFlag: false, - chooseOrderData: { - page: 1, - limit: 100, - orderNo: '', - status: '', - date3: '', - date4: '', - statusList: '', - }, - chooseOrderList: [], - chooseOperationModalFlag: false, - chooseOperationData: { - orderNo: '', - site: '', - itemDesc: '' - }, - chooseOperationList: [], - chooseResourceModalFlag: false, - chooseResourceData: { - site: '', - workCenterNo: '', - resourceID: '', - resourceDesc: '', - }, - chooseResourceList: [], - chooseSOSList: [], - choosePartModalFlag: false, - choosePartData: { - site: '', - sourceBu: '', - partNo: '', - partDesc: '', - spec: '', - }, - choosePartList: [], - chooseSOSColumnList: [ - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2Orderno', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'orderno', - headerAlign: "center", - align: "center", - columnLabel: '生产订单', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2Seqno', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'seqno', - 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: 701001, - serialNumber: '701001Table2PartNo', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'partNo', - headerAlign: "center", - align: "left", - columnLabel: '物料编码', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2PartDesc', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'partDesc', - headerAlign: "center", - align: "left", - columnLabel: '物料描述', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2Qtyrequired', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'qtyrequired', - headerAlign: "center", - align: "right", - columnLabel: '派工数量', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2SResourceid', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'sResourceid', - headerAlign: "center", - align: "left", - columnLabel: '机台编码', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 60, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2ResourceDesc', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'resourceDesc', - headerAlign: "center", - align: "left", - columnLabel: '机台名称', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2StartDate', - tableId: "701001Table2", - tableName: "查询派工单", - columnProp: 'startDate', - headerAlign: "center", - align: "left", - columnLabel: '开始日期', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100, - }, - ], - chooseOrderColumnList: [ - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2Orderno', - tableId: "701001Table2", - tableName: "查询工单", - columnProp: 'orderNo', - headerAlign: "center", - align: "center", - columnLabel: '工单号', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2PartNo', - tableId: "701001Table2", - tableName: "查询工单", - columnProp: 'partNo', - headerAlign: "center", - align: "left", - columnLabel: '物料编码', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2PartDescription', - tableId: "701001Table2", - tableName: "查询工单", - columnProp: 'partDescription', - headerAlign: "center", - align: "left", - columnLabel: '物料描述', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 150, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2LotSize', - tableId: "701001Table2", - tableName: "查询工单", - columnProp: 'lotSize', - headerAlign: "center", - align: "right", - columnLabel: '工单数量', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 100, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2Status', - tableId: "701001Table2", - tableName: "查询工单", - columnProp: 'status', - headerAlign: "center", - align: "center", - columnLabel: '状态', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80, - }, - ], - chooseOperationColumnList: [ - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2ItemNo', - tableId: "701001Table2", - tableName: "查询工序", - columnProp: 'itemNo', - headerAlign: "center", - align: "center", - columnLabel: '工序号', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 80, - }, - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2OperationDesc', - tableId: "701001Table2", - tableName: "查询工序", - columnProp: 'operationDesc', - headerAlign: "center", - align: "left", - columnLabel: '工序名称', - columnHidden: false, - columnImage: false, - columnSortable: false, - sortLv: 0, - status: true, - fixed: '', - columnWidth: 120, - } - ], - chooseResourceColumnList: [ - { - userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2ResourceID', - tableId: "701001Table2", - tableName: "查询机台", - columnProp: 'resourceID', + columnProp: "qtyToIssue", headerAlign: "center", - align: "left", - columnLabel: '机台编码', + align: "right", + columnLabel: "合计申请数量", columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 100, - }, - { + columnWidth: 80 + },{ userId: this.$store.state.user.name, - functionId: 701001, - serialNumber: '701001Table2ResourceDesc', - tableId: "701001Table2", - tableName: "查询机台", - columnProp: 'resourceDesc', + functionId: 701002, + serialNumber: '701002Table4QtyToIssueOriginal', + tableId: "701002Table4", + tableName: "申请单材料明细表", + columnProp: "qtyToIssueOriginal", headerAlign: "center", - align: "left", - columnLabel: '机台描述', + align: "right", + columnLabel: "合计已发数量", columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 150, + columnWidth: 80 }, ], + + // 导出 start + exportData: [], + exportName: '发料申请单'+this.dayjs().format('YYYYMMDDHHmmss'), + exportHeader: ["发料申请单"], + exportFooter: [], + // 导出 end + orderDetailData:{ + orderNo:'', + seqNo:'', + locationNo:'', + qtyrequired:'', + issureQty:0, + partDesc:'', + partNo:'', + resourceId:'', + resourceDesc:'', + needDate:'', + itemDesc:'', + workCenterNo:'', + itemNo:0, + materialType:'BOM物料', + }, + chooseSOSModalFlag: false, + chooseSOSData: { + orderno: '', + seqno: '', + sResourceid: '', + startDate: '', + endDate: '', + }, + chooseOrderModalFlag: false, + chooseOrderData: { + page: 1, + limit: 100, + orderNo: '', + status: '', + date3: '', + date4: '', + statusList: '', + }, + chooseOrderList: [], + chooseOperationModalFlag: false, + chooseOperationData: { + orderNo: '', + site: '', + itemDesc: '' + }, + chooseOperationList: [], + chooseResourceModalFlag: false, + chooseResourceData: { + site: '', + workCenterNo: '', + resourceID: '', + resourceDesc: '', + }, + chooseResourceList: [], + chooseSOSList: [], + choosePartModalFlag: false, + choosePartData: { + site: '', + sourceBu: '', + partNo: '', + partDesc: '', + spec: '', + }, + choosePartList: [], } }, mounted () { @@ -2195,100 +883,14 @@ }) }, - // watch: { - // searchData: { - // deep: true, - // handler: function (newV, oldV) { - // this.searchData.partNo = this.searchData.partNo.toUpperCase() - // } - // }, - // }, + created () { - // 动态列 - this.getTableUserColumn(this.$route.meta.menuId+'table1',1) - this.getTableUserColumn(this.$route.meta.menuId+'table2',2) - this.getTableUserColumn(this.$route.meta.menuId+'table3',3) - this.getTableUserColumn(this.$route.meta.menuId+'table4',4) - this.getTableUserColumn(this.$route.meta.menuId+'table5',5) - this.getTableUserColumn(this.$route.meta.menuId+'table6',6) + }, methods: { - // 动态列开始 获取 用户保存的 格式列 - async getTableUserColumn(tableId, columnId) { - let queryTableUser = { - userId: this.$store.state.user.name, - functionId: this.$route.meta.menuId, - tableId: tableId, - status: true, - languageCode: this.$i18n.locale - } - await getTableUserListLanguage(queryTableUser).then(({data}) => { - if (data.rows.length > 0) { - //this.columnList1 = [] - switch (columnId) { - case 1: - this.columnList1 = data.rows - break; - case 2: - this.columnList2 = data.rows - break; - case 3: - this.columnList3 = data.rows - break; - case 4: - this.columnList4 = data.rows - break; - case 5: - this.columnList5 = data.rows - break; - case 6: - this.columnList6 = data.rows - break; - } - } else { - this.getColumnList(tableId, columnId) - } - }) - }, - - // 获取 tableDefault 列 - async getColumnList (tableId, columnId) { - let queryTable= { - functionId: this.$route.meta.menuId, - tableId: tableId, - languageCode: this.$i18n.locale - } - await getTableDefaultListLanguage(queryTable).then(({data}) => { - if (data.rows&&data.rows.length > 0) { - switch (columnId) { - case 1: - this.columnList1 = data.rows - break; - case 2: - this.columnList2 = data.rows - break; - case 3: - this.columnList3 = data.rows - break; - case 4: - this.columnList4 = data.rows - break; - case 5: - this.columnList5 = data.rows - break; - case 6: - this.columnList6 = data.rows - break; - } - } else { - // this.showDefault = true. - } - }) - - }, // 每页数 - sizeChangeHandle (val) { + sizeChangeHandle (val) { this.pageSize = val this.searchTable() }, @@ -2491,173 +1093,6 @@ }, -//申请单主表新增方法 - //新增领料申请单模态框 - createNotifyModal(){ - let inData={ - username:this.$store.state.user.name - } - getSiteAndBuByUserName(inData).then(({data}) =>{ - if (data && data.code === 0) { - this.userBuList=data.rows - if (this.userBuList.length > 0) { - this.notifyData.bu = this.userBuList[0].buNo - } - } - }) - this.createNotifyFlag=true - }, - //保存领料申请单 - saveNotify(){ - let buValue = this.notifyData.bu - let site = buValue.split('_')[0] - let bu = buValue.split('_')[1] - - let inData={ - site: site, - bu: bu, - userName:this.$store.state.user.name, - remark: this.notifyData.remark - } - createNotify(inData).then(({data})=>{ - if (data.code === 0) { - this.$message({ - message: '操作成功', - type: 'success', - duration: 1500, - onClose: () => {} - }) - this.createNotifyFlag = false - // 刷新主表数据 - this.searchTable() - // 清空表单数据 - this.notifyData = { - site: '', - bu: '', - notifyNo: '', - notifyDate: '', - enteredDate: '', - userName: this.$store.state.user.name, - userDisplay: '', - remark: '', - planIssueDate: '', - } - }else { - this.$alert(data.msg, '错误', { - confirmButtonText: '确定' - }) - } - }) - }, - - //新增派工单明细 - createOrderDetail(){ - // 检查是否选择了主表行 - /* if (!this.currentRow || !this.currentRow.notifyNo) { - this.$alert('请先选择一条主表记录!', '提示', { - confirmButtonText: '确定' - }) - return false - } */ - - // 清除所有数据,设置默认值 - this.orderDetailData = { - orderno: '', - seqno: '', - operationNo: '', - locationNo: '', - qtyrequired: '', - issureQty: 0, - partDesc: '', - partNo: '', - resourceId: '', - resourceDesc: '', - itemDesc: '', - itemNo: 0, - workCenterNo: '', - needDate: '', - materialType: 'BOM物料' - } - - this.saveOrderDetailFlag = true - }, - //编辑派工单明细 - editOrderDetail(){ - // 检查是否选择了明细行 - if (!this.dataList2 || this.dataList2.length === 0) { - this.$alert('请先选择一条明细记录!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - // 这里应该实现编辑逻辑 - this.$message.warning('编辑功能待实现'); - }, - saveOrderDetail(){ - // 数据验证 - if (!this.orderDetailData.needDate) { - this.$alert('请选择要求发料时间!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - if (!this.orderDetailData.issureQty || this.orderDetailData.issureQty <= 0) { - this.$alert('请填写领取数量!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - let inData = { - site: this.currentRow.site, - bu: this.currentRow.bu, - notifyNo: this.currentRow.notifyNo, - orderno: this.orderDetailData.orderNo, - seqno: this.orderDetailData.seqNo, - operationNo: this.orderDetailData.operationNo, - locationNo: this.orderDetailData.locationNo, - qtyrequired: this.orderDetailData.qtyRequired, - issureQty: this.orderDetailData.issureQty, - partDesc: this.orderDetailData.partDesc, - partNo: this.orderDetailData.partNo, - resourceDesc: this.orderDetailData.resourceDesc, - resourceId: this.orderDetailData.resourceId, - itemDesc: this.orderDetailData.itemDesc, - itemNo: this.orderDetailData.itemNo, - workCenterNo: this.orderDetailData.workCenterNo, - needDate: this.orderDetailData.needDate, - username: this.$store.state.user.name, - } - - // 这里应该调用相应的API来保存派工单数据 - // 由于没有具体的API,我们先模拟成功 - this.$message.success('保存成功') - this.saveOrderDetailFlag = false - - // 刷新当前标签页数据 - this.refreshCurrentTabTable() - - // 清空表单数据 - this.orderDetailData = { - orderno: '', - seqno: '', - operationNo: '', - locationNo: '', - qtyrequired: '', - issureQty: 0, - partDesc: '', - partNo: '', - resourceId: '', - resourceDesc: '', - itemDesc: '', - itemNo: 0, - workCenterNo: '', - needDate: '', - materialType: 'BOM物料' - } - }, //导出excel @@ -2698,347 +1133,6 @@ }, - - - onMaterialTypeChange(value) { - // 清空相关字段 - this.orderDetailData.orderNo = ''; - this.orderDetailData.seqNo = ''; - this.orderDetailData.operationNo = ''; - this.orderDetailData.partNo = ''; - this.orderDetailData.partDesc = ''; - this.orderDetailData.locationNo = ''; - this.orderDetailData.resourceId = ''; - this.orderDetailData.resourceDesc = ''; - this.orderDetailData.qtyRequired = ''; - this.orderDetailData.itemDesc = ''; - this.orderDetailData.itemNo = ''; - this.orderDetailData.workCenterNo = ''; - this.orderDetailData.issureQty = 0; - }, - - - - - searchSOSRouting() { - // 调用API查询派工单信息 - this.$message.warning('正在查询派工单信息...'); - - getSOScheduledRoutingListForIssure(this.chooseSOSData).then(({data}) => { - if (data.code === 0) { - this.chooseSOSList = data.rows; - if (this.chooseSOSList.length === 0) { - this.$message.warning('未查询到符合条件的派工单'); - } - } else { - this.$message.error(data.msg || '查询失败'); - } - }).catch(error => { - console.error('查询派工单失败:', error); - this.$message.error('查询失败,请稍后重试'); - }); - }, - openChooseSOSModal() { - // 检查是否选择了主表行 - if (!this.currentRow || !this.currentRow.notifyNo) { - this.$alert('请先选择一条主表记录!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - // 初始化选择派工单数据 - this.chooseSOSData = { - site: this.currentRow.site, - bu: this.currentRow.bu, - orderno: '', - seqno: '', - sResourceid: '', - startDate: this.dayjs().format('YYYY-MM-DD'), - endDate: this.dayjs().format('YYYY-MM-DD'), - } - - // 清空选择列表 - this.chooseSOSList = [] - - // 打开选择模态框 - this.chooseSOSModalFlag = true - }, - chooseSOS(row) { - // 关闭选择模态框 - this.chooseSOSModalFlag = false - - // 将选择的数据填入到保存派工单模态框中 - this.orderDetailData.orderNo = row.orderno || row.orderNo || ''; - this.orderDetailData.seqNo = row.seqno || row.seqNo || ''; - this.orderDetailData.operationNo = row.operationNo || row.operation || ''; - this.orderDetailData.locationNo = row.sResourceid || row.locationNo || ''; - this.orderDetailData.qtyRequired = row.qtyrequired || row.qtyToIssue || ''; - this.orderDetailData.partDesc = row.partDesc || ''; - this.orderDetailData.partNo = row.partNo || row.fGPartNo || ''; - this.orderDetailData.workCenterNo = row.workCenterNo || ''; - this.orderDetailData.needDate = row.startDate || this.dayjs().format('YYYY-MM-DD HH:mm:ss'); - - // 根据物料类型设置 - if (row.issueType === '非BOM物料') { - this.orderDetailData.materialType = '非BOM物料'; - } else { - this.orderDetailData.materialType = 'BOM物料'; - } - - this.$message.success('选择派工单成功,数据已填入表单'); - }, - - -//工单选择部分 - // 打开选择工单模态框 - openChooseOrderModal() { - // 检查是否选择了主表行 - if (!this.currentRow || !this.currentRow.notifyNo) { - this.$alert('请先选择一条主表记录!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - // 初始化选择工单数据 - this.chooseOrderData = { - page: 1, - limit: 100, - site: this.currentRow.site, - buNo: this.currentRow.bu, - user: this.$store.state.user.name, - orderNo: '', - statusList: ['已下达', '已计划', '已排产'], - date3: this.dayjs().format('YYYY-MM-DD'), - date4: this.dayjs().format('YYYY-MM-DD'), - } - - // 清空选择列表 - this.chooseOrderList = [] - - // 打开选择模态框 - this.chooseOrderModalFlag = true - }, - // 查询工单信息 - searchOrder() { - this.chooseOrderData.limit = this.co_pageSize - this.chooseOrderData.page = this.co_pageIndex - searchShopOrderByPaging(this.chooseOrderData).then(({data}) => { - if (data.code === 0) { - this.chooseOrderList = data.page.list; - if (this.chooseOrderList.length === 0) { - this.$message.warning('未查询到符合条件的工单'); - } - this.co_pageIndex = data.page.currPage - this.co_pageSize = data.page.pageSize - this.co_totalPage = data.page.totalCount - } else { - this.chooseOrderList = []; - this.$message.error(data.msg || '查询失败'); - } - }).catch(error => { - this.chooseOrderList = []; - console.error('查询工单失败:', error); - this.$message.error('查询失败,请稍后重试'); - }); - }, - // 每页数 工单分页信息 - coSizeChangeHandle(val) { - this.co_pageSize = val - this.searchOrder() - }, - // 当前页 工单分页信息 - co_currentChangeHandle(val) { - this.co_pageIndex = val - this.searchOrder() - }, - // 选择工单 - chooseOrder(row) { - // 关闭选择模态框 - this.chooseOrderModalFlag = false - - // 将选择的数据填入到保存派工单模态框中 - this.orderDetailData.orderNo = row.orderNo || ''; - this.orderDetailData.partNo = row.partNo || ''; - this.orderDetailData.partDesc = row.partDescription || ''; - this.orderDetailData.qtyRequired = row.lotSize || ''; - - // 清空相关字段 - this.orderDetailData.seqNo = ''; - this.orderDetailData.operationNo = ''; - this.orderDetailData.locationNo = ''; - }, -//工序选择部分 - // 打开选择工序模态框 - openChooseOperationModal() { - // 检查是否选择了工单 - if (!this.orderDetailData.orderNo) { - this.$alert('请先选择工单!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - // 初始化选择工序数据 - this.chooseOperationData = { - orderNo: this.orderDetailData.orderNo, - site: this.currentRow.site, - } - - // 清空选择列表 - this.chooseOperationList = [] - - // 打开选择模态框 - this.chooseOperationModalFlag = true - }, - // 查询工序信息 - searchOperation() { - // 调用API查询工序信息 - getRouteInShopOrder(this.chooseOperationData).then(({data}) => { - if (data.code === 0) { - this.chooseOperationList = data.dataList; - if (this.chooseOperationList.length === 0) { - this.$message.warning('未查询到符合条件的工序'); - } - } else { - // 清空选择列表 - this.chooseOperationList = []; - this.$message.error(data.msg || '查询失败'); - } - }).catch(error => { - // 清空选择列表 - this.chooseOperationList = []; - console.error('查询工序失败:', error); - this.$message.error('查询失败,请稍后重试'); - }); - }, - // 选择工序 - chooseOperation(row) { - // 关闭选择模态框 - this.chooseOperationModalFlag = false - - // 将选择的数据填入到保存派工单模态框中 - this.orderDetailData.itemDesc = row.operationDesc || ''; - this.orderDetailData.itemNo = row.itemNo || ''; - this.orderDetailData.workCenterNo = row.workCenterNo || ''; - - this.$message.success('操作成功'); - }, -//机台选择部分 - // 打开选择机台模态框 - openChooseResourceModal() { - // 检查是否选择了工单 - if (!this.orderDetailData.orderNo) { - this.$alert('请先选择工单!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - // 初始化选择机台数据 - this.chooseResourceData = { - site: this.currentRow.site, - workCenterNo: this.orderDetailData.workCenterNo, - resourceID: '', - resourceDesc: '', - } - - // 清空选择列表 - this.chooseResourceList = [] - - // 打开选择模态框 - this.chooseResourceModalFlag = true - }, - // 查询机台信息 - searchResource() { - // 调用API查询机台信息 - searchAllResource(this.chooseResourceData).then(({data}) => { - if (data.code === 0) { - this.chooseResourceList = data.rows; - if (this.chooseResourceList.length === 0) { - this.$message.warning('未查询到符合条件的机台'); - } - } else { - // 清空选择列表 - this.chooseResourceList = []; - this.$message.error(data.msg || '查询失败'); - } - }).catch(error => { - // 清空选择列表 - this.chooseResourceList = []; - console.error('查询机台失败:', error); - this.$message.error('查询失败,请稍后重试'); - }); - }, - // 选择机台 - chooseResource(row) { - // 关闭选择模态框 - this.chooseResourceModalFlag = false - - // 将选择的数据填入到保存派工单模态框中 - this.orderDetailData.resourceId = row.resourceId || ''; - this.orderDetailData.resourceDesc = row.resourceDesc || ''; - - this.$message.success('操作成功'); - }, -//非BOM物料选择部分 - // 打开选择物料模态框 - openChoosePartModal() { - // 检查是否选择了主表行 - if (!this.currentRow || !this.currentRow.notifyNo) { - this.$alert('请先选择一条主表记录!', '提示', { - confirmButtonText: '确定' - }) - return false - } - - // 初始化选择物料数据 - this.choosePartData = { - site: this.currentRow.site, - sourceBu: this.currentRow.bu, - partNo: '', - partDesc: '', - spec: '', - } - - // 清空选择列表 - this.choosePartList = [] - - // 打开选择模态框 - this.choosePartModalFlag = true - }, - // 查询物料信息 - searchPartModel() { - // 调用API查询物料信息 - this.$message.warning('正在查询物料信息...'); - - getPartList(this.choosePartData).then(({data}) => { - if (data.code === 0) { - this.choosePartList = data.rows; - if (this.choosePartList.length === 0) { - this.$message.warning('未查询到符合条件的物料'); - } - } else { - this.$message.error(data.msg || '查询失败'); - } - }).catch(error => { - console.error('查询物料失败:', error); - this.$message.error('查询失败,请稍后重试'); - }); - }, - // 选择物料 - choosePart(row) { - // 关闭选择模态框 - this.choosePartModalFlag = false - - // 将选择的数据填入到保存派工单模态框中 - this.orderDetailData.partNo = row.partNo || ''; - this.orderDetailData.partDesc = row.partDesc || ''; - this.orderDetailData.materialType = '非BOM物料'; - - this.$message.success('选择物料成功,数据已填入表单'); - }, }, } diff --git a/src/views/modules/orderIssure/searchIssureNotify_old.vue b/src/views/modules/orderIssure/searchIssureNotify_old.vue new file mode 100644 index 0000000..4926d4e --- /dev/null +++ b/src/views/modules/orderIssure/searchIssureNotify_old.vue @@ -0,0 +1,3085 @@ +4 + + + +