1.禁用库位时钉钉消息通知、更新缓存中对应模组的启用/禁用状态
2.修复异常 模组管理中无法通过模组编码进行搜索
This commit is contained in:
@ -39,6 +39,7 @@ namespace WCS.BLL.HardWare
|
||||
|
||||
public int LightId { get; set; }
|
||||
public List<int> ModuleIds { get; set; }
|
||||
public List<SmartShelfModule> Modules { get; set; }
|
||||
public string ClientIp { get; set; }
|
||||
/// <summary>
|
||||
/// 货架当前模式
|
||||
|
@ -26,6 +26,7 @@ namespace WCS.BLL.HardWare
|
||||
public List<string> ExceptionMessages { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public bool IsWarning { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public string WebSocketIpAddress { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public List<SmartShelfModule> Modules { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
|
||||
public bool ConfirmStocktakingSingle(int BoardId, int LightNumber)
|
||||
{
|
||||
|
@ -1370,6 +1370,7 @@ namespace WCS.BLL.HardWare
|
||||
MatSpec = inventoryDetail.MatSpec,
|
||||
MatCustomer = inventoryDetail.MatCustomer,
|
||||
MatSupplier = inventoryDetail.MatSupplier,
|
||||
OrderNumber = orderMatDetails.OrderNumber,
|
||||
|
||||
Direction = DirectionEnum.出库,
|
||||
};
|
||||
|
@ -88,7 +88,6 @@ namespace WCS.BLL.Manager
|
||||
//货架是否还存在报警信息
|
||||
shelfIsWarning = Warnings.Where(t => t.ShelfId == warning.ShelfId)
|
||||
.Any();
|
||||
|
||||
//对应货架如果不存在报警信息了 指示灯回到对应的状态
|
||||
if (!shelfIsWarning)
|
||||
{
|
||||
|
@ -955,6 +955,7 @@ namespace WCS.BLL.Services.Service
|
||||
MatSpec = inventoryDetail.MatSpec,
|
||||
MatCustomer = inventoryDetail.MatCustomer,
|
||||
MatSupplier = inventoryDetail.MatSupplier,
|
||||
OrderNumber = stockTakingOrderMatDetail.StocktakingOrderNumber,
|
||||
|
||||
Direction = DirectionEnum.盘点,
|
||||
OperateUser = request.UserName
|
||||
|
@ -7,6 +7,7 @@ using System.Threading.Tasks;
|
||||
using TouchSocket.Core;
|
||||
using WCS.BLL.Config;
|
||||
using WCS.BLL.DbModels;
|
||||
using WCS.BLL.HardWare;
|
||||
using WCS.BLL.Manager;
|
||||
using WCS.BLL.Services.IService;
|
||||
using WCS.DAL;
|
||||
@ -359,6 +360,27 @@ namespace WCS.BLL.Services.Service
|
||||
}
|
||||
DbHelp.db.Updateable(moduleInfo).ExecuteCommand();
|
||||
DbHelp.db.CommitTran();
|
||||
|
||||
#region 更新缓存中的禁用/启动状态
|
||||
try
|
||||
{
|
||||
var shelf = ShelfManager.Shelves.Where(t => t.ShelfId == moduleInfo.ShelfId)
|
||||
.FirstOrDefault();
|
||||
if (shelf != null)
|
||||
{
|
||||
|
||||
var moduleInPc = shelf.Modules.Where(t => t.ModuleId == moduleInfo.Id)
|
||||
.First();
|
||||
if (moduleInPc != null)
|
||||
moduleInPc.IsEnable = request.DisableOrEnable == DisableOrEnableEnum.Enable;
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
return new ResponseCommon()
|
||||
{
|
||||
Code = 200,
|
||||
@ -441,6 +463,14 @@ namespace WCS.BLL.Services.Service
|
||||
//禁用需要删除当前库存数据
|
||||
if (request.DisableOrEnable == DisableOrEnableEnum.Disable)
|
||||
{
|
||||
|
||||
//盟讯公司发送钉钉消息
|
||||
if (LocalFile.Config.IsMx)
|
||||
{
|
||||
var DingDing = string.Empty;
|
||||
MXBackgroundThread.SendDingDingMsg($"【智能货架】库位{storeInfo.StoreCode}被屏蔽", new List<string> { "104379", "103595" }, ref DingDing);
|
||||
}
|
||||
|
||||
//库位
|
||||
storeInfo.CurrentMatSn = "禁用";
|
||||
//库存数据处理
|
||||
|
Reference in New Issue
Block a user