| | |
| | | msg2 = "[" + msg2.ToString() + "]"; |
| | | |
| | | List<Model.Cls_MaterialHandingModel> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.Cls_MaterialHandingModel>>(msg2); |
| | | |
| | | var ds = oCN.RunProcReturn("select * from Gy_Material where HNumber='" + list[0].HMaterNumber + "'", "Gy_Material"); |
| | | |
| | | int HItemID =Convert.ToInt32(list[0].HItemID); |
| | |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | LogService.Write("送货物料信息保存异常:" + e.Message); |
| | | oCN.RollBack(); |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | |
| | | "HBatchNo, HBarcodeQtys, HBarcodeNo, HSupID, HGroupID, HMaker, HMakeDate, HPrintQty, HEndQty, HSupflag, " + |
| | | "HSourceInterID, HSourceEntryID, HSourceBillNo, HSourceBillType, HMTONO, HProduceDate, HExpiryDate, HISKFPERIOD) " + |
| | | "VALUES (" + |
| | | linterid.ToString() + ", '" + TM + "', '" + HBarCodeType + "', " + HMaterID + ", " + "0" + ", " + HQty + ", '" + HKFDate + "', " + HKFPeriod + ", '" + HKFDQDate + "', " + |
| | | linterid.ToString() + ", '" + TM + "', '" + HBarCodeType + "', " + HMaterID + ", " + "0" + ", " + currentQty + ", '" + HKFDate + "', " + HKFPeriod + ", '" + HKFDQDate + "', " + |
| | | "'" + HBatchNo + "', " + get_BarCodecount + ", '" + virtualCount + "', " + HSupID + ", " + "0" + ", '" + ClsPub.CurUserName + "', '" + DateTime.Today.ToString("yyyy-MM-dd") + "', " + "1" + ", " + "0" + ", 1, " + |
| | | "1, 1, '1', '" + HSourceBillType + "', '1', '" + |
| | | HKFDate + "', '" + HKFDQDate + "', " + HISKFPERIOD + ")"; |
| | |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "生成条码成功!"; |
| | | objJsonResult.data = generatedBarcodes; // 返回生成的条码列表 |
| | | objJsonResult.data =string.Join("~", generatedBarcodes); // 返回生成的条码列表 |
| | | WebAPIController.Add_Log("条码下推", UserName, "生成条码"); |
| | | return objJsonResult; |
| | | } |
| | |
| | | } |
| | | |
| | | // 将逗号分隔的条码转换为SQL IN查询条件 |
| | | var barcodeList = barcodes.Split(','); |
| | | var barcodeList = barcodes.Split('~'); |
| | | |
| | | // 构建IN子句,为每个条码添加单引号 |
| | | var inValues = new List<string>(); |
| | |
| | | </Reference> |
| | | <Reference Include="Newtonsoft.Json, Version=13.0.1.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> |
| | | <SpecificVersion>False</SpecificVersion> |
| | | <HintPath>..\..\NewtonsoftJson\Newtonsoft.Json.dll</HintPath> |
| | | <HintPath>..\..\..\智云SRM\Newtonsoft文件\Newtonsoft.Json.dll</HintPath> |
| | | </Reference> |
| | | <Reference Include="NPOI, Version=2.5.6.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL"> |
| | | <HintPath>..\packages\NPOI.2.5.6\lib\net45\NPOI.dll</HintPath> |