From e7df5d1ece7ecabaa7a3943f24a6621649fdc455 Mon Sep 17 00:00:00 2001 From: duheng <2784771470@qq.com> Date: 星期一, 13 一月 2025 16:08:11 +0800 Subject: [PATCH] 增加批量添加,修改阀门界面 --- BLL/HStation.BLL.Assets.Core/03-localclient/17-flowmeter/02-main/AssetsFlowmeterMain.cs | 32 ++++++++++++++++++++------------ 1 files changed, 20 insertions(+), 12 deletions(-) diff --git a/BLL/HStation.BLL.Assets.Core/03-localclient/17-flowmeter/02-main/AssetsFlowmeterMain.cs b/BLL/HStation.BLL.Assets.Core/03-localclient/17-flowmeter/02-main/AssetsFlowmeterMain.cs index 17ef23d..91a29bf 100644 --- a/BLL/HStation.BLL.Assets.Core/03-localclient/17-flowmeter/02-main/AssetsFlowmeterMain.cs +++ b/BLL/HStation.BLL.Assets.Core/03-localclient/17-flowmeter/02-main/AssetsFlowmeterMain.cs @@ -1,7 +1,9 @@ -锘縩amespace HStation.CAL.LocalClient +锘縰sing Mapster; + +namespace HStation.CAL.LocalClient { /// <summary> - /// + /// /// </summary> public class AssetsFlowmeterMain : IAssetsFlowmeterMain { @@ -71,7 +73,9 @@ }); } - #endregion + #endregion Query + + #region Insert @@ -108,7 +112,13 @@ { return await Task.Factory.StartNew(() => { - return false; + var list = inputList.Select(x => x.Adapt<AddAssetsFlowmeterMainInput, Model.AssetsFlowmeterMain>()).ToList(); + list.ForEach(x => + { + x.SortCode = _service.GetMaxSortCode(x.SeriesID) + 1 + list.IndexOf(x); + }); + var bol = _service.Inserts(list); + return bol; }); } @@ -123,7 +133,7 @@ }); } - #endregion + #endregion Insert #region Update @@ -243,13 +253,12 @@ }); } - - #endregion + #endregion Update #region Exist /// <summary> - /// + /// /// </summary> public async Task<bool> IsExistTagName(string TagName) { @@ -261,7 +270,7 @@ } /// <summary> - /// + /// /// </summary> public async Task<bool> IsExistTagNameExceptID(string TagName, long ExceptID) { @@ -272,7 +281,7 @@ }); } - #endregion + #endregion Exist #region Delete @@ -315,8 +324,7 @@ }); } - - #endregion + #endregion Delete } } \ No newline at end of file -- Gitblit v1.9.3