From fd920e21a37b6481ffe580525e43d728897101ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=91=E6=B8=A4=E6=97=AD=5BIrelia=5D?= <366601522@qq.com> Date: Mon, 24 Apr 2023 22:34:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=BA=93=E4=BD=8D=E5=AF=BC?= =?UTF-8?q?=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Locations/LocationAutoMapperProfile.cs | 32 +++++++++---------- .../SfsCrudWithDetailsAppServiceBase.cs | 7 ++-- 2 files changed, 21 insertions(+), 18 deletions(-) diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Locations/LocationAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Locations/LocationAutoMapperProfile.cs index 5bbeca507..492e50342 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Locations/LocationAutoMapperProfile.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Locations/LocationAutoMapperProfile.cs @@ -17,22 +17,22 @@ public partial class BasedataApplicationAutoMapperProfile : Profile .Ignore(x => x.TenantId) .Ignore(x => x.ExtraProperties) .Ignore(x => x.ConcurrencyStamp) - .Ignore(x => x.EnableMixItem) - .Ignore(x => x.EnableMixLot) - .Ignore(x => x.EnableMixStatus) - .Ignore(x => x.EnableNegative) - .Ignore(x => x.EnableKeepZero) - .Ignore(x => x.EnableOpportunityCount) - .Ignore(x => x.EnablePick) - .Ignore(x => x.EnableOverPick) - .Ignore(x => x.EnableWholeStore) - .Ignore(x => x.EnableBreakStore) - .Ignore(x => x.EnableShip) - .Ignore(x => x.EnableReceive) - .Ignore(x => x.EnableReturnToSupplier) - .Ignore(x => x.EnableReturnFromCustomer) - .Ignore(x => x.EnableSplitPallet) - .Ignore(x => x.EnableSplitBox) + //.Ignore(x => x.EnableMixItem) + //.Ignore(x => x.EnableMixLot) + //.Ignore(x => x.EnableMixStatus) + //.Ignore(x => x.EnableNegative) + //.Ignore(x => x.EnableKeepZero) + //.Ignore(x => x.EnableOpportunityCount) + //.Ignore(x => x.EnablePick) + //.Ignore(x => x.EnableOverPick) + //.Ignore(x => x.EnableWholeStore) + //.Ignore(x => x.EnableBreakStore) + //.Ignore(x => x.EnableShip) + //.Ignore(x => x.EnableReceive) + //.Ignore(x => x.EnableReturnToSupplier) + //.Ignore(x => x.EnableReturnFromCustomer) + //.Ignore(x => x.EnableSplitPallet) + //.Ignore(x => x.EnableSplitBox) ; diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs index fd6654cd6..64a9ac7db 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs @@ -772,8 +772,11 @@ public abstract class SfsCrudWithDetailsAppServiceBase p.Name == "Worker"); - first.SetValue(first, CurrentUser.GetUserName()); + if (entity.GetProps().Any(p => p.Name == "Worker")) + { + var first = entity.GetProps().First(p => p.Name == "Worker"); + first.SetValue(first, CurrentUser.GetUserName()); + } } var hasEntity = entity != null;