chenhaozhe
2025-09-25 9d8435352f7a1ac512554f9d22ce2a63d1b98f95
WebAPI/Controllers/LMESController.cs
@@ -647,6 +647,7 @@
                            sql = "select top 1000 * from h_v_Sc_ProcessExchangeArrangementList_PG where 1 = 1 " + sWhere;
                        }
                    }
                    sql = "select top 1000 * from h_v_Sc_ProcessExchangeArrangementList_PG where 1 = 1 " + sWhere + " ";
                    SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                    ds = oCN.RunProcReturn(sql, "h_v_Sc_ProcessExchangeArrangementList_PG");
@@ -3374,6 +3375,31 @@
            return CustomCorrect(ds);
        }
        [Route("LEMS/SaveToSc_PackUnionBillSub_Batch")]
        [HttpGet]
        public object SaveToSc_PackUnionBillSub_Batch(string HitemID, string HRemark)
        {
            DataSet ds;
            try
            {
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                if (HitemID == null || HitemID.Equals(""))
                {
                    return CustomError("更新失败HitemID为空!");
                }
                else
                {
                    ds = oCN.RunProcReturn("exec h_p_Save_KF_PonderationBillMain_TempToSc_PackUnionBillSub_Batch '" + HitemID + "','" + HRemark + "'", "h_p_Save_KF_PonderationBillMain_TempToSc_PackUnionBillSub_Batch");
                }
            }
            catch (Exception e)
            {
                ds = null;
            }
            return CustomCorrect(ds);
        }
        //更新没有反写的数据
        [Route("LEMS/SaveToSc_PackUnionBillSub_Back")]
        [HttpGet]
@@ -3428,6 +3454,31 @@
                else
                {
                    ds = oCN.RunProcReturn("exec h_p_Update_Flag_HRelationInterID '" + HitemID + "'", "h_p_Update_Flag_HRelationInterID");
                }
            }
            catch (Exception e)
            {
                ds = null;
            }
            return CustomCorrect(ds);
        }
        [Route("LEMS/Update_Flag_HRelationInterID_Batch")]
        [HttpGet]
        public object Update_Flag_HRelationInterID_Batch(string HitemID)
        {
            DataSet ds;
            try
            {
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                if (HitemID == null || HitemID.Equals(""))
                {
                    return CustomError("更新失败HitemID为空!");
                }
                else
                {
                    ds = oCN.RunProcReturn("exec h_p_Update_Flag_HRelationInterID_Batch '" + HitemID + "'", "h_p_Update_Flag_HRelationInterID_Batch");
                }
            }
@@ -3608,11 +3659,11 @@
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                if (sWhere == null || sWhere.Equals(""))
                {
                    ds = oCN.RunProcReturn("select top 1000 * from h_v_ProductionLinePackagingList order by 扫码日期 desc, 唯一条码 desc", "h_v_ProductionLinePackagingList");
                    ds = oCN.RunProcReturn("select top 300 * from h_v_ProductionLinePackagingList order by 扫码日期 desc, 唯一条码 desc", "h_v_ProductionLinePackagingList");
                }
                else
                {
                    string sql1 = "select top 1000 * from h_v_ProductionLinePackagingList where 1 = 1 ";
                    string sql1 = "select top 300 * from h_v_ProductionLinePackagingList where 1 = 1 ";
                    string sql = sql1 + sWhere;
                    string sql2 = " order by 扫码日期 desc, 唯一条码 desc";
                    sql = sql + sql2;
@@ -3880,7 +3931,7 @@
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "[0000-1-051]" + ds.Tables[0].Rows[0]["HBackRemark"].ToString();
                        objJsonResult.Message =ds.Tables[0].Rows[0]["HBackRemark"].ToString();
                        return objJsonResult;
                    }
                    else