Browse Source

修改 提示

Agv分支2024-11-19
郑勃旭 4 months ago
parent
commit
a0131a68fd
  1. 22
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/DeliverRequests/DTOs/DeliverRequestByContainerDTO.cs
  2. 6
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/OperationPacking/IntegrationPackingNotes/IntegrationPackingNoteAppService.cs
  3. 2
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/OperationPacking/SeparationPackingNotes/SeparationPackingNoteAppService.cs
  4. 30
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/DeliverRequests/DeliverRequestAppService.cs

22
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/DeliverRequests/DTOs/DeliverRequestByContainerDTO.cs

@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using Volo.Abp.Application.Dtos;
using Volo.Abp.Data;
namespace Win_in.Sfs.Wms.Store.Application.Contracts;
public class DeliverRequestByContainerDTO : AuditedEntityDto
{
/// <summary>
/// Mes器具号
/// </summary>
[Display(Name = "Mes器具号")]
public string MesDeliveryContainer { get; set; }
public DateTime MaxDateTime { get; set; }
public DateTime MinDateTime { get; set; }
public List<DeliverRequestDetailDTO> RequestDetailDtos { get; set; }
}

6
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/OperationPacking/IntegrationPackingNotes/IntegrationPackingNoteAppService.cs

@ -80,7 +80,7 @@ public class IntegrationPackingNoteAppService :
if (outDtos.Any()) if (outDtos.Any())
{ {
throw new UserFriendlyException($"此物料已经被【任务编号:{outDtos.First().JobNumber}】占用"); throw new UserFriendlyException($"此库存{input.PackingCode}已经被【任务编号:{outDtos.First().JobNumber}】占用");
} }
var entity = input.ToObject<IntegrationPackingNote>(); var entity = input.ToObject<IntegrationPackingNote>();
@ -99,7 +99,7 @@ public class IntegrationPackingNoteAppService :
var balanceDetailDto=await _balanceAppService.GetByPackingCodeAsync(detailInput.PackingCode).ConfigureAwait(false); var balanceDetailDto=await _balanceAppService.GetByPackingCodeAsync(detailInput.PackingCode).ConfigureAwait(false);
if (balanceDetailDto.LocationCode != balanceMainDto.LocationCode) if (balanceDetailDto.LocationCode != balanceMainDto.LocationCode)
{ {
throw new UserFriendlyException($"箱码{detailInput.PackingCode}的库位与合并箱码{balanceMainDto.LocationCode}的库位不一致"); throw new UserFriendlyException($"箱码【{detailInput.PackingCode}】的库存需要再{balanceMainDto.LocationCode}库位上才可合并");
} }
//库存移动 //库存移动
@ -112,7 +112,7 @@ public class IntegrationPackingNoteAppService :
if (balanceDetailDtos.Sum(p=>p.Qty) > input.StdPackQty) if (balanceDetailDtos.Sum(p=>p.Qty) > input.StdPackQty)
{ {
throw new UserFriendlyException($"合箱数量超过标包"); throw new UserFriendlyException($"合箱数量超过标包数量");
} }
await _transferLogAppService.AddManyAsync(transferLogEditInputs).ConfigureAwait(false); await _transferLogAppService.AddManyAsync(transferLogEditInputs).ConfigureAwait(false);

2
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/OperationPacking/SeparationPackingNotes/SeparationPackingNoteAppService.cs

@ -66,7 +66,7 @@ public class SeparationPackingNoteAppService :
var outDtos = await _expectOutAppService.GetListByPackingCodeAsync(input.PackingCode).ConfigureAwait(false); var outDtos = await _expectOutAppService.GetListByPackingCodeAsync(input.PackingCode).ConfigureAwait(false);
if (outDtos.Any()) if (outDtos.Any())
{ {
throw new UserFriendlyException($"此物料已经被【任务编号:{outDtos.First().JobNumber}】占用"); throw new UserFriendlyException($"此库存{input.PackingCode}已经被【任务编号:{outDtos.First().JobNumber}】占用");
} }
if (input.Details.Sum(p => p.Qty) > input.Qty) if (input.Details.Sum(p => p.Qty) > input.Qty)

30
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/DeliverRequests/DeliverRequestAppService.cs

@ -522,9 +522,6 @@ public class DeliverRequestAppService :
await SetRequestAutoPropertiesAsync(entity).ConfigureAwait(false); await SetRequestAutoPropertiesAsync(entity).ConfigureAwait(false);
} }
private static void CheckTransactionType(TransactionTypeDTO transactionType, ItemBasicDTO item) private static void CheckTransactionType(TransactionTypeDTO transactionType, ItemBasicDTO item)
{ {
if (transactionType == null) if (transactionType == null)
@ -546,5 +543,32 @@ public class DeliverRequestAppService :
} }
} }
private async Task<List<DeliverRequestDetailDTO>> GetDetailListByFisAsync()
{
var list=await _repository.GetListAsync(p => p.DeliverRequestType == EnumDeliverRequestType.FIS).ConfigureAwait(false);
var details=new List<DeliverRequestDetail>();
foreach (var deliverRequest in list)
{
foreach (var deliverRequestDetail in deliverRequest.Details)
{
details.Add(deliverRequestDetail);
}
}
var byContainerDto=new List<DeliverRequestByContainerDTO>();
var groupBy=details.GroupBy(p => p.MesDeliveryContainer);
foreach (var key in groupBy)
{
var dto= new DeliverRequestByContainerDTO();
//dto.RequestDetailDtos
}
return null;
}
#endregion #endregion
} }

Loading…
Cancel
Save