Browse Source

三方库TYRP接口更新

dev_DY_CC
周红军 12 months ago
parent
commit
97707171e6
  1. 1
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ThirdLocationNotes/DTOs/ThirdLocationNoteDTO.cs
  2. 1
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ThirdLocationNotes/Inputs/ThirdLocationNoteEditInput.cs
  3. 1
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ThirdLocationNotes/Inputs/ThirdLocationNoteImportInput.cs
  4. 1
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ThirdLocationNotes/ThirdLocationNote.cs
  5. 2
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ThirdLocationNotes/ThirdLocationNoteDbContextModelCreatingExtensions.cs
  6. 6
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/ThirdLocationJobAutoMapperProfile.cs
  7. 14
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Notes/ThirdLocationNoteAutoMapperProfile.cs
  8. 2
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/DataExchanges/ThirdLocationNoteEventHandler.cs

1
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ThirdLocationNotes/DTOs/ThirdLocationNoteDTO.cs

@ -12,6 +12,7 @@ public class ThirdLocationNoteDTO : SfsStoreDTOBase<ThirdLocationNoteDetailDTO>,
/// </summary>
[Display(Name = "任务ID")]
public string JobNumber { get; set; }
/// <summary>
/// 车间

1
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ThirdLocationNotes/Inputs/ThirdLocationNoteEditInput.cs

@ -27,6 +27,7 @@ public class ThirdLocationNoteEditInput : SfsStoreCreateOrUpdateInputBase
[Display(Name = "任务ID")]
[Required(ErrorMessage = "{0}是必填项")]
public string JobNumber { get; set; }
/// <summary>
/// 车间

1
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ThirdLocationNotes/Inputs/ThirdLocationNoteImportInput.cs

@ -9,6 +9,7 @@ public class ThirdLocationNoteImportInput : SfsStoreImportInputBase, IHasJobNumb
/// </summary>
[Display(Name = "任务ID")]
public string JobNumber { get; set; }
/// <summary>
/// 车间

1
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ThirdLocationNotes/ThirdLocationNote.cs

@ -16,6 +16,7 @@ public class ThirdLocationNote : SfsStoreAggregateRootBase<ThirdLocationNoteDeta
/// </summary>
[IgnoreUpdate]
public string JobNumber { get; set; }
/// <summary>
/// 车间

2
be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ThirdLocationNotes/ThirdLocationNoteDbContextModelCreatingExtensions.cs

@ -21,7 +21,7 @@ public static class ThirdLocationNoteDbContextModelCreatingExtensions
//Properties
b.Property(q => q.RequestNumber).HasMaxLength(SfsPropertyConst.CodeLength);
b.Property(q => q.RequestType).HasMaxLength(SfsPropertyConst.CodeLength);
b.Property(q => q.Workshop).HasMaxLength(SfsPropertyConst.NameLength);
b.Property(q => q.Workshop).HasMaxLength(SfsPropertyConst.NameLength);
b.Property(q => q.Remark).HasMaxLength(SfsPropertyConst.RemarkLength);
//Relations

6
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/ThirdLocationJobAutoMapperProfile.cs

@ -16,10 +16,10 @@ public partial class StoreEventAutoMapperProfile : Profile
CreateMap<ThirdLocationJob, ThirdLocationNote>()
.ForMember(x => x.JobNumber, y => y.MapFrom(d => d.Number))
.ForMember(x => x.RequestNumber, y => y.MapFrom(d => d.RequestNumber))
.ForMember(x => x.ActiveDate, y => y.MapFrom(d => DateTime.Now))
.ForMember(x => x.ActiveDate, y => y.MapFrom(d => DateTime.Now))
.ForMember(x => x.Worker, y => y.MapFrom(d => d.CompleteUserName))
.Ignore(x => x.Confirmed)
.Ignore(x => x.Number)
.Ignore(x => x.Number)
.Ignore(x => x.ConfirmTime);
CreateMap<ThirdLocationJobDetail, ThirdLocationNoteDetail>()
@ -64,7 +64,7 @@ public partial class StoreEventAutoMapperProfile : Profile
CreateMap<ThirdLocationJob, ThirdLocationNoteEditInput>()
.ForMember(x => x.RequestNumber, y => y.MapFrom(d => d.RequestNumber))
.Ignore(x => x.Confirmed)
.Ignore(x => x.JobNumber)
.Ignore(x => x.JobNumber)
.Ignore(x => x.ActiveDate)
;
CreateMap<ThirdLocationJobDetail, ThirdLocationNoteDetailInput>()

14
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Notes/ThirdLocationNoteAutoMapperProfile.cs

@ -1,6 +1,7 @@
using AutoMapper;
using Volo.Abp.AutoMapper;
using Win_in.Sfs.Wms.Inventory.Application.Contracts;
using Win_in.Sfs.Wms.Store.Application.Contracts;
using Win_in.Sfs.Wms.Store.Domain;
namespace Win_in.Sfs.Wms.Store.Event;
@ -17,6 +18,19 @@ public partial class StoreEventAutoMapperProfile : Profile
.Ignore(x => x.ExtraProperties)
.Ignore(x => x.TransSubType)
;
CreateMap<ThirdLocationNote, TransferNoteDTO>()
.ForMember(dest => dest.Type, opts => opts.MapFrom(src => src.RequestType))
.Ignore(x => x.ExtraProperties)
.Ignore(x => x.CallServerName)
.Ignore(x => x.CallBusinessType)
.Ignore(x => x.CallRequestNumber)
.Ignore(x => x.CallJobNumber)
;
CreateMap<ThirdLocationNoteDetail, TransferNoteDetailDTO>()
.Ignore(x => x.Reason)
;
}
}

2
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/DataExchanges/ThirdLocationNoteEventHandler.cs

@ -40,7 +40,7 @@ namespace Win_in.Sfs.Wms.Store.Event.DataExchanges
protected override async Task AddExchangeDataAsync(List<ThirdLocationNote> entities)
{
var dtos = ObjectMapper.Map<List<ThirdLocationNote>, List<ThirdLocationNoteDTO>>(entities);
var dtos = ObjectMapper.Map<List<ThirdLocationNote>, List<TransferNoteDTO>>(entities);
foreach (var detail in dtos.SelectMany(dto => dto.Details))
{
await detail.TrySetLocationAsync(LocationAclService).ConfigureAwait(false);

Loading…
Cancel
Save