1.解决TCP添加失败问题

2.所有搜索记录倒叙排
3.优化:出入记录、库存记录增加货架类型分类查询
4.权限
5.优化下载app二维码
This commit is contained in:
hehaibing-1996
2024-07-02 09:05:21 +08:00
parent c9e25a1f85
commit adb0367a83
28 changed files with 785 additions and 101 deletions

View File

@ -35,7 +35,7 @@ namespace WCS.BLL.Services.Service
.WhereIF(!string.IsNullOrEmpty(request.MatSupplier), (id, si) => id.MatSpec.Contains(request.MatSupplier))
.WhereIF(!string.IsNullOrEmpty(request.MatCustomer), (id, si) => id.MatSpec.Contains(request.MatCustomer))
.WhereIF(request.Direction != null, (id, si) => id.Direction == request.Direction)
.WhereIF(request.ShelfTypeId != 0, (id, si) => si.ShelfTypeId == request.ShelfTypeId)
.WhereIF(request.StoreId != 0, (id, si) => id.StoreId == request.StoreId)
.WhereIF(!string.IsNullOrEmpty(request.StoreCode), (id, si) => id.StoreCode.Contains(request.StoreCode))
@ -43,6 +43,7 @@ namespace WCS.BLL.Services.Service
var totalCount = await recordsQueryable.CountAsync();
var records = await recordsQueryable
.OrderByDescending((id, si) => id.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.Select<InOutRecord>()
.ToListAsync();
@ -89,12 +90,11 @@ namespace WCS.BLL.Services.Service
.WhereIF(!string.IsNullOrEmpty(request.MatSpec), (id, si) => id.MatSpec.Contains(request.MatSpec))
.WhereIF(!string.IsNullOrEmpty(request.MatSupplier), (id, si) => id.MatSpec.Contains(request.MatSupplier))
.WhereIF(!string.IsNullOrEmpty(request.MatCustomer), (id, si) => id.MatSpec.Contains(request.MatCustomer))
.WhereIF(request.StoreId != 0, (id, si) => id.StoreId == request.StoreId)
.WhereIF(!string.IsNullOrEmpty(request.StoreCode), (id, si) => id.StoreCode.Contains(request.StoreCode))
;
var records = await recordsQueryable
.OrderByDescending((id, si) => id.Id)
.Select<InOutRecord>()
.ToListAsync();
//生成序号

View File

@ -40,6 +40,7 @@ namespace WCS.BLL.Services.Service
}
var totalCount = await recordsQueryable.CountAsync();
var records = await recordsQueryable
.OrderByDescending(t => t.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.ToListAsync();
//生成序号
@ -94,7 +95,7 @@ namespace WCS.BLL.Services.Service
recordsQueryable = recordsQueryable.WhereIF(request.StartTime != null, t => request.StartTime <= t.ResponseTime);
recordsQueryable = recordsQueryable.WhereIF(request.StartTime != null, t => request.EndTime >= t.ResponseTime);
}
var records = await recordsQueryable.ToListAsync();
var records = await recordsQueryable.OrderByDescending(t => t.Id).ToListAsync();
//生成序号
var index = 1;
records.ForEach(r =>

View File

@ -40,6 +40,7 @@ namespace WCS.BLL.Services.Service
var totalCount = await recordsQueryable.CountAsync();
var records = await recordsQueryable
.OrderByDescending(t => t.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.ToListAsync();
//生成序号
@ -81,7 +82,7 @@ namespace WCS.BLL.Services.Service
.WhereIF(!string.IsNullOrEmpty(request.MatName), t => t.MatName.Contains(request.MatName))
.WhereIF(!string.IsNullOrEmpty(request.MatSpec), t => t.MatSpec.Contains(request.MatSpec))
.WhereIF(request.IsEnable != null, t => t.IsEnable == request.IsEnable.GetValueOrDefault());
var records = await recordsQueryable.ToListAsync();
var records = await recordsQueryable.OrderByDescending(t => t.Id).ToListAsync();
//生成序号
var index = 1;
records.ForEach(r =>
@ -387,6 +388,7 @@ namespace WCS.BLL.Services.Service
matCodeList = await DbHelp.db.Queryable<MatBaseInfo>()
.Select(t => t.MatCode)
.Distinct()
.OrderBy(t => t)
.ToListAsync();
}
else
@ -394,6 +396,7 @@ namespace WCS.BLL.Services.Service
matCodeList = await DbHelp.db.Queryable<InventoryDetail>()
.Select(t => t.MatCode)
.Distinct()
.OrderBy(t => t)
.ToListAsync();
}
return new ResponseCommon<List<string>>()
@ -426,7 +429,7 @@ namespace WCS.BLL.Services.Service
.WhereIF(request.IsPrinted != null, t => t.IsPrinted == request.IsPrinted)
.WhereIF(!string.IsNullOrEmpty(request.MatSN), t => t.MatSn.Contains(request.MatSN));
var totalCount = await recordsQueryable.CountAsync();
var records = await recordsQueryable
var records = await recordsQueryable.OrderByDescending(t => t.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.ToListAsync();
//生成序号

View File

@ -33,7 +33,7 @@ namespace WCS.BLL.Services.Service
.WhereIF(!string.IsNullOrEmpty(request.MatSpec), (id, si) => id.MatSpec.Contains(request.MatSpec))
.WhereIF(!string.IsNullOrEmpty(request.MatSupplier), (id, si) => id.MatSpec.Contains(request.MatSupplier))
.WhereIF(!string.IsNullOrEmpty(request.MatCustomer), (id, si) => id.MatSpec.Contains(request.MatCustomer))
.WhereIF(request.ShelfTypeId != 0, (id, si) => si.ShelfTypeId == request.ShelfTypeId)
.WhereIF(request.StoreId != 0, (id, si) => id.StoreId == request.StoreId)
.WhereIF(!string.IsNullOrEmpty(request.StoreCode), (id, si) => id.StoreCode.Contains(request.StoreCode))
@ -42,6 +42,7 @@ namespace WCS.BLL.Services.Service
var totalCount = await recordsQueryable.CountAsync();
var records = await recordsQueryable
.OrderByDescending((id, si) => id.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.Select<InventoryDetail>()
.ToListAsync();
@ -84,17 +85,18 @@ namespace WCS.BLL.Services.Service
.WhereIF(!string.IsNullOrEmpty(request.MatSN), (id, si) => id.MatSN.Contains(request.MatSN))
.WhereIF(!string.IsNullOrEmpty(request.MatCode), (id, si) => id.MatCode.Contains(request.MatCode))
.WhereIF(!string.IsNullOrEmpty(request.MatName), (id, si) => id.MatName.Contains(request.MatName))
.WhereIF(!string.IsNullOrEmpty(request.MatBatch), (id, si) => id.MatBatch.Contains(request.MatBatch))
.WhereIF(!string.IsNullOrEmpty(request.MatBatch), (id, si) => id.MatBatch.Contains(request.MatBatch))
.WhereIF(!string.IsNullOrEmpty(request.MatSpec), (id, si) => id.MatSpec.Contains(request.MatSpec))
.WhereIF(!string.IsNullOrEmpty(request.MatSupplier), (id, si) => id.MatSpec.Contains(request.MatSupplier))
.WhereIF(!string.IsNullOrEmpty(request.MatCustomer), (id, si) => id.MatSpec.Contains(request.MatCustomer))
.WhereIF(request.ShelfTypeId != 0, (id, si) => si.ShelfTypeId == request.ShelfTypeId)
.WhereIF(request.StoreId != 0, (id, si) => id.StoreId == request.StoreId)
.WhereIF(!string.IsNullOrEmpty(request.StoreCode), (id, si) => id.StoreCode.Contains(request.StoreCode))
.WhereIF(!string.IsNullOrEmpty(request.ShelfCode), (id, si) => si.ShelfCode.Contains(request.ShelfCode))
;
var records = await recordsQueryable
.OrderByDescending((id, si) => id.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.Select<InventoryDetail>()
.ToListAsync();

View File

@ -88,6 +88,8 @@ namespace WCS.BLL.Services.Service
shelf.ShelfCheck();
//Thread.Sleep(8);
Task.Run(() =>
{
var warningModel = new WebSocketMessageModel()
@ -100,11 +102,11 @@ namespace WCS.BLL.Services.Service
ShelfCode = shelf.ShelfCode,
ShelfId = shelf.ShelfId,
ClientIp = shelf.WebSocketIpAddress,
WarningMessage = $"货架【{shelf.ShelfCode}】已完成自检"
WarningMessage = $"货架【{shelf.ShelfCode}】自检命令发送完毕"
};
WarningManager.SendWarning(warningModel);
});
Thread.Sleep(10);
Thread.Sleep(8);
}
});
}

View File

@ -339,6 +339,7 @@ namespace WCS.BLL.Services.Service
var totalCount = await recordsQueryable.CountAsync();
var records = await recordsQueryable
.OrderByDescending(t => t.Id)
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
.Select<StockTakingOrder>()
.ToListAsync();