From 82dac540156cb29e58c86f7d7d840e3c7e548c15 Mon Sep 17 00:00:00 2001 From: xwt <2740516069@qq.com> Date: 星期四, 14 八月 2025 19:55:41 +0800 Subject: [PATCH] 来料检,入库检,首检巡检。 --- StandardInterface/MES.Service/service/QC/LljService.cs | 43 +++++++++++++++++++++++++++++++++++++------ 1 files changed, 37 insertions(+), 6 deletions(-) diff --git a/StandardInterface/MES.Service/service/QC/LljService.cs b/StandardInterface/MES.Service/service/QC/LljService.cs index 9ac71ce..78ba1fb 100644 --- a/StandardInterface/MES.Service/service/QC/LljService.cs +++ b/StandardInterface/MES.Service/service/QC/LljService.cs @@ -68,8 +68,20 @@ // .OrderByDescending((a, b, .OrderBy("CASE WHEN a.EMERGENCY = 1 THEN 0 ELSE 1 END, CASE WHEN a.STATUS = '宸叉彁浜�' THEN 0 ELSE 1 END, a.IQC_DATE desc, a.ID asc") - .ToPageList(queryObj.PageIndex, queryObj.Limit, ref totalCount); + .ToPageList(queryObj.PageIndex, queryObj.Limit, ref totalCount); + // 涓烘瘡涓楠屽崟娣诲姞妫�楠岄」鐩暟閲忎俊鎭� + foreach (var item in pageList) + { + // 鑾峰彇璇ユ楠屽崟鐨勬楠岄」鐩暟閲� + var itemCount = db.Queryable<MesQaItemsDetectDetail5>() + .Where(x => x.ReleaseNo == item.ReleaseNo) + .Count(); + + // 璁剧疆妫�楠岄」鐩暟閲� + item.InspectionItemCount = itemCount; + } + var emergencyValues = pageList.Select(item => item.EMERGENCY).ToList(); return (pageList, totalCount); } @@ -868,15 +880,34 @@ { return db.Updateable<MesQaItemsDetect01>() .SetColumns(it => it.FngDesc == dto.Remarks) - .SetColumns(it => it.PHSY == dto.PHSY) - .SetColumns(it => it.BLYY == dto.BLYY) - .SetColumns(it => it.SSCJ == dto.SSCJ) - .SetColumns(it => it.PSZT == dto.PSZT) .Where(it => it.ReleaseNo == dto.releaseNo) .ExecuteCommand(); }); } - + //涓昏〃淇敼鐮村潖瀹為獙 + public int savePhsyGid(LLJDto dto) + { + return SqlSugarHelper.UseTransactionWithOracle(db => + { + return db.Updateable<MesQaItemsDetect01>() + .SetColumns(it => it.PHSY == dto.PHSY) + .Where(it => it.ReleaseNo == dto.releaseNo) + .ExecuteCommand(); + }); + } + // 涓昏〃淇敼涓嬫媺妗嗗瓧娈� + public int saveDropdownFields(LLJDto dto) + { + return SqlSugarHelper.UseTransactionWithOracle(db => + { + return db.Updateable<MesQaItemsDetect01>() + .SetColumns(it => it.BLYY == dto.BLYY) + .SetColumns(it => it.PSZT == dto.PSZT) + .SetColumns(it => it.SSCJ == dto.SSCJ) + .Where(it => it.ReleaseNo == dto.releaseNo) + .ExecuteCommand(); + }); + } //瀛愯〃淇敼澶囨敞瀛楁 public int saveRemarksPid(LLJDto dto) { -- Gitblit v1.9.3