| | |
| | | string sql1 = string.Format(@"select * from h_v_Gy_MaterialList where 组织名称='" + Organization + "'"); |
| | | if (sWhere == null || sWhere.Equals("")) |
| | | { |
| | | ds = oCN.RunProcReturn(sql1 + sWhere + " order by 物料代码 ", "h_v_Gy_MaterialList"); |
| | | ds = oCN.RunProcReturn(sql1 + sWhere + " order by 物料代码 desc", "h_v_Gy_MaterialList"); |
| | | } |
| | | else |
| | | { |
| | | string sql = sql1 + sWhere + " order by 物料代码 "; |
| | | string sql = sql1 + sWhere + " order by 物料代码 desc"; |
| | | ds = oCN.RunProcReturn(sql, "h_v_Gy_MaterialList"); |
| | | } |
| | | |
| | |
| | | string HInterID = HInter.Replace("\"", ""); |
| | | string user = sArray[1].ToString(); |
| | | string HBarCode = sArray[2].ToString().Replace("\"",""); |
| | | string HComputerName = SystemInformation.ComputerName; //设备名称 |
| | | |
| | | //编辑权限 |
| | | if (!DBUtility.ClsPub.Security_Log("Gy_BarCodeBillList_Edit", 1, false, user)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "无删除权限!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | string HComputerName = SystemInformation.ComputerName; //设备名称 |
| | | |
| | | try |
| | | { |
| | |
| | | |
| | | string[] NewBarCode; |
| | | NewBarCode = HBarCode.Split(Convert.ToChar(",")); |
| | | |
| | | //编辑权限 |
| | | if (!DBUtility.ClsPub.Security_Log("Gy_BarCodeBill_Del", 1, false, user)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "无删除权限!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //删除条码前进行判断 |
| | | Ds = oCN.RunProcReturn("exec h_p_Gy_BarCodeBill_MulDelete_Before '" + HInterID + "','" + HBarCode + "'", "h_p_Gy_BarCodeBill_MulDelete_Before", ref DBUtility.ClsPub.sExeReturnInfo); |
| | |
| | | { |
| | | oCN.BeginTran(); |
| | | |
| | | ////获取系统参数 |
| | | //string Ret = ""; |
| | | //if (oSystemParameter.ShowBill(ref Ret)) |
| | | //{ |
| | | // //判断是否只能删除自己生成的条码 |
| | | // if (oSystemParameter.omodel.BarCode_DeleterAndMakerllustSame != "龙山汽配") //系统参数 |
| | | // { |
| | | |
| | | // } |
| | | //} |
| | | |
| | | oCN.RunProc("Delete from Gy_BarCodeBill Where HItemID in (" + HInterID + ")"); |
| | | //获取系统参数 |
| | | string Ret = ""; |
| | | if (oSystemParameter.ShowBill(ref Ret)) |
| | | { |
| | | //判断是否只能删除自己生成的条码 |
| | | if (oSystemParameter.omodel.BarCode_DeleterAndMakerMustSame == "Y") //系统参数 |
| | | { |
| | | oCN.RunProc("Delete from Gy_BarCodeBill Where HItemID in (" + HInterID + ")" + " and HMaker = '" + user + "'"); |
| | | } |
| | | else |
| | | { |
| | | oCN.RunProc("Delete from Gy_BarCodeBill Where HItemID in (" + HInterID + ")"); |
| | | } |
| | | } |
| | | |
| | | //写入系统日志 |
| | | for (int i = 0; i <= NewBarCode.Length - 1; i++) |