纽威
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

394 lines
24 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
2 years ago
3 years ago
2 years ago
2 years ago
2 years ago
3 years ago
2 years ago
3 years ago
2 years ago
2 years ago
2 years ago
3 years ago
2 years ago
3 years ago
2 years ago
2 years ago
2 years ago
2 years ago
3 years ago
2 years ago
3 years ago
2 years ago
2 years ago
2 years ago
3 years ago
2 years ago
2 years ago
2 years ago
3 years ago
3 years ago
  1. using ICSSoft.Common;
  2. using ICSSoft.Entity;
  3. using System;
  4. using System.Collections.Generic;
  5. using System.Data;
  6. using System.Data.SqlClient;
  7. using System.Linq;
  8. using System.Text;
  9. using System.Threading.Tasks;
  10. namespace ICSSoft.DataProject
  11. {
  12. public class DisassemblyDoc
  13. {
  14. private static log4net.ILog log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
  15. private static string connString = System.Configuration.ConfigurationManager.AppSettings["ERPConnStr"];
  16. private static string ERPDB = System.Configuration.ConfigurationManager.AppSettings["ERPDB"];
  17. private static string Type = System.Configuration.ConfigurationManager.AppSettings["Type"];
  18. private static string CRNALL = System.Configuration.ConfigurationManager.AppSettings["DisaRCRDNAME"];
  19. /// <summary>
  20. /// 审核拆卸单
  21. /// </summary>
  22. /// <param name="Bills"></param>
  23. /// <returns></returns>
  24. public bool Dismrecord01(List<ICSDisassemblyDoc> Bills)
  25. {
  26. bool ResultFlag = false;
  27. string connS = "";
  28. SqlConnection conn = new SqlConnection();
  29. SqlCommand cmd = new SqlCommand();
  30. if (Bills.Count <= 0)
  31. {
  32. throw new Exception("传送数据为空!");
  33. }
  34. LogInfo(Bills);
  35. List<string> result = Bills.Select(t => t.WorkPoint).Distinct().ToList();
  36. foreach (string WorkPoint in result)
  37. {
  38. try
  39. {
  40. connS = string.Format(connString, WorkPoint);
  41. conn = new System.Data.SqlClient.SqlConnection(connS);
  42. conn.Open();
  43. SqlTransaction sqlTran = conn.BeginTransaction();
  44. cmd = new SqlCommand();
  45. cmd.Transaction = sqlTran;
  46. cmd.Connection = conn;
  47. foreach (ICSDisassemblyDoc head in Bills)
  48. {
  49. if (WorkPoint != head.WorkPoint)
  50. {
  51. continue;
  52. }
  53. if (!DBHelper.IsInventoryConsolidation(cmd, head.WorkPoint))
  54. throw new Exception("U8正在整理现存量,请稍后再试");
  55. string[] ss = head.WorkPoint.Split('_');
  56. ERPDB = ss[1];
  57. string sql = "";
  58. ICSUserInfo userInfo = new ICSUserInfo();
  59. userInfo = DBHelper.GetPersonInfo(head.User, cmd);
  60. string cHandler = string.Empty;
  61. string cIWhCode = string.Empty;
  62. #region 检验单号是否存在
  63. sql = "select * from AssemVouch where ID='" + head.ID + "'";
  64. DataTable dt = DBHelper.SQlReturnData(sql, cmd);
  65. if (dt != null && dt.Rows.Count > 0)
  66. {
  67. cHandler = dt.Rows[0]["cVerifyPerson"].ToString();
  68. //cIWhCode = head.cWhCode;
  69. if (!string.IsNullOrEmpty(cHandler))
  70. {
  71. throw new Exception("单据ID:" + head.ID + "不是开立状态!");
  72. }
  73. }
  74. else
  75. {
  76. throw new Exception("单据ID:" + head.ID + "在U8中不存在!");
  77. }
  78. #endregion
  79. #region 审核拆卸单
  80. sql = @"UPDATE dbo.AssemVouch SET cVerifyPerson='" + userInfo.UserName + @"' ,
  81. dVerifyDate=CONVERT(VARCHAR(50),GETDATE(),112),dnverifytime=GETDATE() WHERE ID='" + head.ID + "'";
  82. DBHelper.CmdExecuteNonQuery(sql, cmd, "审核拆卸单失败!");
  83. #endregion
  84. #region 其他出库单表头
  85. string[] dd = CRNALL.Split('~');
  86. string crdname = dd[0];
  87. string carname = dd[1];
  88. string crdname1 = dd[2];
  89. string carname1 = dd[3];
  90. string surface = dd[4];
  91. string cRDcode = DBHelper.GetRDCode(crdname, cmd);
  92. string cRDcode1 = DBHelper.GetRDCode(crdname1, cmd);
  93. string cardnewcode = DBHelper.GetCardNumber(carname, cmd);
  94. string cardnewcode1 = DBHelper.GetCardNumber(carname1, cmd);
  95. //取得out库单的默认显示模版
  96. string DEF_ID09 = DBHelper.GetDefaultTemplate(cardnewcode1, cmd);
  97. //取得采购入库单单据 表头ID,表体DID
  98. VouchKey key09 = new VouchKey();
  99. var nums = Bills.Count;
  100. Dictionary<string, int> dics = DBHelper.GetAllCode("" + ERPDB + "", surface, "" + nums + "", head.WorkPoint, cmd);
  101. int iFatherIds = Convert.ToInt32(dics["iFatherId"].ToString());
  102. int iChildIds = Convert.ToInt32(dics["iChildId"].ToString());
  103. DateTime dates = DateTime.Now;
  104. string iBaseCodeLens = DBHelper.GetAllRDCode(cardnewcode, "" + dates + "", "admin", cRDcode, head.WorkPoint, cmd);
  105. sql = @"INSERT INTO dbo.RdRecord09
  106. (ID,bRdFlag,cVouchType,cBusType,cSource,cBusCode,cWhCode,dDate,cCode,cRdCode,
  107. cHandler,cMemo,bTransFlag,cMaker,dVeriDate,bpufirst,biafirst,VT_ID,bIsSTQc,bOMFirst,
  108. bFromPreYear,bIsComplement,iDiscountTaxType,ireturncount,
  109. iverifystate,iswfcontrolled,dnmaketime,dnverifytime,bredvouch,cSourceLs,cDepCode)
  110. SELECT top 1 @ID,'0','09','','',a.cAVCode,b.cWhCode,CONVERT(NVARCHAR(15),GETDATE(),23),@cCode,@cRdCode,
  111. @cHandler,@cMemo,'0',@cMaker,CONVERT(NVARCHAR(15),GETDATE(),23),'0','0',
  112. '85','0','0','0','0','0','0','0','0',GETDATE(),GETDATE(),'0',null,cDepCode
  113. from dbo.AssemVouch a
  114. inner join AssemVouchs b on a.id=b.id
  115. WHERE a.ID='" + head.ID + "' and bAVType='' ";
  116. cmd.Parameters.Clear();
  117. cmd.Parameters.Add(new SqlParameter("@ID", iFatherIds));
  118. cmd.Parameters.Add(new SqlParameter("@cCode", iBaseCodeLens));
  119. cmd.Parameters.Add(new SqlParameter("@cHandler", userInfo.UserName));
  120. cmd.Parameters.Add(new SqlParameter("@cMemo", ""));
  121. cmd.Parameters.Add(new SqlParameter("@cMaker", userInfo.UserName));
  122. cmd.Parameters.Add(new SqlParameter("@VT_ID", DEF_ID09));
  123. cmd.Parameters.Add(new SqlParameter("@cRdCode", cRDcode1));
  124. cmd.CommandText = sql;
  125. try
  126. {
  127. cmd.ExecuteNonQuery();
  128. }
  129. catch (Exception ex)
  130. {
  131. log.Error("生成其他出库单失败!拆卸单ID:" + head.ID + ";异常:" + ex.Message + ";SQL:\r\n" + sql);
  132. throw new Exception("程序异常,请联系开发人员!");
  133. }
  134. #endregion
  135. #region 3.5 其他出库单表体
  136. #region 检验单号是否存在
  137. sql = "select iAVQuantity,iAVNum,* from AssemVouchs where ID='" + head.ID + "' and bAVType='套件'";
  138. DataTable dsh = DBHelper.SQlReturnData(sql, cmd);
  139. if (dsh != null && dsh.Rows.Count > 0)
  140. {
  141. cIWhCode = dsh.Rows[0]["cWhCode"].ToString();
  142. }
  143. else
  144. {
  145. throw new Exception("单据ID:" + head.ID + "在U8中不存在!");
  146. }
  147. //判断物料批号与现存量表批号是否一致、数量不能超过现存量物料数量
  148. sql = @"SELECT cBatch,iQuantity from CurrentStock WHERE cInvCode='" + dsh.Rows[0]["cInvCode"].ToString() + "'AND cBatch='" + dsh.Rows[0]["cAVBatch"].ToString() + @"'AND cFree1='" + dsh.Rows[0]["cFree1"].ToString() + @"' AND cFree2='" + dsh.Rows[0]["cFree2"].ToString() + @"' AND cFree3='" + dsh.Rows[0]["cFree3"].ToString() + @"' AND cFree4='" + dsh.Rows[0]["cFree4"].ToString() + @"' AND cFree5='" + dsh.Rows[0]["cFree5"].ToString() + @"' AND cFree6='" + dsh.Rows[0]["cFree6"].ToString() + @"' AND cFree7='" + dsh.Rows[0]["cFree7"].ToString() + @"' AND cFree8='" + dsh.Rows[0]["cFree8"].ToString() + @"' AND cFree9='" + dsh.Rows[0]["cFree9"].ToString() + @"' AND cFree10='" + dsh.Rows[0]["cFree10"].ToString() + @"' and cWhCode='" + dsh.Rows[0]["cWhCode"].ToString() + "'";
  149. //sql = @"SELECT cBatch,iQuantity from CurrentStock WHERE cInvCode='" + dsh.Rows[0]["cInvCode"].ToString() + "'AND cBatch=''and cWhCode='" + dsh.Rows[0]["cWhCode"].ToString() + "'";
  150. DataTable dtItem = DBHelper.SQlReturnData(sql, cmd);
  151. if (dtItem != null && dtItem.Rows.Count > 0)
  152. {
  153. if (Convert.ToDecimal(dtItem.Rows[0]["iQuantity"].ToString()) < Convert.ToInt32(dsh.Rows[0]["iAVQuantity"].ToString()))
  154. {
  155. throw new Exception("物料条码的数量大于U8现存量物料数量,物料:" + dsh.Rows[0]["cInvCode"].ToString());
  156. }
  157. }
  158. else
  159. {
  160. throw new Exception("物料:" + dsh.Rows[0]["cInvCode"].ToString() + "在现存量表中不存在!");
  161. }
  162. #endregion
  163. #region 3.5.1 表体
  164. sql = @"INSERT INTO dbo.rdrecords09
  165. (AutoID,ID,cInvCode,iQuantity,iSOutQuantity,iSOutNum,iFlag,iTrIds,iNQuantity,iNum,
  166. cMassUnit,bLPUseFree,iRSRowNO,iOriTrackID,bCosting,bVMIUsed,iExpiratDateCalcu,iordertype,irowno,cbaccounter,cBatch,iPUnitCost,iPPrice,cFree1,cFree2,cFree3,cFree4,cFree5,cFree6,cFree7,cFree8,cFree9,cFree10)
  167. SELECT @AutoID,@ID,cInvCode,iAVQuantity,'0','0','0',a.autoID,iAVQuantity,iAVNum,
  168. '0','0','0','0','1','0','0','0',a.irowno,null,cAVBatch,iAVPCost,iAVPPrice,cFree1,cFree2,cFree3,cFree4,cFree5,cFree6,cFree7,cFree8,cFree9,cFree10
  169. from AssemVouchs a
  170. where ID=" + head.ID + @" and bAVType='' ;";
  171. cmd.Parameters.Clear();
  172. cmd.Parameters.Add(new SqlParameter("@AutoID", iChildIds));
  173. cmd.Parameters.Add(new SqlParameter("@ID", iFatherIds));
  174. cmd.CommandText = sql;
  175. try
  176. {
  177. cmd.ExecuteNonQuery();
  178. }
  179. catch (Exception ex)
  180. {
  181. log.Error("生成其他出库单表体失败!拆卸单ID:" + head.ID + ";异常:" + ex.Message + ";SQL:\r\n" + sql);
  182. throw new Exception("程序异常,请联系开发人员!");
  183. }
  184. sql = @"INSERT INTO dbo.rdrecords09sub
  185. ( AutoID , ID ,iBG_Ctrl , iBGSTSum )
  186. values('" + iChildIds + "','" + iFatherIds + "',0,0)";
  187. cmd.CommandText = sql;
  188. cmd.ExecuteNonQuery();
  189. #endregion
  190. if (head.UpdateStock)
  191. {
  192. //更新现存量
  193. key09.cBustypeUN = "拆卸出库";
  194. key09.cVouchTypeUN = "09";
  195. key09.TableName = "IA_ST_UnAccountVouch09";
  196. //DBHelper.UpdateCurrentStock(cmd, dsh.Rows[0]["cInvCode"].ToString(), cIWhCode, "", -Convert.ToDecimal(dsh.Rows[0]["iAVQuantity"].ToString()), key09);
  197. //DBHelper.UpdateCurrentStockNEW(cmd, dsh.Rows[0]["cInvCode"].ToString(), cIWhCode, dsh.Rows[0]["cAVBatch"].ToString(), -Convert.ToDecimal(dsh.Rows[0]["iAVQuantity"].ToString()), dsh.Rows[0]["cFree1"].ToString(), dsh.Rows[0]["cFree2"].ToString(), dsh.Rows[0]["cFree3"].ToString(), dsh.Rows[0]["cFree4"].ToString(), dsh.Rows[0]["cFree5"].ToString(), dsh.Rows[0]["cFree6"].ToString(), dsh.Rows[0]["cFree7"].ToString(), dsh.Rows[0]["cFree8"].ToString(), dsh.Rows[0]["cFree9"].ToString(), dsh.Rows[0]["cFree10"].ToString(), key09);
  198. string inum = dsh.Rows[0]["iAVNum"].ToString();
  199. if (inum == "")
  200. {
  201. inum = "0";
  202. }
  203. DBHelper.UpdateCurrentStockCCGC(cmd, dsh.Rows[0]["cInvCode"].ToString(), cIWhCode, dsh.Rows[0]["cAVBatch"].ToString(),
  204. -Convert.ToDecimal(dsh.Rows[0]["iAVQuantity"].ToString()), -Convert.ToDecimal(inum), dsh.Rows[0]["cFree1"].ToString(),
  205. dsh.Rows[0]["cFree2"].ToString(), dsh.Rows[0]["cFree3"].ToString(), dsh.Rows[0]["cFree4"].ToString(), dsh.Rows[0]["cFree5"].ToString(), dsh.Rows[0]["cFree6"].ToString(), dsh.Rows[0]["cFree7"].ToString(), dsh.Rows[0]["cFree8"].ToString(), dsh.Rows[0]["cFree9"].ToString(), dsh.Rows[0]["cFree10"].ToString(),
  206. "", key09, "", "", "", "", 0, 0, 0, 0, 0, 0, 0, 0, iFatherIds, iChildIds);
  207. }
  208. //DBHelper.UpdateIDandDID("rd", ErpName, head.list.Count(), cmd);
  209. #endregion
  210. sql = "select cWhCode from dbo.AssemVouchs where ID='" + head.ID + "' and bAVType='散件' group by cWhCode;";
  211. DataTable dtChecks = DBHelper.SQlReturnData(sql, cmd);
  212. int iChildId = 0;
  213. int iFatherId = 0;
  214. VouchKey key08 = new VouchKey();
  215. for (int i = 0; i < dtChecks.Rows.Count; i++)
  216. {
  217. #region 其他入库单表头
  218. //取得out库单的默认显示模版
  219. string DEF_ID08 = DBHelper.GetDefaultTemplate(cardnewcode, cmd);
  220. //取得采购入库单单据 表头ID,表体DID
  221. var num = Bills.Count;
  222. Dictionary<string, int> dic = DBHelper.GetAllCode("" + ERPDB + "", surface, "" + num + "", head.WorkPoint, cmd);
  223. iFatherId = Convert.ToInt32(dic["iFatherId"].ToString());
  224. iChildId = Convert.ToInt32(dic["iChildId"].ToString());
  225. DateTime date = DateTime.Now;
  226. string iBaseCodeLen = DBHelper.GetAllRDCode(cardnewcode, "" + date + "", "admin", cRDcode, head.WorkPoint, cmd);
  227. sql = @"INSERT INTO dbo.RdRecord08
  228. (ID,bRdFlag,cVouchType,cBusType,cSource,cBusCode,cWhCode,dDate,cCode,cRdCode,
  229. cHandler,cMemo,bTransFlag,cMaker,dVeriDate,bpufirst,biafirst,VT_ID,bIsSTQc,bOMFirst,
  230. bFromPreYear,bIsComplement,iDiscountTaxType,ireturncount,
  231. iverifystate,iswfcontrolled,dnmaketime,dnverifytime,bredvouch,cSourceLs,cDepCode)
  232. SELECT top 1 @ID,'1','08','','',a.cAVCode,@cWhCode,CONVERT(NVARCHAR(15),GETDATE(),23),@cCode,@cRdCode,
  233. @cHandler,@cMemo,'0',@cMaker,CONVERT(NVARCHAR(15),GETDATE(),23),'0','0',
  234. @VT_ID,'0','0','0','0','0','0','0','0',GETDATE(),GETDATE(),'0',null,cDepCode
  235. from dbo.AssemVouch a
  236. WHERE id='" + head.ID + "' ";
  237. cmd.Parameters.Clear();
  238. cmd.Parameters.Add(new SqlParameter("@ID", iFatherId));
  239. //cmd.Parameters.Add(new SqlParameter("@cBusCode", head.cCode));
  240. cmd.Parameters.Add(new SqlParameter("@cWhCode", dtChecks.Rows[0]["cWhCode"].ToString()));
  241. cmd.Parameters.Add(new SqlParameter("@cCode", iBaseCodeLen));
  242. cmd.Parameters.Add(new SqlParameter("@cHandler", userInfo.UserName));
  243. cmd.Parameters.Add(new SqlParameter("@cMemo", ""));
  244. cmd.Parameters.Add(new SqlParameter("@cMaker", userInfo.UserName));
  245. cmd.Parameters.Add(new SqlParameter("@VT_ID", DEF_ID08));
  246. cmd.Parameters.Add(new SqlParameter("@cRdCode", cRDcode));
  247. cmd.CommandText = sql;
  248. try
  249. {
  250. cmd.ExecuteNonQuery();
  251. }
  252. catch (Exception ex)
  253. {
  254. log.Error("生成其他入库单表头失败!拆卸ID:" + head.ID + ";异常:" + ex.Message + ";SQL:\r\n" + sql);
  255. throw new Exception("程序异常,请联系开发人员!");
  256. }
  257. #endregion
  258. sql = "select * from AssemVouchs where ID='" + head.ID + "' and bAVType='散件' and cWhCode='" + dtChecks.Rows[i]["cWhCode"].ToString() + "' ";
  259. DataTable ds = DBHelper.SQlReturnData(sql, cmd);
  260. for (int j = 0; j < ds.Rows.Count; j++)
  261. {
  262. #region 其他入库单表体
  263. if (ds != null && ds.Rows.Count > 0)
  264. {
  265. cIWhCode = ds.Rows[j]["cWhCode"].ToString();
  266. }
  267. else
  268. {
  269. throw new Exception("单据号:" + head.ID + "在U8中不存在!");
  270. }
  271. sql = @"INSERT INTO dbo.rdrecords08
  272. (AutoID,ID,cInvCode,iQuantity,iSOutQuantity,iSOutNum,iFlag,iTrIds,iNQuantity,iNum,
  273. cMassUnit,bLPUseFree,iRSRowNO,iOriTrackID,bCosting,bVMIUsed,iExpiratDateCalcu,iordertype,irowno,cbaccounter,cBatch,iPUnitCost,iPPrice,cFree1,cFree2,cFree3,cFree4,cFree5,cFree6,cFree7,cFree8,cFree9,cFree10)
  274. SELECT @AutoID,@ID,cInvCode,a.iAVQuantity,'0','0','0',a.AutoID,iAVQuantity,iAVNum,
  275. '0','0','0','0','1','0','0','0',a.irowno,null,cAVBatch,iAVPCost,iAVPPrice,cFree1,cFree2,cFree3,cFree4,cFree5,cFree6,cFree7,cFree8,cFree9,cFree10 from AssemVouchs a
  276. where a.autoID=" + ds.Rows[j]["autoID"].ToString() + @" ;";
  277. cmd.Parameters.Clear();
  278. cmd.Parameters.Add(new SqlParameter("@AutoID", iChildId));
  279. cmd.Parameters.Add(new SqlParameter("@ID", iFatherId));
  280. cmd.CommandText = sql;
  281. try
  282. {
  283. cmd.ExecuteNonQuery();
  284. }
  285. catch (Exception ex)
  286. {
  287. log.Error("生成其他出库单表体失败!拆卸单单号:" + head.ID + ";异常:" + ex.Message + ";SQL:\r\n" + sql);
  288. throw new Exception("程序异常,请联系开发人员!");
  289. }
  290. if (head.UpdateStock)
  291. {
  292. //更新现存量
  293. key08.cBustypeUN = "拆卸入库";
  294. key08.cVouchTypeUN = "08";
  295. key08.TableName = "IA_ST_UnAccountVouch08";
  296. //DBHelper.UpdateCurrentStockNEW(cmd, ds.Rows[j]["cInvCode"].ToString(), cIWhCode, ds.Rows[j]["cAVBatch"].ToString(), Convert.ToDecimal(ds.Rows[j]["iAVQuantity"].ToString()), ds.Rows[j]["cFree1"].ToString(), ds.Rows[j]["cFree2"].ToString(), ds.Rows[j]["cFree3"].ToString(), ds.Rows[j]["cFree4"].ToString(), ds.Rows[j]["cFree5"].ToString(), ds.Rows[j]["cFree6"].ToString(), ds.Rows[j]["cFree7"].ToString(), ds.Rows[j]["cFree8"].ToString(), ds.Rows[j]["cFree9"].ToString(), ds.Rows[j]["cFree10"].ToString(), key08);
  297. //DBHelper.UpdateCurrentStock(cmd, ds.Rows[j]["cInvCode"].ToString(), cIWhCode, "", Convert.ToDecimal(ds.Rows[j]["iAVQuantity"].ToString()), key08);
  298. string inum = dsh.Rows[j]["iAVNum"].ToString();
  299. if (inum == "")
  300. {
  301. inum = "0";
  302. }
  303. DBHelper.UpdateCurrentStockCCGC(cmd, dsh.Rows[j]["cInvCode"].ToString(), cIWhCode, dsh.Rows[j]["cAVBatch"].ToString(),
  304. Convert.ToDecimal(dsh.Rows[j]["iAVQuantity"].ToString()), Convert.ToDecimal(inum), dsh.Rows[j]["cFree1"].ToString(),
  305. dsh.Rows[j]["cFree2"].ToString(), dsh.Rows[j]["cFree3"].ToString(), dsh.Rows[j]["cFree4"].ToString(), dsh.Rows[j]["cFree5"].ToString(), dsh.Rows[j]["cFree6"].ToString(), dsh.Rows[j]["cFree7"].ToString(), dsh.Rows[j]["cFree8"].ToString(), dsh.Rows[j]["cFree9"].ToString(), dsh.Rows[j]["cFree10"].ToString(),
  306. "", key09, "", "", "", "", 0, 0, 0, 0, 0, 0, 0, 0, iFatherId, iChildId);
  307. }
  308. #endregion
  309. iChildId--;
  310. }
  311. }
  312. }
  313. cmd.Transaction.Commit();
  314. }
  315. catch (Exception ex)
  316. {
  317. if (cmd.Transaction != null)
  318. cmd.Transaction.Rollback();
  319. log.Error(ex.Message);
  320. throw new Exception(ex.Message);
  321. }
  322. finally
  323. {
  324. if (conn.State == ConnectionState.Open)
  325. {
  326. conn.Close();
  327. }
  328. conn.Dispose();
  329. }
  330. }
  331. ResultFlag = true;
  332. return ResultFlag;
  333. }
  334. /// <summary>
  335. /// 记录日志
  336. /// </summary>
  337. /// <param name="Bills"></param>
  338. private void LogInfo(List<ICSDisassemblyDoc> Bills)
  339. {
  340. string HeadList = string.Empty;
  341. string BodyList = string.Empty;
  342. foreach (ICSDisassemblyDoc head in Bills)
  343. {
  344. HeadList += "\r\n 表头主键ID:" + head.ID + ",用户:" + head.User + ",站点:" + head.WorkPoint + "";
  345. }
  346. log.Info(HeadList);
  347. log.Info(BodyList);
  348. }
  349. }
  350. }