diff --git a/be/DataExchange/Iac/Win_in.Sfs.Wms.DataExchange.Application.Iac.Mes/Mes/MesProductL7PartsNoteAutoMapperProfile.cs b/be/DataExchange/Iac/Win_in.Sfs.Wms.DataExchange.Application.Iac.Mes/Mes/MesProductL7PartsNoteAutoMapperProfile.cs index 3d08f09ac..ca59169c5 100644 --- a/be/DataExchange/Iac/Win_in.Sfs.Wms.DataExchange.Application.Iac.Mes/Mes/MesProductL7PartsNoteAutoMapperProfile.cs +++ b/be/DataExchange/Iac/Win_in.Sfs.Wms.DataExchange.Application.Iac.Mes/Mes/MesProductL7PartsNoteAutoMapperProfile.cs @@ -11,7 +11,6 @@ public class MesProductL7PartsNoteAutoMapperProfile : Profile public MesProductL7PartsNoteAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ForMember(x => x.CreationTime, y => y.MapFrom(d => d.CreationTime)) .ReverseMap(); diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application/OutgoingFromWms/OutgoingFromWmsAutoMapperProfile.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application/OutgoingFromWms/OutgoingFromWmsAutoMapperProfile.cs index 489ebfa63..fe7819e86 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application/OutgoingFromWms/OutgoingFromWmsAutoMapperProfile.cs +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application/OutgoingFromWms/OutgoingFromWmsAutoMapperProfile.cs @@ -10,7 +10,6 @@ public class OutgoingFromWmsAutoMapperProfile : Profile public OutgoingFromWmsAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ForMember(x => x.CreationTime, y => y.MapFrom(d => d.CreationTime)) .ReverseMap(); diff --git a/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Application/Departments/DepartmentAutoMapperProfile.cs b/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Application/Departments/DepartmentAutoMapperProfile.cs index a0407a3c0..e12fb49a2 100644 --- a/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Application/Departments/DepartmentAutoMapperProfile.cs +++ b/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Application/Departments/DepartmentAutoMapperProfile.cs @@ -10,7 +10,6 @@ public partial class AuthApplicationAutoMapperProfile : Profile private void DepartmentAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() .IgnoreAuditedObjectProperties() diff --git a/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Web/appsettings.json b/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Web/appsettings.json index 8a93db331..7ec7d8dd5 100644 --- a/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Web/appsettings.json +++ b/be/Hosts/Auth.Host/src/Win_in.Sfs.Auth.Web/appsettings.json @@ -1,34 +1,34 @@ { "ConfigServer": "http://localhost:21093", "ConfigServer.Docker": "http://gateway:21093", - "ConnectionStrings": { - "Default": "Server=dev.ccwin-in.com,21195;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;", - "Auth": "Server=dev.ccwin-in.com,21195;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;" - }, - "SwaggerAuthServer": { - "Authority": "http://localhost:59093", - "RequireHttpsMetadata": "false" - }, - "IdentityServer": { - "Clients": { - "Auth_Web": { - "ClientId": "Auth_Web", - "RootUrl": "http://localhost:59093/", - "RequireHttpsMetadata": "false" - }, - "Auth_App": { - "ClientId": "Auth_App", - "ClientSecret": "1q2w3e*", - "RootUrl": "http://localhost:59093", - "RequireHttpsMetadata": "false" - }, - "Auth_Swagger": { - "ClientId": "Auth_Swagger", - "ClientSecret": "1q2w3e*", - "RootUrl": "http://localhost:59093", - "RequireHttpsMetadata": "false" - } - } - } + //"ConnectionStrings": { + // "Default": "Server=dev.ccwin-in.com,21195;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;", + // "Auth": "Server=dev.ccwin-in.com,21195;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;" + //}, + //"SwaggerAuthServer": { + // "Authority": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + //}, + //"IdentityServer": { + // "Clients": { + // "Auth_Web": { + // "ClientId": "Auth_Web", + // "RootUrl": "http://localhost:59093/", + // "RequireHttpsMetadata": "false" + // }, + // "Auth_App": { + // "ClientId": "Auth_App", + // "ClientSecret": "1q2w3e*", + // "RootUrl": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + // }, + // "Auth_Swagger": { + // "ClientId": "Auth_Swagger", + // "ClientSecret": "1q2w3e*", + // "RootUrl": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + // } + // } + //} } diff --git a/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/BasedataHttpApiHostModule.cs b/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/BasedataHttpApiHostModule.cs index 1ed8d1002..3f5af902b 100644 --- a/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/BasedataHttpApiHostModule.cs +++ b/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/BasedataHttpApiHostModule.cs @@ -67,14 +67,19 @@ public class BasedataHttpApiHostModule : ModuleBase { public override void ConfigureServices(ServiceConfigurationContext context) { + //base.ConfigureServices(context); + //ConfigureAuditing(); + //// + //ConfigureBlobStoring(); + //Configure(options => + //{ + // options.Kind = DateTimeKind.Local; + //}); + base.ConfigureServices(context); ConfigureAuditing(); // ConfigureBlobStoring(); - Configure(options => - { - options.Kind = DateTimeKind.Local; - }); } public override void PostConfigureServices(ServiceConfigurationContext context) diff --git a/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/appsettings.json b/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/appsettings.json index fc30b6483..8de8aa776 100644 --- a/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/appsettings.json +++ b/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/appsettings.json @@ -1,34 +1,34 @@ { "ConfigServer": "http://localhost:21093", "ConfigServer.Docker": "http://gateway:21093", - "ConnectionStrings": { - "Default": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;", - "Auth": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;" - }, - "SwaggerAuthServer": { - "Authority": "http://localhost:59093", - "RequireHttpsMetadata": "false" - }, - "IdentityServer": { - "Clients": { - "Auth_Web": { - "ClientId": "Auth_Web", - "RootUrl": "http://localhost:59093/", - "RequireHttpsMetadata": "false" - }, - "Auth_App": { - "ClientId": "Auth_App", - "ClientSecret": "1q2w3e*", - "RootUrl": "http://localhost:59093", - "RequireHttpsMetadata": "false" - }, - "Auth_Swagger": { - "ClientId": "Auth_Swagger", - "ClientSecret": "1q2w3e*", - "RootUrl": "http://localhost:59093", - "RequireHttpsMetadata": "false" - } - } - } + //"ConnectionStrings": { + // "Default": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;", + // "Auth": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;" + //}, + //"SwaggerAuthServer": { + // "Authority": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + //}, + //"IdentityServer": { + // "Clients": { + // "Auth_Web": { + // "ClientId": "Auth_Web", + // "RootUrl": "http://localhost:59093/", + // "RequireHttpsMetadata": "false" + // }, + // "Auth_App": { + // "ClientId": "Auth_App", + // "ClientSecret": "1q2w3e*", + // "RootUrl": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + // }, + // "Auth_Swagger": { + // "ClientId": "Auth_Swagger", + // "ClientSecret": "1q2w3e*", + // "RootUrl": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + // } + // } + //} } diff --git a/be/Hosts/Win_in.Sfs.Wms.Dashboard.Host/Win_in.Sfs.Wms.Dashboard.Host.csproj b/be/Hosts/Win_in.Sfs.Wms.Dashboard.Host/Win_in.Sfs.Wms.Dashboard.Host.csproj index 56115b4ec..f55c19d89 100644 --- a/be/Hosts/Win_in.Sfs.Wms.Dashboard.Host/Win_in.Sfs.Wms.Dashboard.Host.csproj +++ b/be/Hosts/Win_in.Sfs.Wms.Dashboard.Host/Win_in.Sfs.Wms.Dashboard.Host.csproj @@ -48,8 +48,8 @@ - + diff --git a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/appsettings.json b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/appsettings.json index fc30b6483..8de8aa776 100644 --- a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/appsettings.json +++ b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/appsettings.json @@ -1,34 +1,34 @@ { "ConfigServer": "http://localhost:21093", "ConfigServer.Docker": "http://gateway:21093", - "ConnectionStrings": { - "Default": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;", - "Auth": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;" - }, - "SwaggerAuthServer": { - "Authority": "http://localhost:59093", - "RequireHttpsMetadata": "false" - }, - "IdentityServer": { - "Clients": { - "Auth_Web": { - "ClientId": "Auth_Web", - "RootUrl": "http://localhost:59093/", - "RequireHttpsMetadata": "false" - }, - "Auth_App": { - "ClientId": "Auth_App", - "ClientSecret": "1q2w3e*", - "RootUrl": "http://localhost:59093", - "RequireHttpsMetadata": "false" - }, - "Auth_Swagger": { - "ClientId": "Auth_Swagger", - "ClientSecret": "1q2w3e*", - "RootUrl": "http://localhost:59093", - "RequireHttpsMetadata": "false" - } - } - } + //"ConnectionStrings": { + // "Default": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;", + // "Auth": "Server=dev.ccwin-in.com,13319;Database=WmsAuth;uid=ccwin-in;pwd=Microsoft@2022;Packet Size=512;" + //}, + //"SwaggerAuthServer": { + // "Authority": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + //}, + //"IdentityServer": { + // "Clients": { + // "Auth_Web": { + // "ClientId": "Auth_Web", + // "RootUrl": "http://localhost:59093/", + // "RequireHttpsMetadata": "false" + // }, + // "Auth_App": { + // "ClientId": "Auth_App", + // "ClientSecret": "1q2w3e*", + // "RootUrl": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + // }, + // "Auth_Swagger": { + // "ClientId": "Auth_Swagger", + // "ClientSecret": "1q2w3e*", + // "RootUrl": "http://localhost:59093", + // "RequireHttpsMetadata": "false" + // } + // } + //} } diff --git a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/scripts/db.Microsoft.EntityFrameworkCore.SqlServer.StoreDbContext.sql b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/scripts/db.Microsoft.EntityFrameworkCore.SqlServer.StoreDbContext.sql index 9e908aedd..87364c0a6 100644 --- a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/scripts/db.Microsoft.EntityFrameworkCore.SqlServer.StoreDbContext.sql +++ b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/scripts/db.Microsoft.EntityFrameworkCore.SqlServer.StoreDbContext.sql @@ -2957,6 +2957,7 @@ CREATE TABLE [Store_DeliverNoteDetail] ( [ItemDesc1] nvarchar(64) NULL, [ItemDesc2] nvarchar(64) NULL, [ItemCode] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [FromPackingCode] nvarchar(64) NOT NULL, @@ -2993,7 +2994,6 @@ CREATE TABLE [Store_DeliverNoteDetail] ( [RecommendFromLocationGroup] nvarchar(64) NULL, [RecommendFromLocationErpCode] nvarchar(64) NULL, [RecommendFromWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -3411,6 +3411,7 @@ CREATE TABLE [Store_IssueNoteDetail] ( [ItemDesc1] nvarchar(64) NULL, [ItemDesc2] nvarchar(64) NULL, [ItemCode] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [FromPackingCode] nvarchar(450) NULL, @@ -3447,7 +3448,6 @@ CREATE TABLE [Store_IssueNoteDetail] ( [RecommendFromLocationGroup] nvarchar(64) NULL, [RecommendFromLocationErpCode] nvarchar(64) NULL, [RecommendFromWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -3855,6 +3855,7 @@ CREATE TABLE [Store_ProductionReturnNoteDetail] ( [ItemDesc1] nvarchar(64) NULL, [ItemDesc2] nvarchar(64) NULL, [ItemCode] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [FromPackingCode] nvarchar(450) NULL, @@ -3891,7 +3892,6 @@ CREATE TABLE [Store_ProductionReturnNoteDetail] ( [RecommendToLocationGroup] nvarchar(64) NULL, [RecommendToLocationErpCode] nvarchar(64) NULL, [RecommendToWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -4021,6 +4021,7 @@ CREATE TABLE [Store_ProductReceiptNoteDetail] ( [LocationErpCode] nvarchar(64) NOT NULL, [WarehouseCode] nvarchar(64) NOT NULL, [Status] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [RecommendContainerCode] nvarchar(64) NULL, @@ -4035,7 +4036,6 @@ CREATE TABLE [Store_ProductReceiptNoteDetail] ( [RecommendToLocationGroup] nvarchar(64) NULL, [RecommendToLocationErpCode] nvarchar(64) NULL, [RecommendToWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -4279,6 +4279,7 @@ CREATE TABLE [Store_PurchaseReceiptNoteDetail] ( [LocationErpCode] nvarchar(64) NOT NULL, [WarehouseCode] nvarchar(64) NOT NULL, [Status] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [RecommendContainerCode] nvarchar(64) NULL, @@ -4293,7 +4294,6 @@ CREATE TABLE [Store_PurchaseReceiptNoteDetail] ( [RecommendToLocationGroup] nvarchar(64) NULL, [RecommendToLocationErpCode] nvarchar(64) NULL, [RecommendToWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -4378,6 +4378,7 @@ CREATE TABLE [Store_PurchaseReturnNoteDetail] ( [LocationErpCode] nvarchar(64) NOT NULL, [WarehouseCode] nvarchar(64) NOT NULL, [Status] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [RecommendContainerCode] nvarchar(64) NULL, @@ -4392,7 +4393,6 @@ CREATE TABLE [Store_PurchaseReturnNoteDetail] ( [RecommendFromLocationGroup] nvarchar(64) NULL, [RecommendFromLocationErpCode] nvarchar(64) NULL, [RecommendFromWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -4466,6 +4466,7 @@ CREATE TABLE [Store_PutawayNoteDetail] ( [ItemDesc1] nvarchar(64) NULL, [ItemDesc2] nvarchar(64) NULL, [ItemCode] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [FromPackingCode] nvarchar(450) NULL, @@ -4502,7 +4503,6 @@ CREATE TABLE [Store_PutawayNoteDetail] ( [RecommendToLocationGroup] nvarchar(64) NULL, [RecommendToLocationErpCode] nvarchar(64) NULL, [RecommendToWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -4901,6 +4901,7 @@ CREATE TABLE [Store_UnplannedIssueNoteDetail] ( [LocationErpCode] nvarchar(64) NOT NULL, [WarehouseCode] nvarchar(64) NOT NULL, [Status] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [RecommendContainerCode] nvarchar(64) NULL, @@ -4915,7 +4916,6 @@ CREATE TABLE [Store_UnplannedIssueNoteDetail] ( [RecommendFromLocationGroup] nvarchar(64) NULL, [RecommendFromLocationErpCode] nvarchar(64) NULL, [RecommendFromWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, @@ -5000,6 +5000,7 @@ CREATE TABLE [Store_UnplannedReceiptNoteDetail] ( [LocationErpCode] nvarchar(64) NOT NULL, [WarehouseCode] nvarchar(64) NOT NULL, [Status] nvarchar(64) NOT NULL, + [Uom] nvarchar(64) NOT NULL, [Qty] decimal(18,6) NOT NULL, [StdPackQty] decimal(18,6) NOT NULL, [RecommendContainerCode] nvarchar(64) NULL, @@ -5014,7 +5015,6 @@ CREATE TABLE [Store_UnplannedReceiptNoteDetail] ( [RecommendToLocationGroup] nvarchar(64) NULL, [RecommendToLocationErpCode] nvarchar(64) NULL, [RecommendToWarehouseCode] nvarchar(64) NULL, - [Uom] nvarchar(64) NOT NULL, [RecommendQty] decimal(18,6) NOT NULL, [HandledContainerCode] nvarchar(64) NULL, [HandledPackingCode] nvarchar(64) NULL, diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/DictController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/DictController.cs index eeaf54727..2bb773383 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/DictController.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/DictController.cs @@ -1,6 +1,9 @@ +using System; using System.Threading.Tasks; using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Options; using Volo.Abp.AspNetCore.Mvc; +using Volo.Abp.Json; using Win_in.Sfs.Basedata.Application.Contracts; namespace Win_in.Sfs.Wms.Pda.Controllers.BaseDatas; @@ -18,9 +21,11 @@ public class DictController : AbpController /// /// /// - public DictController(IDictAppService dictApp) + public DictController(IDictAppService dictApp,IOptions options) { _dictApp = dictApp; + var str = options.Value.DefaultDateTimeFormat; + Console.WriteLine(str); } /// @@ -31,6 +36,8 @@ public class DictController : AbpController [HttpGet("by-code")] public virtual async Task GetByCodeAsync(string code) { - return await _dictApp.GetByCodeAsync(code).ConfigureAwait(false); + var dtos = await _dictApp.GetByCodeAsync(code).ConfigureAwait(false); + + return dtos; } } diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/JobController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/JobController.cs index b6d428c62..17418503c 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/JobController.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/JobController.cs @@ -1,4 +1,6 @@ +using System; using System.Collections.Generic; +using System.Linq; using System.Text.Json; using System.Threading.Tasks; using Microsoft.AspNetCore.Mvc; @@ -70,13 +72,13 @@ public class JobController : AbpController /// 获取全部任务数量统计 /// /// - [HttpGet("")] - public virtual async Task> CountAsync(bool isToday) + [HttpGet("get-job-count/{isToday}")] + public virtual async Task> CountAsync(Guid userId ,bool isToday) { - var wlgCodes = await _userWorkGroupAppService.GetCodsOfCurrentUserAsync().ConfigureAwait(false); - var jsonCodes = JsonSerializer.Serialize(wlgCodes); + var wlgCodes = await _userWorkGroupAppService.GetUserWorkGroupAsync(userId).ConfigureAwait(false); + var jsonCodes = JsonSerializer.Serialize(wlgCodes.Select(p=>p.WorkGroupCode)); - var status = new List() { (int)EnumJobStatus.Open, (int)EnumJobStatus.Doing }; + var status = new List() { EnumJobStatus.Open,EnumJobStatus.Doing }; var jsonStatus = JsonSerializer.Serialize(status); var list = new List(); @@ -162,6 +164,8 @@ public class JobController : AbpController purchaseReceiptJobRequest.Condition.Filters.Add(new Filter(nameof(PurchaseReceiptJobDTO.PlanArriveDate), Clock.Now.ToString("yyyy-MM-dd"), ">=", "And")); purchaseReceiptJobRequest.Condition.Filters.Add(new Filter(nameof(PurchaseReceiptJobDTO.PlanArriveDate), Clock.Now.AddDays(1).ToString("yyyy-MM-dd"), "<=", "And")); } + var purchaseReceiptJobs = await _purchaseReceiptJobAppService.GetCountByFilterAsync(purchaseReceiptJobRequest).ConfigureAwait(false); + list.Add(new JobCountDto { JobType = EnumJobType.PurchaseReceiptJob, Count = purchaseReceiptJobs }); var purchaseReturnJobs = await _purchaseReturnJobAppService.GetCountByFilterAsync(new SfsJobRequestInputBase { diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Dicts/DictAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Dicts/DictAutoMapperProfile.cs index 05459426f..b64bfb41d 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Dicts/DictAutoMapperProfile.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Dicts/DictAutoMapperProfile.cs @@ -13,7 +13,7 @@ public partial class BasedataApplicationAutoMapperProfile : Profile ; CreateMap() - .IgnoreAuditedObjectProperties(); + ; CreateMap() .IgnoreAuditedObjectProperties() diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Containers/ContainerAutoMapperProfile.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Containers/ContainerAutoMapperProfile.cs index 5fadf445f..eb1ddb3d3 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Containers/ContainerAutoMapperProfile.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Containers/ContainerAutoMapperProfile.cs @@ -12,7 +12,8 @@ public partial class InventoryApplicationAutoMapperProfile : Profile CreateMap() .ReverseMap(); - CreateMap().IgnoreAuditedObjectProperties(); + CreateMap() + ; CreateMap() .IgnoreAuditedObjectProperties() diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application/CountLabels/CountLabelAutoMapperProfile.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application/CountLabels/CountLabelAutoMapperProfile.cs index e94bad7dc..6894bb819 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application/CountLabels/CountLabelAutoMapperProfile.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application/CountLabels/CountLabelAutoMapperProfile.cs @@ -10,8 +10,7 @@ public class CountLabelAutoMapperProfile : Profile public CountLabelAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); CreateMap(); } diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletCode/PalletCodeAutoMapperProfile.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletCode/PalletCodeAutoMapperProfile.cs index 79b154e49..4c591b486 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletCode/PalletCodeAutoMapperProfile.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletCode/PalletCodeAutoMapperProfile.cs @@ -10,8 +10,7 @@ public class PalletCodeAutoMapperProfile : Profile public PalletCodeAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); CreateMap(); } diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletLabels/PalletLabelAutoMapperProfile.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletLabels/PalletLabelAutoMapperProfile.cs index b92d2680a..1195131aa 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletLabels/PalletLabelAutoMapperProfile.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application/PalletLabels/PalletLabelAutoMapperProfile.cs @@ -10,7 +10,6 @@ public class PalletLabelAutoMapperProfile : Profile public PalletLabelAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ForMember(x => x.ItemName, y => y.MapFrom(d => d.Name)) .ForMember(x => x.ItemDesc1, y => y.MapFrom(d => d.Desc1)) .ForMember(x => x.ItemDesc2, y => y.MapFrom(d => d.Desc2)) diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application/SaleLabels/SaleLabelAutoMapperProfile.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application/SaleLabels/SaleLabelAutoMapperProfile.cs index 5c0f94e93..fa931b956 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application/SaleLabels/SaleLabelAutoMapperProfile.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application/SaleLabels/SaleLabelAutoMapperProfile.cs @@ -10,7 +10,6 @@ public class SaleLabelAutoMapperProfile : Profile public SaleLabelAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); } } diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application/SerialCode/SerialCodeAutoMapperProfile.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application/SerialCode/SerialCodeAutoMapperProfile.cs index 585f112e9..edf57b3de 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application/SerialCode/SerialCodeAutoMapperProfile.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application/SerialCode/SerialCodeAutoMapperProfile.cs @@ -10,8 +10,7 @@ public class SerialCodeAutoMapperProfile : Profile public SerialCodeAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); CreateMap(); } diff --git a/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypeSubscribes/MessageTypeSubscribeAutoMapperProfile.cs b/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypeSubscribes/MessageTypeSubscribeAutoMapperProfile.cs index 7fedb3bf6..547f34e10 100644 --- a/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypeSubscribes/MessageTypeSubscribeAutoMapperProfile.cs +++ b/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypeSubscribes/MessageTypeSubscribeAutoMapperProfile.cs @@ -10,8 +10,7 @@ public partial class MessageApplicationAutoMapperProfile : Profile public void MessageTypeSubscribesAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); CreateMap() .IgnoreAuditedObjectProperties() diff --git a/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypes/MessageTypeAutoMapperProfile.cs b/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypes/MessageTypeAutoMapperProfile.cs index d602c2108..08dd8ec08 100644 --- a/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypes/MessageTypeAutoMapperProfile.cs +++ b/be/Modules/Message/src/Win_in.Sfs.Message.Application/MessageTypes/MessageTypeAutoMapperProfile.cs @@ -10,7 +10,6 @@ public partial class MessageApplicationAutoMapperProfile : Profile public void MessageTypeAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); } } diff --git a/be/Modules/Message/src/Win_in.Sfs.Message.Application/NotifyMessages/NotifyMessageAutoMapperProfile.cs b/be/Modules/Message/src/Win_in.Sfs.Message.Application/NotifyMessages/NotifyMessageAutoMapperProfile.cs index cfbf6da69..44e43ddb7 100644 --- a/be/Modules/Message/src/Win_in.Sfs.Message.Application/NotifyMessages/NotifyMessageAutoMapperProfile.cs +++ b/be/Modules/Message/src/Win_in.Sfs.Message.Application/NotifyMessages/NotifyMessageAutoMapperProfile.cs @@ -11,8 +11,7 @@ public partial class MessageApplicationAutoMapperProfile : Profile public void NotifyMessageAutoMapperProfileConfig() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); CreateMap() .Ignore(x => x.ConcurrencyStamp) diff --git a/be/Modules/Message/src/Win_in.Sfs.Message.Application/PrivateMessages/PrivateMessageAutoMapperProfile.cs b/be/Modules/Message/src/Win_in.Sfs.Message.Application/PrivateMessages/PrivateMessageAutoMapperProfile.cs index 460d3b5ae..f147927eb 100644 --- a/be/Modules/Message/src/Win_in.Sfs.Message.Application/PrivateMessages/PrivateMessageAutoMapperProfile.cs +++ b/be/Modules/Message/src/Win_in.Sfs.Message.Application/PrivateMessages/PrivateMessageAutoMapperProfile.cs @@ -10,7 +10,6 @@ public class PrivateMessageAutoMapperProfile : Profile public PrivateMessageAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); } } diff --git a/be/Modules/Message/src/Win_in.Sfs.Message.Application/UserNotifyMessages/UserNotifyMessageAutoMapperProfile.cs b/be/Modules/Message/src/Win_in.Sfs.Message.Application/UserNotifyMessages/UserNotifyMessageAutoMapperProfile.cs index c86fc455e..78ba65c1d 100644 --- a/be/Modules/Message/src/Win_in.Sfs.Message.Application/UserNotifyMessages/UserNotifyMessageAutoMapperProfile.cs +++ b/be/Modules/Message/src/Win_in.Sfs.Message.Application/UserNotifyMessages/UserNotifyMessageAutoMapperProfile.cs @@ -11,8 +11,7 @@ public partial class MessageApplicationAutoMapperProfile : Profile public void UserNotifyAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() - .BeforeMap((x, y) => y.UserId = x.CreatorId==null?Guid.Empty: x.CreatorId.Value) + .BeforeMap((x, y) => y.UserId = x.CreatorId==null?Guid.Empty: x.CreatorId.Value) .ReverseMap(); CreateMap(); diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/CachingExtensions.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/CachingExtensions.cs index 80952cec2..d2c552f04 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/CachingExtensions.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/CachingExtensions.cs @@ -4,6 +4,7 @@ using System.Linq; using System.Threading.Tasks; using Microsoft.Extensions.Caching.Distributed; using Volo.Abp.Caching; +using Volo.Abp.Json; namespace Win_in.Sfs.Shared.Application; @@ -27,6 +28,10 @@ public static class CachingExtensions { TCacheItem cacheItem; + + //return await factory.Invoke().ConfigureAwait(false); + + //todo 有问题 时间转换 坑坑坑 var result = await cache.GetAsync(key).ConfigureAwait(false); if (result == null) { 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 600523dce..fd6654cd6 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 @@ -159,8 +159,12 @@ public abstract class SfsCrudWithDetailsAppServiceBase, List>(entities); - var hasDetails = typeof(TEntity) is SfsMasterAggregateRootBase detailEntity; - return ExportImportService.Export(list, detailsProptyName: hasDetails ? nameof(detailEntity.Details) : null); + + //var hasDetails = typeof(TEntity) is SfsMasterAggregateRootBase detailEntity; + var tt = typeof(TEntity).GetBaseClasses(typeof(SfsMasterAggregateRootBase)); + var hasDetails = tt.Length > 0 ? true : false; + + return ExportImportService.Export(list,detailsProptyName: hasDetails ? nameof(TDetail) : null); } /// diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobStatus.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobStatus.cs index dfe744d20..55467616b 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobStatus.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobStatus.cs @@ -1,3 +1,6 @@ +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; + namespace Win_in.Sfs.Shared.Domain.Shared; public enum EnumJobStatus @@ -5,30 +8,36 @@ public enum EnumJobStatus /// /// 空枚举 /// + [Display(Name = "空枚举")] None = 0, /// /// 待处理 /// + [Display(Name = "待处理")] Open = 1, /// /// 执行中 /// + [Display(Name = "执行中")] Doing = 2, /// /// 完成 /// + [Display(Name = "完成")] Done = 3, /// /// 关闭 /// + [Display(Name = "关闭")] Closed = 8, /// /// 作废 /// + [Display(Name = "作废")] Cancelled = 9 } diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain/Entities/SfsMasterAggregateRootBase.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain/Entities/SfsMasterAggregateRootBase.cs index 02df8fc8c..4cd6d8ee4 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain/Entities/SfsMasterAggregateRootBase.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain/Entities/SfsMasterAggregateRootBase.cs @@ -67,7 +67,7 @@ public abstract class SfsMasterAggregateRootBase : SfsAggregateRootBase Details.AddRange(details); } - public void ReplaceDetail(Guid id, TDetail newDetail) + public void ReplaceDetail(Guid id,TDetail newDetail) { var detail = GetDetail(id); @@ -106,7 +106,6 @@ public abstract class SfsMasterAggregateRootBase : SfsAggregateRootBase property.SetValue(detail, newValue); } } - /* ////todo check //var detail = GetDetail(id); diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Host/ModuleBase.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Host/ModuleBase.cs index 34c89f1ab..49586cc1f 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Host/ModuleBase.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Host/ModuleBase.cs @@ -1,10 +1,15 @@ using System; +using System.Configuration; using System.Data; using System.IO; using System.Linq; using System.Reflection; +using System.Runtime.Serialization; +using System.Text.Json; +using System.Text.Json.Serialization; using System.Text.RegularExpressions; using System.Threading.Tasks; +using DocumentFormat.OpenXml.InkML; using Microsoft.AspNetCore.Authentication.JwtBearer; using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.DataProtection; @@ -20,6 +25,7 @@ using Microsoft.Extensions.Hosting; using Microsoft.Extensions.Options; using Microsoft.OpenApi.Models; using NUglify.Helpers; +using Serilog.Formatting.Json; using StackExchange.Redis; using Swashbuckle.AspNetCore.SwaggerGen; using Volo.Abp; @@ -35,8 +41,11 @@ using Volo.Abp.Content; using Volo.Abp.Data; using Volo.Abp.EntityFrameworkCore; using Volo.Abp.Guids; +using Volo.Abp.Json; +using Volo.Abp.Json.SystemTextJson.JsonConverters; using Volo.Abp.Localization; using Volo.Abp.Modularity; +using Volo.Abp.Timing; using Win_in.Sfs.Shared.Application; using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; using Win_in.Sfs.Shared.Domain.Shared; @@ -70,6 +79,7 @@ public abstract class ModuleBase : AbpModule where T : AbpModule ConfigureAutoApiControllers(); ConfigureSwaggerServices(); ConfigureAddCors(); + Configure(); SetFormLimit(); ConfigureExceptionHanding(); } @@ -238,6 +248,9 @@ public abstract class ModuleBase : AbpModule where T : AbpModule protected virtual void Configure() { + //todo 解决时间 + // ServiceConfigurationContext.Services.AddTransient(); + } protected virtual void ConfigureAddCors() @@ -440,4 +453,35 @@ public abstract class ModuleBase : AbpModule where T : AbpModule options.SendExceptionsDetailsToClients = true; }); } + + /// + /// 为了处理abp的时间存入redis 在win环境读取出来报错 + /// + public class ConvertAbpJson : IJsonSerializer + { + public T Deserialize(string jsonString, bool camelCase = true) + { + return System.Text.Json.JsonSerializer.Deserialize(jsonString, GetOptions(camelCase)); + } + + public object Deserialize(Type type, string jsonString, bool camelCase = true) + { + return System.Text.Json.JsonSerializer.Deserialize(jsonString, type, GetOptions(camelCase)); + } + + public string Serialize(object obj, bool camelCase = true, bool indented = false) + { + return System.Text.Json.JsonSerializer.Serialize(obj, GetOptions(camelCase, indented)); + } + + private System.Text.Json.JsonSerializerOptions GetOptions(bool camelCase = true, bool indented = false) + { + return new System.Text.Json.JsonSerializerOptions + { + PropertyNameCaseInsensitive = camelCase, + WriteIndented = indented, + ReferenceHandler = ReferenceHandler.IgnoreCycles + }; + } + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/DTOs/UnplannedIssueJobDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/DTOs/UnplannedIssueJobDetailDTO.cs index 1d656fd2c..b42d6f039 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/DTOs/UnplannedIssueJobDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/DTOs/UnplannedIssueJobDetailDTO.cs @@ -10,4 +10,22 @@ public class UnplannedIssueJobDetailDTO : SfsJobRecommendFromDetailDTOBase [Display(Name = "原因代码")] public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/Inputs/UnplannedIssueJobDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/Inputs/UnplannedIssueJobDetailInput.cs index 9aa5b26de..a0523ab5c 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/Inputs/UnplannedIssueJobDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedIssueJobs/Inputs/UnplannedIssueJobDetailInput.cs @@ -11,6 +11,24 @@ public class UnplannedIssueJobDetailInput : SfsJobRecommendFromDetailInputBase, [Display(Name = "原因代码")] public string ReasonCode { get; set; } + //// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/DTOs/UnplannedReceiptJobDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/DTOs/UnplannedReceiptJobDetailDTO.cs index 8e729e1a6..916479a0f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/DTOs/UnplannedReceiptJobDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/DTOs/UnplannedReceiptJobDetailDTO.cs @@ -1,6 +1,38 @@ +using DocumentFormat.OpenXml.Wordprocessing; +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Data; + namespace Win_in.Sfs.Wms.Store.Application.Contracts; public class UnplannedReceiptJobDetailDTO : SfsJobRecommendToDetailDTOBase { + /// + /// 原因代码 + /// + [Display(Name = "原因代码")] + public string ReasonCode { get; set; } + + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// + /// 扩展属性 + /// + [Display(Name = "扩展属性")] + public ExtraPropertyDictionary ExtraProperties { get; set; } = new ExtraPropertyDictionary(); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/Inputs/UnplannedReceiptJobDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/Inputs/UnplannedReceiptJobDetailInput.cs index b42869a3f..a3ea7b3e3 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/Inputs/UnplannedReceiptJobDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/UnplannedReceiptJobs/Inputs/UnplannedReceiptJobDetailInput.cs @@ -11,6 +11,24 @@ public class UnplannedReceiptJobDetailInput : SfsJobRecommendToDetailInputBase, [Display(Name = "原因代码")] public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/DTOs/UnplannedIssueNoteDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/DTOs/UnplannedIssueNoteDetailDTO.cs index f93ca2d14..efa949974 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/DTOs/UnplannedIssueNoteDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/DTOs/UnplannedIssueNoteDetailDTO.cs @@ -17,4 +17,22 @@ public class UnplannedIssueNoteDetailDTO : SfsStoreRecommendFromDetailWithLotPac [Display(Name = "原因代码")] public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/Inputs/UnplannedIssueNoteDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/Inputs/UnplannedIssueNoteDetailInput.cs index 8f3179cb4..923365b36 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/Inputs/UnplannedIssueNoteDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedIssueNotes/Inputs/UnplannedIssueNoteDetailInput.cs @@ -13,6 +13,24 @@ public class UnplannedIssueNoteDetailInput : SfsStoreRecommendFromDetailWithLotP [Display(Name = "原因代码")] public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/DTOs/UnplannedReceiptNoteDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/DTOs/UnplannedReceiptNoteDetailDTO.cs index ea74d4e34..dbedb405b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/DTOs/UnplannedReceiptNoteDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/DTOs/UnplannedReceiptNoteDetailDTO.cs @@ -16,4 +16,22 @@ public class UnplannedReceiptNoteDetailDTO : SfsStoreRecommendToDetailWithLotPac /// [Display(Name = "原因代码")] public string ReasonCode { get; set; } + + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/Inputs/UnplannedReceiptNoteDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/Inputs/UnplannedReceiptNoteDetailInput.cs index c03b2db03..327e6af54 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/Inputs/UnplannedReceiptNoteDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/UnplannedReceiptNotes/Inputs/UnplannedReceiptNoteDetailInput.cs @@ -11,6 +11,24 @@ public class UnplannedReceiptNoteDetailInput : SfsStoreRecommendToDetailWithLotP [Display(Name = "原因代码")] public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/DTOs/UnplannedIssueRequestDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/DTOs/UnplannedIssueRequestDetailDTO.cs index 129aef93c..d5ecf445f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/DTOs/UnplannedIssueRequestDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/DTOs/UnplannedIssueRequestDetailDTO.cs @@ -12,4 +12,22 @@ public class UnplannedIssueRequestDetailDTO /// [Display(Name = "扩展属性")] public ExtraPropertyDictionary ExtraProperties { set; get; } = new ExtraPropertyDictionary(); + + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/Inputs/UnplannedIssueRequestDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/Inputs/UnplannedIssueRequestDetailInput.cs index c5f9138bf..d052b41b3 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/Inputs/UnplannedIssueRequestDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedIssueRequests/Inputs/UnplannedIssueRequestDetailInput.cs @@ -10,4 +10,22 @@ public class UnplannedIssueRequestDetailInput : SfsStoreDetailWithLotPackingQtyL /// [Display(Name = "扩展属性")] public ExtraPropertyDictionary ExtraProperties { get; set; } = new ExtraPropertyDictionary(); + + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/DTOs/UnplannedReceiptRequestDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/DTOs/UnplannedReceiptRequestDetailDTO.cs index aa67eb319..3bedef9ee 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/DTOs/UnplannedReceiptRequestDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/DTOs/UnplannedReceiptRequestDetailDTO.cs @@ -7,6 +7,30 @@ public class UnplannedReceiptRequestDetailDTO : SfsStoreDetailWithLotPackingQtyLocationStatusDTOBase , IHasExtraProperties { + /// + /// 原因代码 + /// + [Display(Name = "原因代码")] + public string ReasonCode { get; set; } + + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/Inputs/UnplannedReceiptRequestDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/Inputs/UnplannedReceiptRequestDetailInput.cs index 4d527adfd..bf59628f8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/Inputs/UnplannedReceiptRequestDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/UnplannedReceiptRequests/Inputs/UnplannedReceiptRequestDetailInput.cs @@ -5,6 +5,24 @@ namespace Win_in.Sfs.Wms.Store.Application.Contracts; public class UnplannedReceiptRequestDetailInput : SfsStoreDetailWithLotPackingQtyLocationInputBase, IHasExtraProperties { + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Bases/SfsJobAppServiceBase.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Bases/SfsJobAppServiceBase.cs index aa9cc4b2c..8aa54abe2 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Bases/SfsJobAppServiceBase.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Bases/SfsJobAppServiceBase.cs @@ -11,6 +11,7 @@ using Volo.Abp.Validation; using Win_in.Sfs.Shared.Application; using Win_in.Sfs.Shared.Application.Contracts; using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; using Win_in.Sfs.Wms.Store.Domain; @@ -153,6 +154,12 @@ public abstract class SfsJobAppServiceBase CompleteAsync(Guid id, TEntityDto dto) { var handleEntity = ObjectMapper.Map(dto); + var job= await _repository.GetAsync(id).ConfigureAwait(false); + if (job.JobStatus is EnumJobStatus.Closed or EnumJobStatus.Cancelled or EnumJobStatus.None or EnumJobStatus.Done)//需要考虑下 多次提交的问题 所以不判断 进行中 + { + throw new UserFriendlyException($"任务状态错误:编号为【{job.Number}】的任务已经【{job.JobStatus.GetDisplayName()}】"); + } + var handleResult = await _jobManager.CompleteAsync(handleEntity, CurrentUser).ConfigureAwait(false); var handleDto = ObjectMapper.Map(handleResult); return handleDto; diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/ExchangeDatas/StoreApplicationAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/ExchangeDatas/StoreApplicationAutoMapperProfile.cs index ab2640e21..0593916fd 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/ExchangeDatas/StoreApplicationAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/ExchangeDatas/StoreApplicationAutoMapperProfile.cs @@ -10,7 +10,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile private void ExchangeDataAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); // CreateMap() // .IgnoreAuditedObjectProperties() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CheckJobs/CheckJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CheckJobs/CheckJobAutoMapperProfile.cs index b8ae62e62..9bcd74c3a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CheckJobs/CheckJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CheckJobs/CheckJobAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CountJobs/CountJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CountJobs/CountJobAutoMapperProfile.cs index e1e543e8c..df81e992b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CountJobs/CountJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/CountJobs/CountJobAutoMapperProfile.cs @@ -73,11 +73,9 @@ public partial class StoreApplicationAutoMapperProfile : Profile .Ignore(x => x.Details); CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/DeliverJobs/DeliverJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/DeliverJobs/DeliverJobAutoMapperProfile.cs index f8bccdeb5..54e4efa4b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/DeliverJobs/DeliverJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/DeliverJobs/DeliverJobAutoMapperProfile.cs @@ -13,10 +13,10 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties(); + ; CreateMap() - .IgnoreAuditedObjectProperties(); + ; CreateMap(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAutoMapperProfile.cs index b12f088ce..b48a352c2 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAutoMapperProfile.cs @@ -16,11 +16,9 @@ public partial class StoreApplicationAutoMapperProfile : Profile ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() @@ -31,11 +29,9 @@ public partial class StoreApplicationAutoMapperProfile : Profile .Ignore(x => x.Id); CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() @@ -47,7 +43,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile ; CreateMap() - .IgnoreAuditedObjectProperties() .Ignore(x => x.WarehouseCode) .Ignore(x => x.Details) .Ignore(x => x.SummaryDetails) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAutoMapperProfile.cs index f382757bc..4758bb65f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAutoMapperProfile.cs @@ -14,11 +14,9 @@ public partial class StoreApplicationAutoMapperProfile : Profile CreateMap(); CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/JisDeliverJobs/JisDeliverJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/JisDeliverJobs/JisDeliverJobAutoMapperProfile.cs index 21a63b0c9..6e0b160b7 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/JisDeliverJobs/JisDeliverJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/JisDeliverJobs/JisDeliverJobAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductReceiveJobs/ProductReceiveJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductReceiveJobs/ProductReceiveJobAutoMapperProfile.cs index 817171844..7b9b0543a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductReceiveJobs/ProductReceiveJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductReceiveJobs/ProductReceiveJobAutoMapperProfile.cs @@ -13,8 +13,7 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() - .ReverseMap(); + .ReverseMap(); CreateMap() .IgnoreAuditedObjectProperties() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductionReturnJobs/ProductionReturnJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductionReturnJobs/ProductionReturnJobAutoMapperProfile.cs index 6eead08ba..2435e9d3b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductionReturnJobs/ProductionReturnJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductionReturnJobs/ProductionReturnJobAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap(); @@ -26,7 +25,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .Ignore(x => x.Id); CreateMap() - .IgnoreAuditedObjectProperties() ; } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAutoMapperProfile.cs index 963b4b5b3..0c9469123 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAutoMapperProfile.cs @@ -16,11 +16,9 @@ public partial class StoreApplicationAutoMapperProfile : Profile ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() - .IgnoreAuditedObjectProperties() ; CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReturnJobs/PurchaseReturnJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReturnJobs/PurchaseReturnJobAutoMapperProfile.cs index f486e014c..2ca4390c6 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReturnJobs/PurchaseReturnJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReturnJobs/PurchaseReturnJobAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedIssueJobs/UnplannedIssueJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedIssueJobs/UnplannedIssueJobAutoMapperProfile.cs index dec115e62..5ecdd3e85 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedIssueJobs/UnplannedIssueJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedIssueJobs/UnplannedIssueJobAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobAutoMapperProfile.cs index 8591cf74a..1716b485c 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerBindNotes/ContainerBindNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerBindNotes/ContainerBindNoteAutoMapperProfile.cs index d3969a17c..24c1894f3 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerBindNotes/ContainerBindNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerBindNotes/ContainerBindNoteAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/CountNotes/CountNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/CountNotes/CountNoteAppService.cs index 278f8a52c..47cdf7440 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/CountNotes/CountNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/CountNotes/CountNoteAppService.cs @@ -24,7 +24,14 @@ namespace Win_in.Sfs.Wms.Store.Application; [Route($"{StoreConsts.RootPath}count-note")] public class CountNoteAppService : - SfsStoreWithDetailsAppServiceBase, + SfsStoreWithDetailsAppServiceBase, ICountNoteAppService { private readonly ICountNoteManager _countNoteManager; @@ -35,7 +42,10 @@ public class CountNoteAppService : public CountNoteAppService( ICountNoteRepository repository, - ICountNoteManager countNoteManager, ICountPlanAppService countPlanAppService, ILocationAppService locationAppService, IItemBasicAppService itemBasicAppService) : base(repository) + ICountNoteManager countNoteManager, + ICountPlanAppService countPlanAppService, + ILocationAppService locationAppService, + IItemBasicAppService itemBasicAppService) : base(repository) { _countNoteManager = countNoteManager; _countPlanAppService = countPlanAppService; diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/JisProductReceiptNotes/JisProductReceiptNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/JisProductReceiptNotes/JisProductReceiptNoteAutoMapperProfile.cs index bae5c6578..f4e2446a3 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/JisProductReceiptNotes/JisProductReceiptNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/JisProductReceiptNotes/JisProductReceiptNoteAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .Ignore(x => x.ProdLine) .ReverseMap(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductReceiptNotes/ProductReceiptNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductReceiptNotes/ProductReceiptNoteAutoMapperProfile.cs index cb730c146..7bfc7fd9f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductReceiptNotes/ProductReceiptNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductReceiptNotes/ProductReceiptNoteAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .Ignore(x => x.ProdLine) .ReverseMap(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs index cfc41e44f..b4877764b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs @@ -14,7 +14,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReturnNotes/PurchaseReturnNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReturnNotes/PurchaseReturnNoteAutoMapperProfile.cs index bc12055ab..ce58489bc 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReturnNotes/PurchaseReturnNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReturnNotes/PurchaseReturnNoteAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ReceiptAbnormalNotes/ReceiptAbnormalNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ReceiptAbnormalNotes/ReceiptAbnormalNoteAutoMapperProfile.cs index 3532b2ca5..f92e2ca8f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ReceiptAbnormalNotes/ReceiptAbnormalNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ReceiptAbnormalNotes/ReceiptAbnormalNoteAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs index ba42b49cf..3e09d396c 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs @@ -49,31 +49,32 @@ public class RecycledMaterialReceiptNoteAppService : [HttpPost("")] public override async Task CreateAsync(RecycledMaterialReceiptNoteEditInput input) { - var entity= ObjectMapper.Map(input); + var entity = ObjectMapper.Map(input); - entity.Number=string.IsNullOrEmpty(input.Number) + entity.Number = string.IsNullOrEmpty(input.Number) ? await GenerateNumberAsync(nameof(RecycledMaterialReceiptNote), input.ActiveDate) .ConfigureAwait(false) : input.Number; + entity.SetId(GuidGenerator.Create()); foreach (var detail in entity.Details) { var detailNumber = await GenerateNumberAsync(nameof(RecycledMaterialReceiptNote), input.ActiveDate) .ConfigureAwait(false); - detail.Number=detailNumber; + detail.SetIdAndNumber(GuidGenerator, entity.Id, detailNumber); var locationDto = await _locationAppService.GetByCodeAsync(detail.LocationCode).ConfigureAwait(false); detail.LocationErpCode = locationDto.ErpLocationCode; detail.LocationArea = locationDto.AreaCode; detail.LocationGroup = locationDto.LocationGroupCode; - detail.WarehouseCode=locationDto.WarehouseCode; - var itemBasicDto=await _itemBasicAppService.GetByCodeAsync(detail.ItemCode).ConfigureAwait(false); + detail.WarehouseCode = locationDto.WarehouseCode; + var itemBasicDto = await _itemBasicAppService.GetByCodeAsync(detail.ItemCode).ConfigureAwait(false); detail.StdPackQty = itemBasicDto.StdPackQty; detail.Uom = itemBasicDto.BasicUom; } - entity=await _repository.InsertAsync(entity).ConfigureAwait(false); + entity = await _repository.InsertAsync(entity).ConfigureAwait(false); - await LocalEventBus.PublishAsync(new SfsCreatedEntityEventData(entity),false).ConfigureAwait(false); + await LocalEventBus.PublishAsync(new SfsCreatedEntityEventData(entity), false).ConfigureAwait(false); return ObjectMapper.Map(entity); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAutoMapperProfile.cs index 35ee6a020..4ac78addc 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs index 5967d9876..c66e42ebc 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs @@ -8,6 +8,7 @@ using Microsoft.AspNetCore.Mvc; using Microsoft.EntityFrameworkCore; using Volo.Abp; using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; using Win_in.Sfs.Wms.Store.Domain; @@ -57,7 +58,7 @@ public class PurchaseOrderAppService : foreach (var purchaseOrder in addList) { purchaseOrder.CreatorId = CurrentUser.Id; - purchaseOrder.Worker = CurrentUser.Name; + purchaseOrder.Worker = CurrentUser.GetName(); var supplierDto = await _supplierAppService.GetByCodeAsync(purchaseOrder.SupplierCode).ConfigureAwait(false); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAutoMapperProfile.cs index 2ef9b67b1..bff9c5e7d 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/SaleOrders/SaleOrderAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/SaleOrders/SaleOrderAutoMapperProfile.cs index 7006bf3f2..93c75bbf8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/SaleOrders/SaleOrderAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/SaleOrders/SaleOrderAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAppService.cs index de9cea2ea..cf4254513 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAppService.cs @@ -23,7 +23,14 @@ using Win_in.Sfs.Shared.Domain; [Route($"{StoreConsts.RootPath}count-plan")] public class CountPlanAppService : - SfsStoreRequestAppServiceBase, + SfsStoreRequestAppServiceBase, ICountPlanAppService { diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAutoMapperProfile.cs index fbac04195..cb7430c66 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/CountPlans/CountPlanAutoMapperProfile.cs @@ -29,7 +29,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .Ignore(x => x.DiffQty) .ReverseMap(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/PreparationPlans/PreparationPlanAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/PreparationPlans/PreparationPlanAutoMapperProfile.cs index 90a14f582..bd3697b54 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/PreparationPlans/PreparationPlanAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Plans/PreparationPlans/PreparationPlanAutoMapperProfile.cs @@ -10,7 +10,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile private void PreparationPlanAutoMapperProfile() { CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/DeliverRequests/DeliverRequestFisAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/DeliverRequests/DeliverRequestFisAppService.cs index 484fe8dfb..2a980b30b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/DeliverRequests/DeliverRequestFisAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/DeliverRequests/DeliverRequestFisAppService.cs @@ -115,7 +115,7 @@ public class DeliverRequestFisAppService : detail.ItemDesc2 = itemBasicDto.Desc2; detail.ItemName = itemBasicDto.Name; detail.Uom = itemBasicDto.BasicUom; - + detail.StdPackQty=itemBasicDto.StdPackQty; } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/InspectRequests/InspectRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/InspectRequests/InspectRequestAutoMapperProfile.cs index 2e27bf9ac..239fd3a30 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/InspectRequests/InspectRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/InspectRequests/InspectRequestAutoMapperProfile.cs @@ -14,7 +14,7 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties(); + ; CreateMap() .IgnoreAuditedObjectProperties() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ItemTransformRequests/ItemTransformRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ItemTransformRequests/ItemTransformRequestAutoMapperProfile.cs index 4e7dd161f..72add1c78 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ItemTransformRequests/ItemTransformRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ItemTransformRequests/ItemTransformRequestAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ForMember(x => x.ToItemName, y => y.MapFrom(d => d.ToItemName)) .ForMember(x => x.ToItemDesc1, y => y.MapFrom(d => d.ToItemDesc1)) .ForMember(x => x.ToItemDesc2, y => y.MapFrom(d => d.ToItemDesc2)) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAutoMapperProfile.cs index 6e957501f..9f0d49555 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAutoMapperProfile.cs @@ -14,7 +14,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap() diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductionReturnRequests/ProductionReturnRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductionReturnRequests/ProductionReturnRequestAutoMapperProfile.cs index 18c6c170f..c5d12102a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductionReturnRequests/ProductionReturnRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductionReturnRequests/ProductionReturnRequestAutoMapperProfile.cs @@ -13,7 +13,6 @@ public partial class StoreApplicationAutoMapperProfile : Profile .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap(); CreateMap(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs index 52e915a56..11d85fc8d 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs @@ -2,6 +2,7 @@ using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.Linq; using System.Threading.Tasks; +using Volo.Abp; using Volo.Abp.Users; using Volo.Abp.Validation; using Win_in.Sfs.Shared.Domain.Shared; @@ -31,9 +32,7 @@ public class PurchaseReceiptJobManager : SfsJobManagerBase CompleteAsync(PurchaseReceiptJob input, ICurrentUser user) { var entity = await Repository.FindAsync(input.Id).ConfigureAwait(false); - BuildDetailHandledAsync(input, entity); - //设置任务为完成 return await base.CompleteAsync(entity, user).ConfigureAwait(false); } @@ -52,6 +51,8 @@ public class PurchaseReceiptJobManager : SfsJobManagerBase public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobDetail.cs index a2ba8a699..9d1b62089 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/UnplannedReceiptJobs/UnplannedReceiptJobDetail.cs @@ -1,3 +1,4 @@ +using System.ComponentModel.DataAnnotations; using Volo.Abp.Data; namespace Win_in.Sfs.Wms.Store.Domain; @@ -10,6 +11,24 @@ public class UnplannedReceiptJobDetail : SfsJobRecommendToDetailEntityBase, IHas /// public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedIssueNotes/UnplannedIssueNoteDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedIssueNotes/UnplannedIssueNoteDetail.cs index 8f575b250..ef461133a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedIssueNotes/UnplannedIssueNoteDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedIssueNotes/UnplannedIssueNoteDetail.cs @@ -1,3 +1,4 @@ +using System.ComponentModel.DataAnnotations; using Volo.Abp.Data; namespace Win_in.Sfs.Wms.Store.Domain; @@ -9,6 +10,24 @@ public class UnplannedIssueNoteDetail : SfsStoreRecommendFromDetailWithLotPackin /// public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedReceiptNotes/UnplannedReceiptNoteDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedReceiptNotes/UnplannedReceiptNoteDetail.cs index 138e792de..eb0c1b067 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedReceiptNotes/UnplannedReceiptNoteDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/UnplannedReceiptNotes/UnplannedReceiptNoteDetail.cs @@ -1,3 +1,4 @@ +using System.ComponentModel.DataAnnotations; using Volo.Abp.Data; namespace Win_in.Sfs.Wms.Store.Domain; @@ -9,6 +10,24 @@ public class UnplannedReceiptNoteDetail : SfsStoreRecommendToDetailWithLotPackin /// public string ReasonCode { get; set; } + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs index 02f0fe835..f64b4e6e4 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs @@ -27,7 +27,7 @@ public class MaterialRequestManager /// public virtual async Task CreateBynNumberAsync(MaterialRequest entity) { - var number = string.IsNullOrEmpty(entity.Number) ? await GenerateNumberAsync(typeof(MaterialRequest).Name, entity.ActiveDate).ConfigureAwait(false) : entity.Number; + var number = string.IsNullOrEmpty(entity.Number) ? await GenerateNumberAsync(nameof(MaterialRequest), entity.ActiveDate).ConfigureAwait(false) : entity.Number; entity.SetIdAndNumberWithDetails(GuidGenerator, number); entity.Submit(); entity.Agree(); @@ -128,16 +128,35 @@ public class MaterialRequestManager oldEntity.ReplaceDetail(newDetail.Id, newDetail); } - var flag=oldEntity.Details.Any(p => p.ReceivedQty < p.Qty);//还有补料完 没收到的货 - - if (!flag) + foreach (var detail in oldEntity.Details) { - oldEntity.Complete(); + SetMaterialRequestDetailStatus(detail); } + //SetMaterialRequestStatus(oldEntity); + await Repository.UpdateAsync(oldEntity).ConfigureAwait(false); } + private void SetMaterialRequestDetailStatus(MaterialRequestDetail detail) + { + if (detail.Qty > detail.IssuedQty)//要100 实际只有50 + { + if (detail.ReceivedQty >= detail.Qty)//执行的时候发的比100还多 就完成 + { + detail.Status = EnumStatus.Close; + } + else + { + detail.Status=EnumStatus.Open; + } + } + else//要100 实际够100 + { + detail.Status = EnumStatus.Close; + } + } + public virtual async Task CompleteAsync(string number) { var entity = await GetByNumberAsync(number).ConfigureAwait(false); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedIssueRequests/UnplannedIssueRequestDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedIssueRequests/UnplannedIssueRequestDetail.cs index 2d597734a..a98da6f81 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedIssueRequests/UnplannedIssueRequestDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedIssueRequests/UnplannedIssueRequestDetail.cs @@ -1,3 +1,4 @@ +using System.ComponentModel.DataAnnotations; using Volo.Abp.Data; namespace Win_in.Sfs.Wms.Store.Domain; @@ -8,6 +9,24 @@ namespace Win_in.Sfs.Wms.Store.Domain; public class UnplannedIssueRequestDetail : SfsStoreDetailWithLotPackingQtyLocationStatusEntityBase , IHasExtraProperties { + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedReceiptRequests/UnplannedReceiptRequestDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedReceiptRequests/UnplannedReceiptRequestDetail.cs index ec68fc967..1ac70ec54 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedReceiptRequests/UnplannedReceiptRequestDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/UnplannedReceiptRequests/UnplannedReceiptRequestDetail.cs @@ -1,3 +1,4 @@ +using System.ComponentModel.DataAnnotations; using Volo.Abp.Data; namespace Win_in.Sfs.Wms.Store.Domain; @@ -7,6 +8,29 @@ namespace Win_in.Sfs.Wms.Store.Domain; /// public class UnplannedReceiptRequestDetail : SfsStoreDetailWithLotPackingQtyLocationStatusEntityBase, IHasExtraProperties { + /// + /// 原因代码 + /// + public string ReasonCode { get; set; } + + /// + /// 专案 + /// + [Display(Name = "专案")] + public string CaseCode { get; set; } + + /// + /// 项目分类 + /// + [Display(Name = "项目分类")] + public string ProjCapacityCode { get; set; } + + /// + /// 次交易码 + /// + [Display(Name = "次交易码")] + public string OnceBusiCode { get; set; } + /// /// 扩展属性 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/CountJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/CountJobAutoMapperProfile.cs index a0253c5fa..eb88b8826 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/CountJobAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/CountJobAutoMapperProfile.cs @@ -102,8 +102,6 @@ public partial class StoreEventAutoMapperProfile : Profile ; CreateMap() - .IgnoreAuditedObjectProperties() - // .ForMember(x => x.Item, y => y.MapFrom(d => new Item(d.ItemName, d.ItemDesc1, d.ItemDesc2))) // .ForMember(x => x.Batch, y => y.MapFrom(d => new Batch(d.SupplierBatch, d.ArriveDate, d.ProduceDate, d.ExpireDate))) .ForMember(x => x.InventoryLocationCode, y => y.MapFrom(d => d.LocationCode)) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Notes/RecycledMaterialReceiptNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Notes/RecycledMaterialReceiptNoteAutoMapperProfile.cs index d8e9c64ce..55dbc66b5 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Notes/RecycledMaterialReceiptNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Notes/RecycledMaterialReceiptNoteAutoMapperProfile.cs @@ -24,7 +24,6 @@ public partial class StoreEventAutoMapperProfile : Profile CreateMap() .ReverseMap(); CreateMap() - .IgnoreAuditedObjectProperties() .ReverseMap() ; } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionReturnJobEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionReturnJobEventHandler.cs index b8ac3da2a..4690c9f2d 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionReturnJobEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionReturnJobEventHandler.cs @@ -1,3 +1,4 @@ +using System; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; @@ -59,6 +60,7 @@ public class ProductionReturnJobEventHandler : { var input = ObjectMapper.Map(entity); + input.ReturnTime=DateTime.Now; input.Details = new List(); foreach (var detail in entity.Details.Where(detail => detail.HandledQty != 0)) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/DeliverRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/DeliverRequestEventHandler.cs index acba1747c..f63574787 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/DeliverRequestEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/DeliverRequestEventHandler.cs @@ -9,33 +9,89 @@ using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Shared.Event; 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.BusinessRequest; -using Win_in.Sfs.Wms.Store.Application.Contracts; - public class DeliverRequestEventHandler : StoreEventHandlerBase - , ILocalEventHandler> - , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler>> { private readonly IDeliverNoteAppService _deliverNoteApp; private readonly IDeliverJobAppService _deliverJobApp; private readonly ICustomerAddressAppService _customerAddressApp; + private readonly IDeliverRequestManager _deliverRequestManager; public DeliverRequestEventHandler( IDeliverJobAppService deliverJobApp , IDeliverNoteAppService deliverNoteApp - , ICustomerAddressAppService customerAddressApp - ) + , ICustomerAddressAppService customerAddressApp, IDeliverRequestManager deliverRequestManager) { _deliverNoteApp = deliverNoteApp; _deliverJobApp = deliverJobApp; _customerAddressApp = customerAddressApp; + _deliverRequestManager = deliverRequestManager; + } + + + /// + /// 创建后 + /// + /// Event data + [UnitOfWork] + public async Task HandleEventAsync(SfsCreatedEntityEventData eventData) + { + var entity = eventData.Entity; + if (entity.AutoSubmit) + { + await _deliverRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + + /// + /// 批量创建后 + /// + /// Event data + [UnitOfWork] + public async Task HandleEventAsync(SfsCreatedEntityEventData> eventData) + { + var entitys = eventData.Entity; + foreach (var entity in entitys) + { + if (entity.AutoSubmit) + { + await _deliverRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } } + /// + /// 审批后 + /// + /// + /// + [UnitOfWork] + public virtual async Task HandleEventAsync(SfsAbortedEntityEventData eventData) + { + var entity = eventData.Entity; + + //东阳特殊逻辑 + if (!entity.DirectCreateNote) + { + await _deliverJobApp.CancelByDeliverRequestAsync(entity.Number).ConfigureAwait(false); + } + } + + /// + /// 执行后 + /// + /// + /// [UnitOfWork] public virtual async Task HandleEventAsync(SfsHandledEntityEventData eventData) { @@ -54,26 +110,32 @@ public class DeliverRequestEventHandler } } + + #region 私有 + private async Task BuildDeliverNoteAsync(DeliverRequest request) { - var transactionType = await TransactionTypeAclService.GetByTransTypeAsync(EnumTransType.Deliver, EnumTransSubType.None).ConfigureAwait(false); + var transactionType = await TransactionTypeAclService + .GetByTransTypeAsync(EnumTransType.Deliver, EnumTransSubType.None).ConfigureAwait(false); if (request.DeliverRequestType == EnumDeliverRequestType.Normal) { transactionType = await TransactionTypeAclService.GetByTransTypeAsync( - EnumTransType.Deliver, - EnumTransSubType.Deliver_Standard).ConfigureAwait(false); + EnumTransType.Deliver, + EnumTransSubType.Deliver_Standard).ConfigureAwait(false); } else if (request.DeliverRequestType == EnumDeliverRequestType.FIS) { transactionType = await TransactionTypeAclService.GetByTransTypeAsync( - EnumTransType.Deliver, - EnumTransSubType.Deliver_FIS).ConfigureAwait(false); + EnumTransType.Deliver, + EnumTransSubType.Deliver_FIS).ConfigureAwait(false); } var createInput = ObjectMapper.Map(request); - var customerAddress = (await _customerAddressApp.GetByCustomerCodeAsync(request.CustomerCode).ConfigureAwait(false)).FirstOrDefault(); + var customerAddress = + (await _customerAddressApp.GetByCustomerCodeAsync(request.CustomerCode).ConfigureAwait(false)) + .FirstOrDefault(); LocationDTO toLocation = null; if (customerAddress != null && !string.IsNullOrEmpty(customerAddress.LocationCode)) @@ -88,14 +150,14 @@ public class DeliverRequestEventHandler foreach (var detail in request.Details) { var balances = await BalanceAclService.GetRecommendBalancesAsync( - new RecommendBalanceRequestInput() - { - ItemCode = detail.ItemCode, - Qty = detail.Qty, - LocationTypes = transactionType.OutLocationTypes, - LocationAreas = new List() { detail.AreaCode }, - Statuses = transactionType.OutInventoryStatuses - }).ConfigureAwait(false); + new RecommendBalanceRequestInput + { + ItemCode = detail.ItemCode, + Qty = detail.Qty, + LocationTypes = transactionType.OutLocationTypes, + LocationAreas = new List { detail.AreaCode }, + Statuses = transactionType.OutInventoryStatuses + }).ConfigureAwait(false); var sumQty = balances.Sum(t => t.Qty); @@ -150,9 +212,12 @@ public class DeliverRequestEventHandler throw new ArgumentOutOfRangeException(); } - var transactionType = await TransactionTypeAclService.GetByTransTypeAsync(EnumTransType.Deliver, transSubType).ConfigureAwait(false); + var transactionType = await TransactionTypeAclService.GetByTransTypeAsync(EnumTransType.Deliver, transSubType) + .ConfigureAwait(false); var createInput = ObjectMapper.Map(request); - var customerAddress = (await _customerAddressApp.GetByCustomerCodeAsync(request.CustomerCode).ConfigureAwait(false)).FirstOrDefault(); + var customerAddress = + (await _customerAddressApp.GetByCustomerCodeAsync(request.CustomerCode).ConfigureAwait(false)) + .FirstOrDefault(); LocationDTO toLocation = null; if (customerAddress != null && !string.IsNullOrEmpty(customerAddress.LocationCode)) { @@ -165,14 +230,14 @@ public class DeliverRequestEventHandler foreach (var detail in request.Details) { var balances = await BalanceAclService.GetRecommendBalancesAsync( - new RecommendBalanceRequestInput() - { - ItemCode = detail.ItemCode, - Qty = detail.Qty, - LocationTypes = transactionType.OutLocationTypes, - LocationAreas = new List() { detail.AreaCode }, - Statuses = transactionType.OutInventoryStatuses - }).ConfigureAwait(false); + new RecommendBalanceRequestInput + { + ItemCode = detail.ItemCode, + Qty = detail.Qty, + LocationTypes = transactionType.OutLocationTypes, + LocationAreas = new List { detail.AreaCode }, + Statuses = transactionType.OutInventoryStatuses + }).ConfigureAwait(false); var sumQty = balances.Sum(t => t.Qty); @@ -190,6 +255,7 @@ public class DeliverRequestEventHandler inputDetail.ToLocationErpCode = toLocation.ErpLocationCode; inputDetail.ToWarehouseCode = toLocation.WarehouseCode; } + var item = await ItemBasicAclService.GetByCodeAsync(balance.ItemCode).ConfigureAwait(false); if (item != null) @@ -214,18 +280,8 @@ public class DeliverRequestEventHandler createInput.Priority = PriorityHelper.GetPriority(Clock); createInput.PriorityIncrement = 1; - return new List() { createInput }; + return new List { createInput }; } - [UnitOfWork] - public virtual async Task HandleEventAsync(SfsAbortedEntityEventData eventData) - { - var entity = eventData.Entity; - - //东阳特殊逻辑 - if (!entity.DirectCreateNote) - { - await _deliverJobApp.CancelByDeliverRequestAsync(entity.Number).ConfigureAwait(false); - } - } + #endregion } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/Note/IssueNoteEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/Note/IssueNoteEventHandler.cs index 94d4e8369..8f718fb7e 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/Note/IssueNoteEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/Note/IssueNoteEventHandler.cs @@ -6,6 +6,8 @@ using Volo.Abp.Uow; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Shared.Event; using Win_in.Sfs.Wms.Store.Domain; +using static Win_in.Sfs.Wms.Store.Domain.Shared.StoreSettings; +using MaterialRequest = Win_in.Sfs.Wms.Store.Domain.MaterialRequest; namespace Win_in.Sfs.Wms.Store.Event.BusinessRequest; @@ -37,33 +39,6 @@ public class IssueNoteEventHandler await UpdateReceivedQtyMaterialRequestAsync(entity).ConfigureAwait(false); } - private async Task UpdateReceivedQtyMaterialRequestAsync(IssueNote entity) - { - var receiveQtyGroup = entity.Details - .GroupBy(p => new { p.ItemCode, p.ToLocationCode }) - .Select(p => new { p.Key.ItemCode, p.Key.ToLocationCode, Qty = p.Sum(d => d.Qty) }) - .ToList(); - - var materialRequest = await _materialRequestManager.GetByNumberAsync(entity.RequestNumber).ConfigureAwait(false); - - if (entity.RequestType != EnumMaterialRequestType.Issue_Direct.ToString()) - { - //更新叫料请求的已收数量 - foreach (var materialRequestDetail in materialRequest.Details) - { - var receiveQty = receiveQtyGroup.FirstOrDefault(p => - p.ItemCode == materialRequestDetail.ItemCode && - p.ToLocationCode == materialRequestDetail.ToLocationCode)?.Qty; - if (receiveQty != null) - { - materialRequestDetail.ReceivedQty += receiveQty.Value; - } - } - - await _materialRequestManager.UpdateDetailsAsync(materialRequest).ConfigureAwait(false); - } - } - /// /// 当叫料记录创建后 修改请求的值 /// @@ -93,4 +68,31 @@ public class IssueNoteEventHandler await UpdateReceivedQtyMaterialRequestAsync(entity).ConfigureAwait(false); } } + + private async Task UpdateReceivedQtyMaterialRequestAsync(IssueNote entity) + { + var receiveQtyGroup = entity.Details + .GroupBy(p => new { p.ItemCode, p.ToLocationCode }) + .Select(p => new { p.Key.ItemCode, p.Key.ToLocationCode, Qty = p.Sum(d => d.Qty) }) + .ToList(); + + var materialRequest = await _materialRequestManager.GetByNumberAsync(entity.RequestNumber).ConfigureAwait(false); + + if (entity.RequestType != EnumMaterialRequestType.Issue_Direct.ToString()) + { + //更新叫料请求的已收数量 + foreach (var materialRequestDetail in materialRequest.Details) + { + var receiveQty = receiveQtyGroup.FirstOrDefault(p => + p.ItemCode == materialRequestDetail.ItemCode && + p.ToLocationCode == materialRequestDetail.ToLocationCode)?.Qty; + if (receiveQty != null) + { + materialRequestDetail.ReceivedQty += receiveQty.Value; + } + } + + await _materialRequestManager.UpdateDetailsAsync(materialRequest).ConfigureAwait(false); + } + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs index fa0a16a2e..2e0b3a9f8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs @@ -16,20 +16,55 @@ using Application.Contracts; public class ProductRecycleRequestEventHandler : StoreEventHandlerBase , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler>> { private readonly IProductRecycleNoteAppService _productRecycleNoteApp; private readonly IBackFlushNoteAppService _backFlushNoteApp; private readonly IBomAppService _bomApp; + private readonly IProductRecycleRequestManager _productRecycleRequestManager; public ProductRecycleRequestEventHandler( IProductRecycleNoteAppService productRecycleNoteApp, IBackFlushNoteAppService backFlushNoteApp, - IBomAppService bomApp - ) + IBomAppService bomApp, IProductRecycleRequestManager + productRecycleRequestManager) { _productRecycleNoteApp = productRecycleNoteApp; _backFlushNoteApp = backFlushNoteApp; _bomApp = bomApp; + _productRecycleRequestManager = productRecycleRequestManager; + } + + /// + /// 创建后 + /// + /// Event data + [UnitOfWork] + public async Task HandleEventAsync(SfsCreatedEntityEventData eventData) + { + var entity = eventData.Entity; + if (entity.AutoSubmit) + { + await _productRecycleRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + + /// + /// 批量创建后 + /// + /// Event data + [UnitOfWork] + public async Task HandleEventAsync(SfsCreatedEntityEventData> eventData) + { + var entitys = eventData.Entity; + foreach (var entity in entitys) + { + if (entity.AutoSubmit) + { + await _productRecycleRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } } [UnitOfWork] @@ -49,6 +84,8 @@ public class ProductRecycleRequestEventHandler } } + #region 私有 + private async Task BuildProductRecycleNoteAsync(ProductRecycleRequest request) { var createInput = ObjectMapper.Map(request); @@ -115,6 +152,10 @@ public class ProductRecycleRequestEventHandler return detailInput; } + #endregion + + + /* private async Task> BuildFlushNotesAsync(ProductRecycleRequest request) { diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedIssueRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedIssueRequestEventHandler.cs index 4969e34e8..acfe68f31 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedIssueRequestEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedIssueRequestEventHandler.cs @@ -10,20 +10,58 @@ namespace Win_in.Sfs.Wms.Store.Event.BusinessRequest; public class UnplannedIssueRequestEventHandler : StoreEventHandlerBase - , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler>> + , ILocalEventHandler> { private readonly IUnplannedIssueJobAppService _unplannedIssueJobApp; private readonly IUnplannedIssueNoteAppService _unplannedIssueNoteAppService; + private readonly IUnplannedIssueRequestManager _unplannedIssueRequestManager; public UnplannedIssueRequestEventHandler( - IUnplannedIssueJobAppService unplannedIssueJobApp - , IUnplannedIssueNoteAppService unplannedIssueNoteAppService - ) + IUnplannedIssueJobAppService unplannedIssueJobApp, + IUnplannedIssueNoteAppService unplannedIssueNoteAppService, + IUnplannedIssueRequestManager unplannedIssueRequestManager) { _unplannedIssueJobApp = unplannedIssueJobApp; _unplannedIssueNoteAppService = unplannedIssueNoteAppService; + _unplannedIssueRequestManager = unplannedIssueRequestManager; } + /// + /// 创建后 + /// + /// Event data + public async Task HandleEventAsync(SfsCreatedEntityEventData eventData) + { + var entity = eventData.Entity; + if (entity.AutoSubmit) + { + await _unplannedIssueRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + + /// + /// 批量创建后 + /// + /// Event data + public async Task HandleEventAsync(SfsCreatedEntityEventData> eventData) + { + var entitys = eventData.Entity; + foreach (var entity in entitys) + { + if (entity.AutoSubmit) + { + await _unplannedIssueRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + } + + /// + /// 执行后 + /// + /// + /// public virtual async Task HandleEventAsync(SfsHandledEntityEventData eventData) { var entity = eventData.Entity; @@ -39,7 +77,10 @@ public class UnplannedIssueRequestEventHandler } } - private async Task BuildUnplannedIssueNoteCreateInputAsync(UnplannedIssueRequest entity) + #region 私有 + + private async Task BuildUnplannedIssueNoteCreateInputAsync( + UnplannedIssueRequest entity) { await Task.CompletedTask.ConfigureAwait(false); var createInput = ObjectMapper.Map(entity); @@ -50,6 +91,8 @@ public class UnplannedIssueRequestEventHandler return createInput; } + #endregion + private async Task BuildUnplannedIssueJobCreateInputAsync(UnplannedIssueRequest entity) { await Task.CompletedTask.ConfigureAwait(false); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedReceiptRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedReceiptRequestEventHandler.cs index 5e93227dc..dcec7d221 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedReceiptRequestEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/UnplannedReceiptRequestEventHandler.cs @@ -10,20 +10,58 @@ namespace Win_in.Sfs.Wms.Store.Event.BusinessRequest; public class UnplannedReceiptRequestEventHandler : StoreEventHandlerBase - , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler>> + , ILocalEventHandler> { private readonly IUnplannedReceiptJobAppService _unplannedReceiptJobApp; private readonly IUnplannedReceiptNoteAppService _unplannedReceiptNoteApp; + private readonly IUnplannedReceiptRequestManager _unplannedReceiptRequestManager; public UnplannedReceiptRequestEventHandler( - IUnplannedReceiptJobAppService unplannedReceiptJobApp - , IUnplannedReceiptNoteAppService unplannedReceiptNoteApp - ) + IUnplannedReceiptJobAppService unplannedReceiptJobApp, + IUnplannedReceiptNoteAppService unplannedReceiptNoteApp, + IUnplannedReceiptRequestManager unplannedReceiptRequestManager) { _unplannedReceiptNoteApp = unplannedReceiptNoteApp; + _unplannedReceiptRequestManager = unplannedReceiptRequestManager; _unplannedReceiptJobApp = unplannedReceiptJobApp; } + /// + /// 创建后 + /// + /// Event data + public async Task HandleEventAsync(SfsCreatedEntityEventData eventData) + { + var entity = eventData.Entity; + if (entity.AutoSubmit) + { + await _unplannedReceiptRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + + /// + /// 批量创建后 + /// + /// Event data + public async Task HandleEventAsync(SfsCreatedEntityEventData> eventData) + { + var entitys = eventData.Entity; + foreach (var entity in entitys) + { + if (entity.AutoSubmit) + { + await _unplannedReceiptRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + } + + /// + /// 执行后 + /// + /// + /// public virtual async Task HandleEventAsync(SfsHandledEntityEventData eventData) { var entity = eventData.Entity; @@ -41,7 +79,10 @@ public class UnplannedReceiptRequestEventHandler } } - private async Task BuildUnplannedReceiptNoteCreateInputAsync(UnplannedReceiptRequest entity) + #region 私有 + + private async Task BuildUnplannedReceiptNoteCreateInputAsync( + UnplannedReceiptRequest entity) { await Task.CompletedTask.ConfigureAwait(false); var createInput = ObjectMapper.Map(entity); @@ -52,7 +93,8 @@ public class UnplannedReceiptRequestEventHandler return createInput; } - private async Task BuildToUnplannedReceiptJobCreateInputAsync(UnplannedReceiptRequest entity) + private async Task BuildToUnplannedReceiptJobCreateInputAsync( + UnplannedReceiptRequest entity) { await Task.CompletedTask.ConfigureAwait(false); var createInput = ObjectMapper.Map(entity); @@ -75,6 +117,8 @@ public class UnplannedReceiptRequestEventHandler return createInput; } + #endregion + /* 改用AutoMapper实现 private void SetUnplannedReceiptJobDetails(UnplannedReceiptJobCreateInput createInput, List details) { @@ -111,5 +155,4 @@ public class UnplannedReceiptRequestEventHandler } } */ - } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/PurchaseReceiptNoteEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/PurchaseReceiptNoteEventHandler.cs index 891d194c9..719171fa8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/PurchaseReceiptNoteEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/PurchaseReceiptNoteEventHandler.cs @@ -120,7 +120,6 @@ public class PurchaseReceiptNoteEventHandler Dictionary dictionary) { if (entity.Details.Any(p => - p.PurchaseReceiptInspectStatus == EnumPurchaseReceiptInspect.NOK || p.PurchaseReceiptInspectStatus == EnumPurchaseReceiptInspect.OK)) { var inboundTransactions = new List(); diff --git a/build/src/docker/publish/conf/settings/appsettings.Development.json b/build/src/docker/publish/conf/settings/appsettings.Development.json index 38d969c76..5a4efcb2d 100644 --- a/build/src/docker/publish/conf/settings/appsettings.Development.json +++ b/build/src/docker/publish/conf/settings/appsettings.Development.json @@ -1,5 +1,5 @@ { - "AlwaysAllowAuthorization": "True", + "AlwaysAllowAuthorization": "true", "App": { "CorsOrigins": [ "http://localhost:59080", @@ -45,7 +45,7 @@ }, "AuthServer": { "Audience": "Auth", - "Authority": "http://dev.ccwin-in.com:21293/", + "Authority": "http://dev.ccwin-in.com:60083/", "ClientId": "Auth_App", "ClientSecret": "1q2w3E*", "RequireHttpsMetadata": "false", @@ -74,28 +74,28 @@ // "Store": "Server=localhost,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;" // }, "ConnectionStrings": { - "AbpAuditLogging": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpBackgroundJobs": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpBlobStoring": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpFeatureManagement": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpIdentity": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpIdentityServer": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpPermissionManagement": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpSettingManagement": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "AbpTenantManagement": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Auth": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Basedata": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "DataExchange": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "FileStorage": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Inventory": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Job": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Label": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Message": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;", - "Store": "Server=dev.ccwin-in.com,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;" + "AbpAuditLogging": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpBackgroundJobs": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpBlobStoring": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpFeatureManagement": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpIdentity": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpIdentityServer": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpPermissionManagement": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpSettingManagement": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpTenantManagement": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Auth": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Basedata": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "DataExchange": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "FileStorage": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Inventory": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Job": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Label": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Message": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Store": "Server=dev.ccwin-in.com,13319;Database=Wms_Dy_ShangHai;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;" }, "IdentityClients": { "Default": { - "Authority": "http://dev.ccwin-in.com:21293", + "Authority": "http://dev.ccwin-in.com:60083", "ClientId": "Auth_App", "ClientSecret": "1q2w3E*", "GrantType": "client_credentials", @@ -107,19 +107,20 @@ "Redis": { "Configuration": "localhost:21194", "KeyPrefix": "Wms:" + //"IsEnabled": "false" }, "RemoteServices": { "Auth": { - "BaseUrl": "http://dev.ccwin-in.com:21293/" + "BaseUrl": "http://dev.ccwin-in.com:60083/" }, "BaseData": { - "BaseUrl": "http://dev.ccwin-in.com:21294/" + "BaseUrl": "http://dev.ccwin-in.com:60084/" }, "Default": { - "BaseUrl": "http://dev.ccwin-in.com:21293/" + "BaseUrl": "http://dev.ccwin-in.com:60083/" }, "FileStorage": { - "BaseUrl": "http://dev.ccwin-in.com:21292/" + "BaseUrl": "http://dev.ccwin-in.com:60082/" }, "Inventory": { "BaseUrl": "http://localhost:59095/" @@ -128,10 +129,10 @@ "BaseUrl": "http://localhost:59095/" }, "Label": { - "BaseUrl": "http://dev.ccwin-in.com:21292/" + "BaseUrl": "http://dev.ccwin-in.com:60082/" }, "Message": { - "BaseUrl": "http://dev.ccwin-in.com:21292/" + "BaseUrl": "http://dev.ccwin-in.com:60082/" }, "Store": { "BaseUrl": "http://localhost:59095/" diff --git a/fe/PC/src/api/wms-api.js b/fe/PC/src/api/wms-api.js index 7d96a106d..8f8c59486 100644 --- a/fe/PC/src/api/wms-api.js +++ b/fe/PC/src/api/wms-api.js @@ -2,6 +2,7 @@ import request from '@/utils/request' import store from '@/store' // let baseURL = process.env.VUE_APP_BASE_API + '/' let baseURL = localStorage.getItem('base') + '/api/' +let printURL = localStorage.getItem('print') + '/api/' //新建 export function postCreate(data, url) { if (Object.keys(data).includes('company')) { @@ -242,7 +243,7 @@ export function getPage(data, url) { //打印标签 export function PrintServices(data) { return request({ - url: baseURL + 'reporting/PrintServices', + url: printURL + 'reporting/PrintServices', method: 'post', headers: { 'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8' @@ -408,11 +409,20 @@ export function notifyMessage(params, id) { }) } -// 库存-启用 | 库存余额 -export function inventoryBalanceActive(id) { +// 库存-启用 | 库存余额 +// export function inventoryBalanceActive(id) { +// return request({ +// url: baseURL + 'wms/inventory/inventory-balance/active?id=' + id, +// method: 'post', +// }) +// } + +// 库存-启用 | 库存余额 改 +export function inventoryBalanceActive(params) { return request({ - url: baseURL + 'wms/inventory/inventory-balance/active?id=' + id, + url: baseURL + 'wms/inventory/inventory-balance/' + params.id + '/active', method: 'post', + params: params, }) } @@ -456,8 +466,9 @@ export function createAndHandle(data) { // 人工叫料申请 | 人工发料任务 | 人工发料记录 | 自动叫料申请 | 自动发料任务 | 自动发料记录 | 直接发料记录 // 完工收货缴库申请 | 线边仓缴库申请 | 线边仓缴库记录 | 线边仓报废申请 | 线边仓报废记录 | 原料报废记录 export function materialRequestByType(data, url, params) { + let _type = params.type?params.type:params.requestType return request({ - url: baseURL + url + '/' + params.type, + url: baseURL + url + '/' + _type, method: 'post', params: params, data @@ -499,7 +510,7 @@ export function getPageListWip(data, url) { }) } -// 线边仓调拨确认按钮 | 客户调拨确认按钮 +// 线边仓调拨确认按钮 | 客户调拨确认按钮 | 自动发料记录 export function confirm(id, url) { return request({ url: baseURL + url + '/confirm/' + id, @@ -530,6 +541,22 @@ export function allSupplierByCodes(data) { data }) } + +// 根据code获取当前供应商信息 打印需要获取供应商信息(供应商简称等)相关位置 +export function getOneSupplierInfoByCode(code) { + return request({ + url: baseURL + 'basedata/supplier/by-code/' + code, + method: 'get' + }) +} + +// 根据code获取当前客户信息 打印需要获取供应商信息(客户地址等)相关位置 +export function getOneCustomerInfoByCode(code) { + return request({ + url: baseURL + 'basedata/customer/by-code/' + code, + method: 'get' + }) +} // 根据编号获取字典信息 // export function getDictByCode(code) { // return request({ diff --git a/fe/PC/src/api/wms-core.js b/fe/PC/src/api/wms-core.js index 965aa35c5..40ad301dc 100644 --- a/fe/PC/src/api/wms-core.js +++ b/fe/PC/src/api/wms-core.js @@ -2,6 +2,14 @@ import request from '@/utils/request' // let baseURL = localStorage.getItem('print') + '/api/' let baseURL = localStorage.getItem('base') + '/api/' +// 根据箱码获取标签相关信息 | 补打标签 +export function getOneInventoryLabelByCode(code) { + return request({ + url: baseURL + 'label/inventory-label/by-code/' + code, + method: 'get' + }) +} + // 批量获取箱标签信息 | 到货请求 export function getInventoryLabelByCodes(data) { return request({ diff --git a/fe/PC/src/api/wms-job.js b/fe/PC/src/api/wms-job.js index 6afac7482..62e663b3c 100644 --- a/fe/PC/src/api/wms-job.js +++ b/fe/PC/src/api/wms-job.js @@ -168,8 +168,9 @@ export function InspectJobHandle(data, params, url) { //人工发料任务 | 自动发料任务 export function materialRequestByType(data, url, params) { + let _type = params.type?params.type:params.requestType return request({ - url: baseURL + url + '/' + params.type, + url: baseURL + url + '/' + _type, method: 'post', params: params, data @@ -198,7 +199,7 @@ export function preparationPlanByNumber(params) { //质检——完成质检 export function completeSummaryDetailStatus(params, data) { return request({ - url: baseURL + 'wms/job/inspect-job/complete-summary-detail-status/' + params.id, + url: baseURL + 'wms/store/inspect-job/complete-summary-detail-status/' + params.id, method: 'post', params: params, data @@ -208,7 +209,7 @@ export function completeSummaryDetailStatus(params, data) { //质检——设置默认状态(清除质检) export function setDetailDefaultOkStatus(params, id, data) { return request({ - url: baseURL + 'wms/job/inspect-job/set-detail-default-ok-status/' + id, + url: baseURL + 'wms/store/inspect-job/set-detail-default-ok-status/' + id, method: 'post', params: params, data @@ -218,7 +219,7 @@ export function setDetailDefaultOkStatus(params, id, data) { //质检——设置详情为合格 export function setDetailOkStatus(params, id, data) { return request({ - url: baseURL + 'wms/job/inspect-job/set-detail-ok-status/' + id, + url: baseURL + 'wms/store/inspect-job/set-detail-ok-status/' + id, method: 'post', params: params, data @@ -228,7 +229,7 @@ export function setDetailOkStatus(params, id, data) { //质检——设置详情为不合格 export function setDetailNookStatus(params, id, data) { return request({ - url: baseURL + 'wms/job/inspect-job/set-detail-nook-status/' + id, + url: baseURL + 'wms/store/inspect-job/set-detail-nook-status/' + id, method: 'post', params: params, data diff --git a/fe/PC/src/components/StepsCountPlanForm/index.vue b/fe/PC/src/components/StepsCountPlanForm/index.vue index 46fbf5b54..d786649be 100644 --- a/fe/PC/src/components/StepsCountPlanForm/index.vue +++ b/fe/PC/src/components/StepsCountPlanForm/index.vue @@ -412,6 +412,15 @@ export default { //确定筛选 advancedFilter(url, list, TotalCount, data, oldSkipCount) { return () => { + // 盘点库存 过滤线边仓数据 20230417 + if (data == 'locationData') { + list.condition.filters.push({ + action: "!=", + column: "type", + logic: "And", + value: "5" + }) + } list.SkipCount = (oldSkipCount - 1) * list.MaxResultCount; this.tableLoading = true; getPageList(list, url) diff --git a/fe/PC/src/components/commonTabel-drawer/index.vue b/fe/PC/src/components/commonTabel-drawer/index.vue index c45b70de8..175f20e22 100644 --- a/fe/PC/src/components/commonTabel-drawer/index.vue +++ b/fe/PC/src/components/commonTabel-drawer/index.vue @@ -8,7 +8,6 @@ :with-header="false" :modal="false" size="100%" - style="height:calc(100% - 28px);top: 14px;right:14px" >
@@ -70,6 +69,7 @@