qq_41295110
2026-01-13 4e5527d8bf8d89b7b8a3ca2a00ba95e9ca37b5aa
src/views/component/printList/barcode.vue
@@ -70,6 +70,11 @@
          "select * from h_v_IF_BarCodeBillList where hmainid in(" +
          this.handleMessage.linterid.toString() +
          ") order by hmainid desc";
      } else if (this.$route.query.Type == "HGy_BarCodeBillList") {
        sql =
          "select * from h_v_IF_BarCodeBillList where hmainid in(" +
          this.handleMessage.linterid.toString() +
          ") order by hmainid desc";
      } else if (this.$route.query.Type == "HPOInStockBill") {
        sql =
          "select * from h_v_Sc_PrintMouldProdOutBillList where hmainid=" +
@@ -77,23 +82,11 @@
          " order by hmainid";
      } else if (this.$route.query.Type == "HGyStockPlaceBarCode") {
        let condition = decodeURI(this.handleMessage.linterid.toString());
        sql = `SELECT
                CEILING(CAST(t.row_num AS FLOAT) / 2) AS orderid,
                MAX(CASE WHEN t.row_num % 2 = 1 THEN t.条码编号 END) AS 条码编号1,
                MAX(CASE WHEN t.row_num % 2 = 1 THEN t.仓位名称 END) AS 仓位名称1,
                MAX(CASE WHEN t.row_num % 2 = 0 THEN t.条码编号 END) AS 条码编号2,
                MAX(CASE WHEN t.row_num % 2 = 0 THEN t.仓位名称 END) AS 仓位名称2
              FROM (
                SELECT
                  条码编号, 仓位名称,
                  ROW_NUMBER() OVER (ORDER BY t1.HItemID) AS row_num
                FROM h_v_IF_StockPlaceList t1 where 条码编号 in (${condition})
              ) AS t
              GROUP BY CEILING(CAST(t.row_num AS FLOAT) / 2)
              ORDER BY orderid;`;
        condition = condition.split(',').map(e => `'${e}'`).join(',')
        sql = `exec h_p_GetSPBarCode_Swell N'${condition}'`;
      }
      try {
        let res = await axios.get(this.baseUrl + "/CommonModel/searchMethod", {
      try{
        let res =  await axios.get(this.baseUrl + "/CommonModel/searchMethod", {
          params: {
            sql: sql,
            user: sessionStorage["HUserName"],