廖井涛
2024-08-19 1d193f2cc23f54634ef8ed73c11436fbe76bb575
north-glass-erp/northglass-erp/src/components/pp/PrintProcessReplenish.vue
@@ -54,7 +54,7 @@
//   }
// });
// data.value.printList = Object.values(uniqueObjects);
let flowCardCount = data.value.printList.length
let flowCardCount = null
onMounted(() => {
  request.post(`/processCard/getSelectPrintingRefund/${merge}/${like}`, data.value).then((res) => {
        if (res.code == 200) {
@@ -136,7 +136,31 @@
          }
          //处理同配置打印
          // 使用一个对象来存储合并后的结果
          const mergedData = produceList.value.reduce((acc, item) => {
            const processId = item.detail[0].process_id;
            // 如果该 process_id 尚未在 acc 中,初始化其数组
            if (!acc[processId]) {
              acc[processId] = {
                processList: item.processList,
                detailList: [],
                detail: item.detail
              };
            }
            // 合并 detailList
            acc[processId].detailList = acc[processId].detailList.concat(item.detailList);
            return acc;
          }, {});
// 将合并后的对象转换回数组
          produceList.value = Object.values(mergedData);
           flowCardCount=produceList.value.length
          handleSummary()
          handleGetQRCode()
        } else {
@@ -395,7 +419,7 @@
      </tr>
      <tr v-for="(itemtextareas,index) in item.detail" :key="index">
        <td  colspan="29" rowspan="6" style="width: 480px;height: 150px ">
          <div style="width: 100%;height: 100%;"><textarea style="height: 99%;width: 99%;border: none;;font-size: 12px">{{itemtextareas.processing_note}}</textarea>
          <div style="width: 100%;height: 100%;"><textarea style="height: 99%;width: 99%;border: none;;font-size: 12px;text-align: left">{{itemtextareas.processing_note}}</textarea>
          </div>
        </td>
      </tr>