| | |
| | | using System.Data; |
| | | using System.Buffers; |
| | | using System.Data; |
| | | using MES.Service.DB; |
| | | using MES.Service.Dto.service; |
| | | using MES.Service.Modes; |
| | |
| | | } |
| | | |
| | | //获取所有数据分页 |
| | | public List<SJPageResult> getPage(SJPageResult queryObj) |
| | | public (List<SJPageResult> items, int TotalCount) getPage(SJPageResult queryObj) |
| | | { |
| | | var db = SqlSugarHelper.GetInstance(); |
| | | |
| | | var totalCount = 0; |
| | | |
| | | string[]? lineNo = null; |
| | | |
| | |
| | | !"未完成".Equals(queryObj.Result), |
| | | a => a.Result != "未完成") |
| | | .WhereIF(queryObj.Comments != null, a => a.Comments == queryObj.Comments) |
| | | .WhereIF(StringUtil.IsNotNullOrEmpty(queryObj.SearchValue),a=>a.BillNo.Contains(queryObj.SearchValue) |
| | | || a.ItemNo.Contains(queryObj.SearchValue)) |
| | | .OrderBy(a => a.BillNo, OrderByType.Desc) |
| | | .ToPageList(queryObj.PageIndex, queryObj.Limit); |
| | | .ToPageList(queryObj.PageIndex, queryObj.Limit, ref totalCount); |
| | | |
| | | return data; |
| | | return (data, totalCount); |
| | | } |
| | | |
| | | |
| | |
| | | item.Items = getQSItems(qsItemIpiReq.Id, null); |
| | | var sjPageResult = new SJPageResult |
| | | { Id = item.From.Id, Limit = 1, PageIndex = 1 }; |
| | | item.Result = getPage(sjPageResult)[0]; |
| | | item.Result = getPage(sjPageResult).items[0]; |
| | | |
| | | return item; |
| | | } |