guoyujie
2025-05-26 02609fcedd8fb55383da0a1f823a8cba913510e7
north-glass-erp/northglass-erp/src/components/pp/PrintProcessReplenish.vue
@@ -21,7 +21,8 @@
const data = ref({
  printList: []
  printList: [],
  processName:[]
})
let props = defineProps({
@@ -71,6 +72,7 @@
  request.post(`/processCard/getSelectPrintingRefund/${merge}/${like}/${mergeTechnologyNumber}`, data.value).then((res) => {
        if (res.code == 200) {
          produceList.value = deepClone(res.data.data)
          data.processName   = res.data.data[0].processNameList
          //处理单片厚度
          for (let j = 0; j < produceList.value.length; j++) {
@@ -93,33 +95,34 @@
            produceList.value[j].detail[0].weight = sumWeight
          }
          //处理合并打印
          if (printMerge !== null && printMerge !== undefined && printMerge !== "") {
            produceList.value.forEach(item => {
              item.detail[0].technologyNumber = printMerge;
            });
            //合并打印工艺流程处理
            if (like == null) {
              let process = produceList.value[0].detail[0].process
              let indexOfJiaJiao = process.indexOf('夹胶');
              if (indexOfJiaJiao !== -1) {
                // 使用 substring 截取 "夹胶" 后面的部分,包括 "夹胶" 本身
                let afterJiaJiao = process.substring(indexOfJiaJiao).trim();
                produceList.value.forEach(item => {
                  item.detail[0].process = afterJiaJiao
                })
              }
              let indexOfProceList = produceList.value[0].processList
              let getProceList = indexOfProceList.findIndex(item => item.process === '夹胶');
              if (getProceList !== -1) {
                // 使用 filter 方法过滤出 "夹胶" 及其之后的对象
                produceList.value[0].processList = indexOfProceList.filter((item, index) => index >= getProceList);
              }
            }
          }
          // if (printMerge !== null && printMerge !== undefined && printMerge !== "") {
          //
          //   produceList.value.forEach(item => {
          //     item.detail[0].technologyNumber = printMerge;
          //   });
          //
          //   //合并打印工艺流程处理
          //   if (like == null) {
          //     let process = produceList.value[0].detail[0].process
          //     console.log(process)
          //     let indexOfJiaJiao = process.indexOf('夹胶');
          //     if (indexOfJiaJiao !== -1) {
          //       // 使用 substring 截取 "夹胶" 后面的部分,包括 "夹胶" 本身
          //       let afterJiaJiao = process.substring(indexOfJiaJiao).trim();
          //       produceList.value.forEach(item => {
          //         item.detail[0].process = afterJiaJiao
          //       })
          //     }
          //
          //     let indexOfProceList = produceList.value[0].processList
          //     let getProceList = indexOfProceList.findIndex(item => item.process === '夹胶');
          //
          //     if (getProceList !== -1) {
          //       // 使用 filter 方法过滤出 "夹胶" 及其之后的对象
          //       produceList.value[0].processList = indexOfProceList.filter((item, index) => index >= getProceList);
          //     }
          //   }
          // }
          produceList.value.forEach(item => {