duhe
2025-07-15 e8ba3626a4452ad0419c80146bac357a6a5276ba
WebAPI/Controllers/»ªÔ¶datamapping/HY_DataMappingController.cs
@@ -64,7 +64,7 @@
        public string HPCSNo;                           //PCS号
        public int HPosition_x;                         //PCS所在行的索引
        public int HPosition_y;                         //PCS所在列的索引
        public int HPageIndex;                          //正反面(0:正面,1:反面)
        public string HPageIndex;                          //正反面(0:正面,1:反面)
        public string HBadReason;                       //不良原因
    }
@@ -146,7 +146,7 @@
        public string HPCSNo;                           //PCS号
        public int HPosition_x;                         //PCS所在行的索引
        public int HPosition_y;                         //PCS所在列的索引
        public int HPageIndex;                          //正反面(0:正面,1:反面)
        public string HPageIndex;                          //正反面(0:正面,1:反面)
        public string HBadReason;                       //不良原因
    }
@@ -192,7 +192,7 @@
        public string HPCSNo;                           //PCS号
        public int HPosition_x;                         //PCS所在行的索引
        public int HPosition_y;                         //PCS所在列的索引
        public int HPageIndex;                          //正反面(0:正面,1:反面)
        public string HPageIndex;                          //正反面(0:正面,1:反面)
        public string HBadReason;                       //不良原因
    }
@@ -238,7 +238,7 @@
        public string HPCSNo;                           //PCS号
        public int HPosition_x;                         //PCS所在行的索引
        public int HPosition_y;                         //PCS所在列的索引
        public int HPageIndex;                          //正反面(0:正面,1:反面)
        public string HPageIndex;                          //正反面(0:正面,1:反面)
        public string HBadReason;                       //不良原因
    }
@@ -400,7 +400,7 @@
                        int HPosition_x = vRSInner_SaveCheckNote_RequestParams[i].param[j].HPosition_x;
                        int HPosition_y = vRSInner_SaveCheckNote_RequestParams[i].param[j].HPosition_y;
                        string HCheckProc = "炬森VRS内层";
                        int HPageIndex = vRSInner_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HPageIndex = vRSInner_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HBadReason = vRSInner_SaveCheckNote_RequestParams[i].param[j].HBadReason;
                        //根据PNL条码找到PNL对于的PNL布局信息。然后根据PCS号在PNL布局信息中找到PCS对应的set号
@@ -430,7 +430,7 @@
                            "," + HPosition_x + "" +
                            "," + HPosition_y + "" +
                            ",'" + HCheckProc + "'" +
                            "," + HPageIndex + "" +
                            ",'" + HPageIndex + "'" +
                            ",'" + HBadReason + "'" +
                            ",'" + HMaker + "'" +
                            ",getdate() " +
@@ -685,7 +685,7 @@
                        int HPosition_x = vRSOuter_SaveCheckNote_RequestParams[i].param[j].HPosition_x;
                        int HPosition_y = vRSOuter_SaveCheckNote_RequestParams[i].param[j].HPosition_y;
                        string HCheckProc = "炬森VRS外层";
                        int HPageIndex = vRSOuter_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HPageIndex = vRSOuter_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HBadReason = vRSOuter_SaveCheckNote_RequestParams[i].param[j].HBadReason;
                        //根据PNL条码找到PNL对于的PNL布局信息。然后根据PCS号在PNL布局信息中找到PCS对应的set号
@@ -715,7 +715,7 @@
                            "," + HPosition_x + "" +
                            "," + HPosition_y + "" +
                            ",'" + HCheckProc + "'" +
                            "," + HPageIndex + "" +
                            ",'" + HPageIndex + "'" +
                            ",'" + HBadReason + "'" +
                            ",'" + HMaker + "'" +
                            ",getdate() " +
