| | |
| | | !"未完成".Equals(queryObj.result), |
| | | (a, b, c, d, e) => a.FcheckResu != null && a.Fsubmit == 1) |
| | | .WhereIF(id > 0, (a, b, c, d, e) => a.Id == id) |
| | | .WhereIF(StringUtil.IsNotNullOrEmpty(queryObj.createUser) && queryObj.SearchIndex != null, |
| | | (a, b, c, d, e) => c.Fname.Contains(queryObj.createUser)) |
| | | .WhereIF(StringUtil.IsNotNullOrEmpty(queryObj.ItemNo), |
| | | (a, b, c, d, e) => b.ItemNo.Contains(queryObj.ItemNo)) |
| | | .WhereIF(StringUtil.IsNotNullOrEmpty(queryObj.ItemName), |
| | | (a, b, c, d, e) => b.ItemName.Contains(queryObj.ItemName)) |
| | | .WhereIF(StringUtil.IsNotNullOrEmpty(queryObj.ReleaseNo), |
| | | (a, b, c, d, e) => a.ReleaseNo.Contains(queryObj.ReleaseNo)) |
| | | .OrderByDescending((a, b, c, d, e) => a.Id) |
| | | .Select((a, b, c, d, e) => new MesOqcItemsDetect02() |
| | | { |
| | |
| | | } |
| | | } |
| | | |
| | | public bool OqcQagetTable(LLJDto dto) |
| | | { |
| | | try |
| | | { |
| | | // 1. 根据releaseNo查询MesOqcItemsDetect02实体 |
| | | var detect02Entity = Db.Queryable<MesOqcItemsDetect02>() |
| | | .Where(s => s.ReleaseNo == dto.releaseNo) |
| | | .First(); |
| | | // 2. 校验实体是否存在 |
| | | if (detect02Entity == null) |
| | | { |
| | | throw new Exception($"未找到ReleaseNo为{dto.releaseNo}的检验单数据"); |
| | | } |
| | | // 3. 调用Regenerate方法(复用现有逻辑) |
| | | Regenerate(detect02Entity); |
| | | return true; |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | throw new Exception(ex.Message); |
| | | } |
| | | } |
| | | |
| | | |
| | | public int saveRemarksGid(LLJDto dto) |
| | | { |
| | | return SqlSugarHelper.UseTransactionWithOracle(db => |