@@ -884,42 +884,35 @@
                    for (int j = 0; j < aVI_SaveCheckNote_RequestParams[i].param.Count; j++)
                    {
                        string HBarCode = aVI_SaveCheckNote_RequestParams[i].param[j].HBarCode;
                        string HSetNo = "";
                        string HBarCode_PNL = "";
                        string HSetNo = HBarCode.Substring(HBarCode.Length - 2, 2);
                        string HPCSNo = aVI_SaveCheckNote_RequestParams[i].param[j].HPCSNo;
                        int HPosition_x = aVI_SaveCheckNote_RequestParams[i].param[j].HPosition_x;
                        int HPosition_y = aVI_SaveCheckNote_RequestParams[i].param[j].HPosition_y;
                        string HCheckProc = "AVI";
                        int HPageIndex = aVI_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HPageIndex = aVI_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HBadReason = aVI_SaveCheckNote_RequestParams[i].param[j].HBadReason;
                        //根据PNL条码找到PNL对于的PNL布局信息。然后根据PCS号在PNL布局信息中找到PCS对应的set号
                        string sql_set = "" +
                            "select distinct " +
                            "   b.HSetNo " +
                            "from Gy_PNLInfo as a " +
                            "inner join Gy_PNLInfoSub as b on a.HInterID = b.HInterID " +
                            "where a.HLayOutName in " +
                            "   ( " +
                            "      select HLayOutName from Gy_BarCodeBill_PNL_Temp where HBarCode = '" + HBarCode + "' " +
                        //根据set条码编号,获取set所属的PNL条码编号
                        string sql_PNLBarCode = "" +
                            //"select * from Gy_BarCodeBill_Set_His where HBarCode = '" + HBarCode + "' " +
                            //"      union " +
                            //"      select HLayOutName from Gy_BarCodeBill_PNL_His where HBarCode = '" + HBarCode + "' " +
                            "   ) " +
                            "and b.HPCSNo = '" + HPCSNo + "' ";
                        ds = oCN.RunProcReturn(sql_set, "Gy_PNLInfo");
                            "select * from Gy_BarCodeBill_Set_Temp where HBarCode = '" + HBarCode + "' ";
                        ds = oCN.RunProcReturn(sql_PNLBarCode, "Gy_BarCodeBill_Set_Temp");
                        if (ds != null && ds.Tables.Count > 0 && ds.Tables[0].Rows.Count > 0)
                        {
                            HSetNo = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HSetNo"]);
                            HBarCode_PNL = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBarCode_PNL"]);
                        }
                        string sql = "insert into QC_CheckNote_PNL_Temp(HBarCode,HSetNo,HPCSNo,HPosition_x,HPosition_y,HCheckProc,HPageIndex,HBadReason,HMaker,HMakeDate) " +
                            "values(" +
                            "'" + HBarCode + "'" +
                            "'" + HBarCode_PNL + "'" +
                            ",'" + HSetNo + "'" +
                            ",'" + HPCSNo + "'" +
                            "," + HPosition_x + "" +
                            "," + HPosition_y + "" +
                            ",'" + HCheckProc + "'" +
                            "," + HPageIndex + "" +
                            ",'" + HPageIndex + "'" +
                            ",'" + HBadReason + "'" +
                            ",'" + HMaker + "'" +
                            ",getdate() " +
@@ -1038,7 +1031,7 @@
                        int HPosition_x = dC_SaveCheckNote_RequestParams[i].param[j].HPosition_x;
                        int HPosition_y = dC_SaveCheckNote_RequestParams[i].param[j].HPosition_y;
                        string HCheckProc = "电测";
                        int HPageIndex = dC_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HPageIndex = dC_SaveCheckNote_RequestParams[i].param[j].HPageIndex;
                        string HBadReason = dC_SaveCheckNote_RequestParams[i].param[j].HBadReason;
                        //根据set条码编号,获取set所属的PNL条码编号
@@ -1060,7 +1053,7 @@
                            "," + HPosition_x + "" +
                            "," + HPosition_y + "" +
                            ",'" + HCheckProc + "'" +
                            "," + HPageIndex + "" +
                            ",'" + HPageIndex + "'" +
                            ",'" + HBadReason + "'" +
                            ",'" + HMaker + "'" +
                            ",getdate() " +