学 赵 1 year ago
parent
commit
b572a728bc
  1. 210
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Logs/log-20220718.txt
  2. 210
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Logs/log-20220825.txt
  3. 15055
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Logs/log-20221012.txt
  4. 11
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Startup.cs
  5. 8
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/components/list/index.js
  6. 1
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/centralized-control.js
  7. 106
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/jis-bbac/input/bbac_se_detail_service.js
  8. 104
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/jis-hbpo/input/hbpo_se_detail_service.js
  9. 6
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/material-relationship.js
  10. 10
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/material.js
  11. 2
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/price-list-app-service-bj.js
  12. 13
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/price-list.js
  13. 85
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/pub_se_detail_service.js
  14. 1
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/purchase_price_service.js
  15. 9
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/tb_re-parts-relationship_service.js
  16. 44
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/router/business.js
  17. 9
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/base-data/centralized-control.js
  18. 24
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/base-data/user.js
  19. 1
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/bj/input/bj_pub_se_detail_service.js
  20. 4
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/home.js
  21. 1
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/in/input/in_pub_se_detail_service.js
  22. 108
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/invoice/invoice_map_group.js
  23. 1
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/jit/input/bbac_jit_pub_se_detail_service.js
  24. 1
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/jit/input/hbpo_jit_pub_se_detail_service.js
  25. 28
      code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/PUB_SA_DTO.cs
  26. 6
      code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/MaterialRelationship/MaterialRelationshipDtoBase.cs
  27. 36
      code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/Materials/MaterialDtoBase.cs
  28. 48
      code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/Prices/PriceListDtoBase.cs
  29. 163
      code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SA_SERVICE.cs
  30. 9
      code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SE_DETAIL_SERVICE.cs
  31. 14
      code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs
  32. 12
      code/src/SettleAccount.sln

210
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Logs/log-20220718.txt

@ -1,210 +0,0 @@
2022-07-18 16:04:56.174 G Starting web host.
2022-07-18 16:05:04.885 G User profile is available. Using '"C:\Users\Administrator\AppData\Local\ASP.NET\DataProtection-Keys"' as key repository and Windows DPAPI to encrypt keys at rest.
2022-07-18 16:05:04.997 G Loaded ABP modules:
2022-07-18 16:05:04.998 G - Win.Sfs.SettleAccount.SettleAccountHttpApiHostModule
2022-07-18 16:05:04.999 G - Win.Sfs.SettleAccount.SettleAccountApplicationModule
2022-07-18 16:05:05.000 G - Win.Sfs.SettleAccount.SettleAccountJobModule
2022-07-18 16:05:05.000 G - Win.Sfs.SettleAccount.SettleAccountDomainModule
2022-07-18 16:05:05.001 G - Volo.Abp.Domain.AbpDddDomainModule
2022-07-18 16:05:05.002 G - Volo.Abp.Auditing.AbpAuditingModule
2022-07-18 16:05:05.002 G - Volo.Abp.Data.AbpDataModule
2022-07-18 16:05:05.002 G - Volo.Abp.ObjectExtending.AbpObjectExtendingModule
2022-07-18 16:05:05.003 G - Volo.Abp.Localization.AbpLocalizationAbstractionsModule
2022-07-18 16:05:05.004 G - Volo.Abp.Validation.AbpValidationAbstractionsModule
2022-07-18 16:05:05.004 G - Volo.Abp.Uow.AbpUnitOfWorkModule
2022-07-18 16:05:05.005 G - Volo.Abp.EventBus.Abstractions.AbpEventBusAbstractionsModule
2022-07-18 16:05:05.005 G - Volo.Abp.Json.AbpJsonModule
2022-07-18 16:05:05.006 G - Volo.Abp.Timing.AbpTimingModule
2022-07-18 16:05:05.006 G - Volo.Abp.Localization.AbpLocalizationModule
2022-07-18 16:05:05.007 G - Volo.Abp.VirtualFileSystem.AbpVirtualFileSystemModule
2022-07-18 16:05:05.008 G - Volo.Abp.Settings.AbpSettingsModule
2022-07-18 16:05:05.008 G - Volo.Abp.Security.AbpSecurityModule
2022-07-18 16:05:05.009 G - Volo.Abp.MultiTenancy.AbpMultiTenancyModule
2022-07-18 16:05:05.009 G - Volo.Abp.Threading.AbpThreadingModule
2022-07-18 16:05:05.010 G - Volo.Abp.EventBus.AbpEventBusModule
2022-07-18 16:05:05.010 G - Volo.Abp.Guids.AbpGuidsModule
2022-07-18 16:05:05.011 G - Volo.Abp.ObjectMapping.AbpObjectMappingModule
2022-07-18 16:05:05.011 G - Volo.Abp.ExceptionHandling.AbpExceptionHandlingModule
2022-07-18 16:05:05.012 G - Volo.Abp.Specifications.AbpSpecificationsModule
2022-07-18 16:05:05.013 G - Win.Sfs.SettleAccount.SettleAccountDomainSharedModule
2022-07-18 16:05:05.013 G - Volo.Abp.Validation.AbpValidationModule
2022-07-18 16:05:05.014 G - Win.Sfs.SettleAccount.SettleAccountApplicationContractsModule
2022-07-18 16:05:05.015 G - Volo.Abp.Application.AbpDddApplicationContractsModule
2022-07-18 16:05:05.016 G - Volo.Abp.Authorization.AbpAuthorizationModule
2022-07-18 16:05:05.017 G - Volo.Abp.Authorization.AbpAuthorizationAbstractionsModule
2022-07-18 16:05:05.018 G - Volo.Abp.AutoMapper.AbpAutoMapperModule
2022-07-18 16:05:05.019 G - Volo.Abp.Dapper.AbpDapperModule
2022-07-18 16:05:05.020 G - Volo.Abp.EntityFrameworkCore.AbpEntityFrameworkCoreModule
2022-07-18 16:05:05.021 G - Win.Abp.Snowflakes.AbpSnowflakeGeneratorModule
2022-07-18 16:05:05.022 G - Volo.Abp.Http.Client.IdentityModel.AbpHttpClientIdentityModelModule
2022-07-18 16:05:05.023 G - Volo.Abp.Http.Client.AbpHttpClientModule
2022-07-18 16:05:05.025 G - Volo.Abp.Http.AbpHttpModule
2022-07-18 16:05:05.026 G - Volo.Abp.Http.AbpHttpAbstractionsModule
2022-07-18 16:05:05.027 G - Volo.Abp.Minify.AbpMinifyModule
2022-07-18 16:05:05.028 G - Volo.Abp.Castle.AbpCastleCoreModule
2022-07-18 16:05:05.030 G - Volo.Abp.IdentityModel.AbpIdentityModelModule
2022-07-18 16:05:05.031 G - Volo.Abp.Caching.AbpCachingModule
2022-07-18 16:05:05.032 G - Volo.Abp.Serialization.AbpSerializationModule
2022-07-18 16:05:05.033 G - Volo.Abp.Identity.AbpIdentityHttpApiClientModule
2022-07-18 16:05:05.034 G - Volo.Abp.Identity.AbpIdentityApplicationContractsModule
2022-07-18 16:05:05.035 G - Volo.Abp.Identity.AbpIdentityDomainSharedModule
2022-07-18 16:05:05.036 G - Volo.Abp.Users.AbpUsersDomainSharedModule
2022-07-18 16:05:05.037 G - Volo.Abp.Features.AbpFeaturesModule
2022-07-18 16:05:05.039 G - Volo.Abp.Users.AbpUsersAbstractionModule
2022-07-18 16:05:05.040 G - Volo.Abp.Application.AbpDddApplicationModule
2022-07-18 16:05:05.042 G - Volo.Abp.GlobalFeatures.AbpGlobalFeaturesModule
2022-07-18 16:05:05.043 G - Volo.Abp.PermissionManagement.AbpPermissionManagementApplicationContractsModule
2022-07-18 16:05:05.045 G - Volo.Abp.PermissionManagement.AbpPermissionManagementDomainSharedModule
2022-07-18 16:05:05.046 G - Volo.Abp.AspNetCore.Mvc.AbpAspNetCoreMvcModule
2022-07-18 16:05:05.047 G - Volo.Abp.AspNetCore.AbpAspNetCoreModule
2022-07-18 16:05:05.048 G - Volo.Abp.ApiVersioning.AbpApiVersioningAbstractionsModule
2022-07-18 16:05:05.049 G - Volo.Abp.AspNetCore.Mvc.AbpAspNetCoreMvcContractsModule
2022-07-18 16:05:05.049 G - Volo.Abp.UI.Navigation.AbpUiNavigationModule
2022-07-18 16:05:05.050 G - Volo.Abp.UI.AbpUiModule
2022-07-18 16:05:05.051 G - Win.Sfs.SettleAccount.SettleAccountEntityFrameworkCoreModule
2022-07-18 16:05:05.051 G - Volo.Abp.PermissionManagement.EntityFrameworkCore.AbpPermissionManagementEntityFrameworkCoreModule
2022-07-18 16:05:05.052 G - Volo.Abp.PermissionManagement.AbpPermissionManagementDomainModule
2022-07-18 16:05:05.053 G - Volo.Abp.SettingManagement.EntityFrameworkCore.AbpSettingManagementEntityFrameworkCoreModule
2022-07-18 16:05:05.054 G - Volo.Abp.SettingManagement.AbpSettingManagementDomainModule
2022-07-18 16:05:05.055 G - Volo.Abp.SettingManagement.AbpSettingManagementDomainSharedModule
2022-07-18 16:05:05.055 G - Volo.Abp.AuditLogging.EntityFrameworkCore.AbpAuditLoggingEntityFrameworkCoreModule
2022-07-18 16:05:05.056 G - Volo.Abp.AuditLogging.AbpAuditLoggingDomainModule
2022-07-18 16:05:05.057 G - Volo.Abp.AuditLogging.AbpAuditLoggingDomainSharedModule
2022-07-18 16:05:05.057 G - Volo.Abp.TenantManagement.EntityFrameworkCore.AbpTenantManagementEntityFrameworkCoreModule
2022-07-18 16:05:05.058 G - Volo.Abp.TenantManagement.AbpTenantManagementDomainModule
2022-07-18 16:05:05.059 G - Volo.Abp.TenantManagement.AbpTenantManagementDomainSharedModule
2022-07-18 16:05:05.060 G - Win.Sfs.SettleAccount.SettleAccountHttpApiModule
2022-07-18 16:05:05.061 G - Volo.Abp.Autofac.AbpAutofacModule
2022-07-18 16:05:05.061 G - Volo.Abp.EntityFrameworkCore.SqlServer.AbpEntityFrameworkCoreSqlServerModule
2022-07-18 16:05:05.062 G - Volo.Abp.AspNetCore.Serilog.AbpAspNetCoreSerilogModule
2022-07-18 16:05:05.062 G - Volo.Abp.BlobStoring.AbpBlobStoringModule
2022-07-18 16:05:05.063 G - Volo.Abp.BlobStoring.FileSystem.AbpBlobStoringFileSystemModule
2022-07-18 16:05:05.064 G - Volo.Abp.BackgroundJobs.Hangfire.AbpBackgroundJobsHangfireModule
2022-07-18 16:05:05.065 G - Volo.Abp.BackgroundJobs.AbpBackgroundJobsAbstractionsModule
2022-07-18 16:05:05.066 G - Volo.Abp.Hangfire.AbpHangfireModule
2022-07-18 16:05:05.155 G Start installing Hangfire SQL objects...
2022-07-18 16:05:57.280 G An exception occurred while trying to perform the migration. Retrying...
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, Boolean applyTransientFaultHandling, String accessToken)
at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-07-18 16:05:57.297 G An exception occurred while trying to perform the migration. Retrying...
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-07-18 16:05:57.305 G An exception occurred while trying to perform the migration.
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-07-18 16:05:57.311 G Was unable to perform the Hangfire schema migration due to an exception. Ignore this message unless you've just installed or upgraded Hangfire.
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-07-18 16:05:57.328 G Starting Hangfire Server using job storage: 'SQL Server: 192.168.0.140@SettleAccountService'
2022-07-18 16:05:57.329 G Using the following options for SQL Server job storage: Queue poll interval: 00:00:15.
2022-07-18 16:05:57.329 G Using the following options for Hangfire Server:
Worker count: 20
Listening queues: 'default'
Shutdown timeout: 00:00:15
Schedule polling interval: 00:00:15
2022-07-18 16:05:57.405 G Execution BackgroundServerProcess is in the Failed state now due to an exception, execution will be retried no more than in 00:00:15
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerConnection.AnnounceServer(String serverId, ServerContext context)
at Hangfire.Server.BackgroundServerProcess.CreateServer(BackgroundServerContext context)
at Hangfire.Server.BackgroundServerProcess.Execute(Guid executionId, BackgroundExecution execution, CancellationToken stoppingToken, CancellationToken stoppedToken, CancellationToken shutdownToken)
at Hangfire.Server.BackgroundProcessingServer.RunServer(Guid executionId, Object state)
at Hangfire.Processing.BackgroundExecution.Run(Action`2 callback, Object state)
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-07-18 16:05:57.415 G Starting Hangfire Server using job storage: 'SQL Server: 192.168.0.140@SettleAccountService'
2022-07-18 16:05:57.416 G Using the following options for SQL Server job storage: Queue poll interval: 00:00:15.
2022-07-18 16:05:57.417 G Using the following options for Hangfire Server:
Worker count: 20
Listening queues: 'default'
Shutdown timeout: 00:00:15
Schedule polling interval: 00:00:15
2022-07-18 16:05:57.422 G Execution BackgroundServerProcess is in the Failed state now due to an exception, execution will be retried no more than in 00:00:15
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerConnection.AnnounceServer(String serverId, ServerContext context)
at Hangfire.Server.BackgroundServerProcess.CreateServer(BackgroundServerContext context)
at Hangfire.Server.BackgroundServerProcess.Execute(Guid executionId, BackgroundExecution execution, CancellationToken stoppingToken, CancellationToken stoppedToken, CancellationToken shutdownToken)
at Hangfire.Server.BackgroundProcessingServer.RunServer(Guid executionId, Object state)
at Hangfire.Processing.BackgroundExecution.Run(Action`2 callback, Object state)
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-07-18 16:05:59.122 G Entity Framework Core "5.0.8" initialized '"PermissionManagementDbContext"' using provider '"Microsoft.EntityFrameworkCore.SqlServer"' with options: "QuerySplittingBehavior=SplitQuery "
2022-07-18 16:05:59.144 G An error occurred using the connection to database '"ABP"' on server '"192.168.0.140"'.

210
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Logs/log-20220825.txt

@ -1,210 +0,0 @@
2022-08-25 09:13:13.982 G Starting web host.
2022-08-25 09:13:22.800 G User profile is available. Using '"C:\Users\Administrator\AppData\Local\ASP.NET\DataProtection-Keys"' as key repository and Windows DPAPI to encrypt keys at rest.
2022-08-25 09:13:22.916 G Loaded ABP modules:
2022-08-25 09:13:22.918 G - Win.Sfs.SettleAccount.SettleAccountHttpApiHostModule
2022-08-25 09:13:22.918 G - Win.Sfs.SettleAccount.SettleAccountApplicationModule
2022-08-25 09:13:22.919 G - Win.Sfs.SettleAccount.SettleAccountJobModule
2022-08-25 09:13:22.920 G - Win.Sfs.SettleAccount.SettleAccountDomainModule
2022-08-25 09:13:22.921 G - Volo.Abp.Domain.AbpDddDomainModule
2022-08-25 09:13:22.921 G - Volo.Abp.Auditing.AbpAuditingModule
2022-08-25 09:13:22.921 G - Volo.Abp.Data.AbpDataModule
2022-08-25 09:13:22.922 G - Volo.Abp.ObjectExtending.AbpObjectExtendingModule
2022-08-25 09:13:22.922 G - Volo.Abp.Localization.AbpLocalizationAbstractionsModule
2022-08-25 09:13:22.923 G - Volo.Abp.Validation.AbpValidationAbstractionsModule
2022-08-25 09:13:22.923 G - Volo.Abp.Uow.AbpUnitOfWorkModule
2022-08-25 09:13:22.924 G - Volo.Abp.EventBus.Abstractions.AbpEventBusAbstractionsModule
2022-08-25 09:13:22.924 G - Volo.Abp.Json.AbpJsonModule
2022-08-25 09:13:22.925 G - Volo.Abp.Timing.AbpTimingModule
2022-08-25 09:13:22.925 G - Volo.Abp.Localization.AbpLocalizationModule
2022-08-25 09:13:22.926 G - Volo.Abp.VirtualFileSystem.AbpVirtualFileSystemModule
2022-08-25 09:13:22.926 G - Volo.Abp.Settings.AbpSettingsModule
2022-08-25 09:13:22.926 G - Volo.Abp.Security.AbpSecurityModule
2022-08-25 09:13:22.928 G - Volo.Abp.MultiTenancy.AbpMultiTenancyModule
2022-08-25 09:13:22.928 G - Volo.Abp.Threading.AbpThreadingModule
2022-08-25 09:13:22.929 G - Volo.Abp.EventBus.AbpEventBusModule
2022-08-25 09:13:22.929 G - Volo.Abp.Guids.AbpGuidsModule
2022-08-25 09:13:22.930 G - Volo.Abp.ObjectMapping.AbpObjectMappingModule
2022-08-25 09:13:22.930 G - Volo.Abp.ExceptionHandling.AbpExceptionHandlingModule
2022-08-25 09:13:22.931 G - Volo.Abp.Specifications.AbpSpecificationsModule
2022-08-25 09:13:22.931 G - Win.Sfs.SettleAccount.SettleAccountDomainSharedModule
2022-08-25 09:13:22.932 G - Volo.Abp.Validation.AbpValidationModule
2022-08-25 09:13:22.932 G - Win.Sfs.SettleAccount.SettleAccountApplicationContractsModule
2022-08-25 09:13:22.933 G - Volo.Abp.Application.AbpDddApplicationContractsModule
2022-08-25 09:13:22.933 G - Volo.Abp.Authorization.AbpAuthorizationModule
2022-08-25 09:13:22.934 G - Volo.Abp.Authorization.AbpAuthorizationAbstractionsModule
2022-08-25 09:13:22.935 G - Volo.Abp.AutoMapper.AbpAutoMapperModule
2022-08-25 09:13:22.935 G - Volo.Abp.Dapper.AbpDapperModule
2022-08-25 09:13:22.936 G - Volo.Abp.EntityFrameworkCore.AbpEntityFrameworkCoreModule
2022-08-25 09:13:22.936 G - Win.Abp.Snowflakes.AbpSnowflakeGeneratorModule
2022-08-25 09:13:22.937 G - Volo.Abp.Http.Client.IdentityModel.AbpHttpClientIdentityModelModule
2022-08-25 09:13:22.938 G - Volo.Abp.Http.Client.AbpHttpClientModule
2022-08-25 09:13:22.938 G - Volo.Abp.Http.AbpHttpModule
2022-08-25 09:13:22.939 G - Volo.Abp.Http.AbpHttpAbstractionsModule
2022-08-25 09:13:22.940 G - Volo.Abp.Minify.AbpMinifyModule
2022-08-25 09:13:22.940 G - Volo.Abp.Castle.AbpCastleCoreModule
2022-08-25 09:13:22.941 G - Volo.Abp.IdentityModel.AbpIdentityModelModule
2022-08-25 09:13:22.941 G - Volo.Abp.Caching.AbpCachingModule
2022-08-25 09:13:22.942 G - Volo.Abp.Serialization.AbpSerializationModule
2022-08-25 09:13:22.942 G - Volo.Abp.Identity.AbpIdentityHttpApiClientModule
2022-08-25 09:13:22.944 G - Volo.Abp.Identity.AbpIdentityApplicationContractsModule
2022-08-25 09:13:22.946 G - Volo.Abp.Identity.AbpIdentityDomainSharedModule
2022-08-25 09:13:22.946 G - Volo.Abp.Users.AbpUsersDomainSharedModule
2022-08-25 09:13:22.947 G - Volo.Abp.Features.AbpFeaturesModule
2022-08-25 09:13:22.947 G - Volo.Abp.Users.AbpUsersAbstractionModule
2022-08-25 09:13:22.948 G - Volo.Abp.Application.AbpDddApplicationModule
2022-08-25 09:13:22.948 G - Volo.Abp.GlobalFeatures.AbpGlobalFeaturesModule
2022-08-25 09:13:22.949 G - Volo.Abp.PermissionManagement.AbpPermissionManagementApplicationContractsModule
2022-08-25 09:13:22.950 G - Volo.Abp.PermissionManagement.AbpPermissionManagementDomainSharedModule
2022-08-25 09:13:22.950 G - Volo.Abp.AspNetCore.Mvc.AbpAspNetCoreMvcModule
2022-08-25 09:13:22.951 G - Volo.Abp.AspNetCore.AbpAspNetCoreModule
2022-08-25 09:13:22.951 G - Volo.Abp.ApiVersioning.AbpApiVersioningAbstractionsModule
2022-08-25 09:13:22.952 G - Volo.Abp.AspNetCore.Mvc.AbpAspNetCoreMvcContractsModule
2022-08-25 09:13:22.952 G - Volo.Abp.UI.Navigation.AbpUiNavigationModule
2022-08-25 09:13:22.953 G - Volo.Abp.UI.AbpUiModule
2022-08-25 09:13:22.954 G - Win.Sfs.SettleAccount.SettleAccountEntityFrameworkCoreModule
2022-08-25 09:13:22.954 G - Volo.Abp.PermissionManagement.EntityFrameworkCore.AbpPermissionManagementEntityFrameworkCoreModule
2022-08-25 09:13:22.955 G - Volo.Abp.PermissionManagement.AbpPermissionManagementDomainModule
2022-08-25 09:13:22.956 G - Volo.Abp.SettingManagement.EntityFrameworkCore.AbpSettingManagementEntityFrameworkCoreModule
2022-08-25 09:13:22.956 G - Volo.Abp.SettingManagement.AbpSettingManagementDomainModule
2022-08-25 09:13:22.957 G - Volo.Abp.SettingManagement.AbpSettingManagementDomainSharedModule
2022-08-25 09:13:22.957 G - Volo.Abp.AuditLogging.EntityFrameworkCore.AbpAuditLoggingEntityFrameworkCoreModule
2022-08-25 09:13:22.958 G - Volo.Abp.AuditLogging.AbpAuditLoggingDomainModule
2022-08-25 09:13:22.958 G - Volo.Abp.AuditLogging.AbpAuditLoggingDomainSharedModule
2022-08-25 09:13:22.960 G - Volo.Abp.TenantManagement.EntityFrameworkCore.AbpTenantManagementEntityFrameworkCoreModule
2022-08-25 09:13:22.961 G - Volo.Abp.TenantManagement.AbpTenantManagementDomainModule
2022-08-25 09:13:22.961 G - Volo.Abp.TenantManagement.AbpTenantManagementDomainSharedModule
2022-08-25 09:13:22.962 G - Win.Sfs.SettleAccount.SettleAccountHttpApiModule
2022-08-25 09:13:22.963 G - Volo.Abp.Autofac.AbpAutofacModule
2022-08-25 09:13:22.963 G - Volo.Abp.EntityFrameworkCore.SqlServer.AbpEntityFrameworkCoreSqlServerModule
2022-08-25 09:13:22.964 G - Volo.Abp.AspNetCore.Serilog.AbpAspNetCoreSerilogModule
2022-08-25 09:13:22.965 G - Volo.Abp.BlobStoring.AbpBlobStoringModule
2022-08-25 09:13:22.965 G - Volo.Abp.BlobStoring.FileSystem.AbpBlobStoringFileSystemModule
2022-08-25 09:13:22.966 G - Volo.Abp.BackgroundJobs.Hangfire.AbpBackgroundJobsHangfireModule
2022-08-25 09:13:22.966 G - Volo.Abp.BackgroundJobs.AbpBackgroundJobsAbstractionsModule
2022-08-25 09:13:22.967 G - Volo.Abp.Hangfire.AbpHangfireModule
2022-08-25 09:13:23.050 G Start installing Hangfire SQL objects...
2022-08-25 09:14:15.326 G An exception occurred while trying to perform the migration. Retrying...
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, Boolean applyTransientFaultHandling, String accessToken)
at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-08-25 09:14:15.334 G An exception occurred while trying to perform the migration. Retrying...
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-08-25 09:14:15.338 G An exception occurred while trying to perform the migration.
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-08-25 09:14:15.344 G Was unable to perform the Hangfire schema migration due to an exception. Ignore this message unless you've just installed or upgraded Hangfire.
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerStorage.Initialize()
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-08-25 09:14:15.358 G Starting Hangfire Server using job storage: 'SQL Server: 192.168.0.140@SettleAccountService'
2022-08-25 09:14:15.359 G Using the following options for SQL Server job storage: Queue poll interval: 00:00:15.
2022-08-25 09:14:15.359 G Using the following options for Hangfire Server:
Worker count: 20
Listening queues: 'default'
Shutdown timeout: 00:00:15
Schedule polling interval: 00:00:15
2022-08-25 09:14:15.386 G Execution BackgroundServerProcess is in the Failed state now due to an exception, execution will be retried no more than in 00:00:15
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerConnection.AnnounceServer(String serverId, ServerContext context)
at Hangfire.Server.BackgroundServerProcess.CreateServer(BackgroundServerContext context)
at Hangfire.Server.BackgroundServerProcess.Execute(Guid executionId, BackgroundExecution execution, CancellationToken stoppingToken, CancellationToken stoppedToken, CancellationToken shutdownToken)
at Hangfire.Server.BackgroundProcessingServer.RunServer(Guid executionId, Object state)
at Hangfire.Processing.BackgroundExecution.Run(Action`2 callback, Object state)
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-08-25 09:14:15.397 G Starting Hangfire Server using job storage: 'SQL Server: 192.168.0.140@SettleAccountService'
2022-08-25 09:14:15.398 G Using the following options for SQL Server job storage: Queue poll interval: 00:00:15.
2022-08-25 09:14:15.399 G Using the following options for Hangfire Server:
Worker count: 20
Listening queues: 'default'
Shutdown timeout: 00:00:15
Schedule polling interval: 00:00:15
2022-08-25 09:14:15.403 G Execution BackgroundServerProcess is in the Failed state now due to an exception, execution will be retried no more than in 00:00:15
System.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
---> System.ComponentModel.Win32Exception (53): 找不到网络路径。
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at Hangfire.SqlServer.SqlServerStorage.CreateAndOpenConnection()
at Hangfire.SqlServer.SqlServerStorage.UseConnection[T](DbConnection dedicatedConnection, Func`2 func)
at Hangfire.SqlServer.SqlServerStorage.UseConnection(DbConnection dedicatedConnection, Action`1 action)
at Hangfire.SqlServer.SqlServerConnection.AnnounceServer(String serverId, ServerContext context)
at Hangfire.Server.BackgroundServerProcess.CreateServer(BackgroundServerContext context)
at Hangfire.Server.BackgroundServerProcess.Execute(Guid executionId, BackgroundExecution execution, CancellationToken stoppingToken, CancellationToken stoppedToken, CancellationToken shutdownToken)
at Hangfire.Server.BackgroundProcessingServer.RunServer(Guid executionId, Object state)
at Hangfire.Processing.BackgroundExecution.Run(Action`2 callback, Object state)
ClientConnectionId:00000000-0000-0000-0000-000000000000
Error Number:53,State:0,Class:20
2022-08-25 09:14:17.028 G Entity Framework Core "5.0.8" initialized '"PermissionManagementDbContext"' using provider '"Microsoft.EntityFrameworkCore.SqlServer"' with options: "QuerySplittingBehavior=SplitQuery "
2022-08-25 09:14:17.049 G An error occurred using the connection to database '"ABP"' on server '"192.168.0.140"'.

15055
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Logs/log-20221012.txt

File diff suppressed because it is too large

11
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/Startup.cs

@ -1,8 +1,11 @@
using System.IO.Compression;
using System.Linq;
using System.Text.RegularExpressions; using System.Text.RegularExpressions;
using Coravel; using Coravel;
using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting; using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Mvc.ApplicationModels; using Microsoft.AspNetCore.Mvc.ApplicationModels;
using Microsoft.AspNetCore.ResponseCompression;
using Microsoft.AspNetCore.Routing; using Microsoft.AspNetCore.Routing;
using Microsoft.AspNetCore.Server.Kestrel.Core; using Microsoft.AspNetCore.Server.Kestrel.Core;
using Microsoft.AspNetCore.StaticFiles; using Microsoft.AspNetCore.StaticFiles;
@ -18,6 +21,13 @@ public class Startup
{ {
public void ConfigureServices(IServiceCollection services) public void ConfigureServices(IServiceCollection services)
{ {
services.Configure<GzipCompressionProviderOptions>(options => options.Level = CompressionLevel.Fastest);
services.AddResponseCompression(options =>
{
options.EnableForHttps = true;
options.Providers.Add<GzipCompressionProvider>();
options.MimeTypes = ResponseCompressionDefaults.MimeTypes.Concat(new[] { "image/svg+xml" });
});
services.AddScheduler(); services.AddScheduler();
services.AddSignalR(o => o.EnableDetailedErrors = true); services.AddSignalR(o => o.EnableDetailedErrors = true);
JobHostdService.AddService(services); JobHostdService.AddService(services);
@ -47,6 +57,7 @@ public class Startup
public void Configure(IApplicationBuilder app, IWebHostEnvironment env, ILoggerFactory loggerFactory) public void Configure(IApplicationBuilder app, IWebHostEnvironment env, ILoggerFactory loggerFactory)
{ {
app.UseResponseCompression();
app.UseRouting(); app.UseRouting();
app.UseEndpoints(endpoints => endpoints.MapHub<PageHub>("/api/hub")); app.UseEndpoints(endpoints => endpoints.MapHub<PageHub>("/api/hub"));
app.ApplicationServices.UseScheduler(scheduler => app.ApplicationServices.UseScheduler(scheduler =>

8
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/components/list/index.js

@ -261,7 +261,6 @@ export default {
</el-form-item> </el-form-item>
</el-form> </el-form>
</template> </template>
<template v-else-if="editFormMode==='import'"> <template v-else-if="editFormMode==='import'">
<app-form <app-form
mode="import" mode="import"
@ -427,7 +426,6 @@ export default {
const exportModel = ref(defaultExportModel); const exportModel = ref(defaultExportModel);
const defaultImportModel = config.import?.schema ? schemaToModel(config.import.schema) : {}; const defaultImportModel = config.import?.schema ? schemaToModel(config.import.schema) : {};
const importModel = ref(defaultImportModel); const importModel = ref(defaultImportModel);
const factories = ref([]); const factories = ref([]);
const versions = ref([]); const versions = ref([]);
const fileList = ref([]); const fileList = ref([]);
@ -535,9 +533,8 @@ export default {
if (item.meta.isTop) { if (item.meta.isTop) {
// 批量删除 // 批量删除
try { try {
await ElMessageBox.confirm("删除", "提示", { await ElMessageBox.confirm(format("确认删除选中的%s行数据吗?", rows.length), "提示", {
type: "warning", type: "warning",
message: format("确认删除选中的%s行数据吗?", rows.length),
}); });
const response = await request( const response = await request(
url, url,
@ -561,9 +558,8 @@ export default {
} else { } else {
// 单个删除 // 单个删除
try { try {
await ElMessageBox.confirm("删除", "提示", { await ElMessageBox.confirm(format("确认删除当前行数据吗?", rows[0]), "提示", {
type: "warning", type: "warning",
message: format("确认删除当前行数据吗?", rows[0]),
}); });
await request(url, null, { method: config.edit.deleteMethod }); await request(url, null, { method: config.edit.deleteMethod });
ElMessage({ ElMessage({

1
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/centralized-control.js

@ -122,7 +122,6 @@ export default function () {
table: { table: {
schema: schema, schema: schema,
}, },
edit: { edit: {
detailsUrl, detailsUrl,
createUrl, createUrl,

106
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/jis-bbac/input/bbac_se_detail_service.js

@ -1,51 +1,111 @@
import version from "../../version.js";
const schema = { const schema = {
title: "JIS发运数据", title: "JIS发运数据",
type: "object", type: "object",
properties: { properties: {
version, wmsBillNum: {
shippingDate: { title: "发货单号",
type: "string",
},
num: {
title: "单据编号",
type: "string",
},
billTime: {
title: "发货时间", title: "发货时间",
type: "string", type: "string",
input: "datetime", input: "datetime",
}, },
wmsBillNum: { oper: {
title: "发运单号", title: "发货人",
type: "string",
},
orderNum: {
title: "排序单号",
type: "string",
},
seq: {
title: "订单序号",
type: "string",
},
realCode: {
title: "实际生产码",
type: "string",
},
vinCode: {
title: "订单生产码",
type: "string",
},
codeType: {
title: "生产码类型",
type: "string",
},
realPartCode: {
title: "实际零件号",
type: "string", type: "string",
}, },
lu: { partCode: {
title: "零件号", title: "零件号",
type: "string", type: "string",
}, },
pn: { batch: {
title: "生产号", title: "批次",
type: "string", type: "string",
}, },
keyCode: { mesConfigCode: {
title: "组合键值(LU+PN)", title: "MES配置码",
type: "string", type: "string",
}, },
qty: { fromLoc: {
title: "数量", title: "来源库位",
type: "number", type: "string",
}, },
seqNumber: { toLoc: {
title: "日顺序号", title: "目标库位",
type: "string", type: "string",
}, },
assemblyCode: { refVinCode: {
title: "小总成号", title: "参照订单生产码",
type: "string", type: "string",
}, },
injectionCode: { billCharacter: {
title: "注塑码", title: "单据性质",
type: "string", type: "string",
}, },
beginDate: { refBillNum: {
title: "订单时间", title: "发货关联单号",
type: "string",
},
erpToLoc: {
title: "Erp目标库位",
type: "string",
},
origiCode: {
title: "原生产码",
type: "string",
},
remark: {
title: "备注",
type: "string",
},
uniqueCode: {
title: "塑件唯一码",
type: "string",
},
pjsNum: {
title: "PJS顺序号",
type: "string",
},
matchNumber: {
title: "虚拟小总成",
type: "string",
},
deliverCode: {
title: "发货条码",
type: "string",
},
position: {
title: "客户位置",
type: "string", type: "string",
input: "datetime",
}, },
}, },
}; };

104
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/jis-hbpo/input/hbpo_se_detail_service.js

@ -4,48 +4,110 @@ const schema = {
title: "JIS发运数据", title: "JIS发运数据",
type: "object", type: "object",
properties: { properties: {
version, wmsBillNum: {
shippingDate: { title: "发货单号",
type: "string",
},
num: {
title: "单据编号",
type: "string",
},
billTime: {
title: "发货时间", title: "发货时间",
type: "string", type: "string",
input: "datetime", input: "datetime",
}, },
wmsBillNum: { oper: {
title: "发运单号", title: "发货人",
type: "string",
},
orderNum: {
title: "排序单号",
type: "string",
},
seq: {
title: "订单序号",
type: "string",
},
realCode: {
title: "实际生产码",
type: "string",
},
vinCode: {
title: "订单生产码",
type: "string",
},
codeType: {
title: "生产码类型",
type: "string",
},
realPartCode: {
title: "实际零件号",
type: "string", type: "string",
}, },
lu: { partCode: {
title: "零件号", title: "零件号",
type: "string", type: "string",
}, },
pn: { batch: {
title: "生产号", title: "批次",
type: "string", type: "string",
}, },
keyCode: { mesConfigCode: {
title: "组合键值(LU+PN)", title: "MES配置码",
type: "string", type: "string",
}, },
qty: { fromLoc: {
title: "数量", title: "来源库位",
type: "number", type: "string",
}, },
seqNumber: { toLoc: {
title: "日顺序号", title: "目标库位",
type: "string", type: "string",
}, },
assemblyCode: { refVinCode: {
title: "小总成号", title: "参照订单生产码",
type: "string", type: "string",
}, },
injectionCode: { billCharacter: {
title: "注塑码", title: "单据性质",
type: "string", type: "string",
}, },
beginDate: { refBillNum: {
title: "订单时间", title: "发货关联单号",
type: "string",
},
erpToLoc: {
title: "Erp目标库位",
type: "string",
},
origiCode: {
title: "原生产码",
type: "string",
},
remark: {
title: "备注",
type: "string",
},
uniqueCode: {
title: "塑件唯一码",
type: "string",
},
pjsNum: {
title: "PJS顺序号",
type: "string",
},
matchNumber: {
title: "虚拟小总成",
type: "string",
},
deliverCode: {
title: "发货条码",
type: "string",
},
position: {
title: "客户位置",
type: "string", type: "string",
input: "datetime",
}, },
}, },
}; };

6
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/material-relationship.js

@ -3,15 +3,15 @@ const schema = {
type: "object", type: "object",
properties: { properties: {
erpMaterialCode: { erpMaterialCode: {
title: "厂内零件号", title: "厂内物料号",
type: "string", type: "string",
}, },
settleMaterialCode: { settleMaterialCode: {
title: "客户零件号", title: "客户物料号",
type: "string", type: "string",
}, },
materialDesc: { materialDesc: {
title: "物料描述", title: "厂内物料描述",
type: "string", type: "string",
}, },
}, },

10
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/material.js

@ -3,11 +3,11 @@ const schema = {
type: "object", type: "object",
properties: { properties: {
factory: { factory: {
title: "客户物料号", title: "工厂",
type: "string", type: "string",
}, },
materialCode: { materialCode: {
title: "厂内物料号", title: "物料号",
type: "string", type: "string",
}, },
materialDesc: { materialDesc: {
@ -19,7 +19,11 @@ const schema = {
type: "string", type: "string",
}, },
estimateType: { estimateType: {
title: "产品类型", title: "估价类",
type: "string",
},
estimateTypeDesc: {
title: "估价类描述",
type: "string", type: "string",
}, },
}, },

2
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/price-list-app-service-bj.js

@ -15,7 +15,7 @@ const schema = {
type: "DateTime", type: "DateTime",
}, },
endDate: { endDate: {
title: "结时间", title: "结时间",
type: "DateTime", type: "DateTime",
}, },
clientCode: { clientCode: {

13
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/price-list.js

@ -18,7 +18,7 @@ const schema = {
input: "datetime", input: "datetime",
}, },
endTime: { endTime: {
title: "结时间", title: "结时间",
type: "string", type: "string",
input: "datetime", input: "datetime",
}, },
@ -26,14 +26,13 @@ const schema = {
title: "客户编码", title: "客户编码",
type: "string", type: "string",
}, },
businessType: { date: {
title: "业务类别", title: "合同签订时间",
type: "string", type: "string",
input: "select", input: "datetime",
options: businessTypes,
}, },
version: { contractNo: {
title: "版本", title: "合同号",
type: "string", type: "string",
}, },
}, },

85
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/pub_se_detail_service.js

@ -1,51 +1,80 @@
import version from "./version.js";
import state from "./state.js";
const schema = { const schema = {
title: "结算数据", title: "结算数据",
type: "object", type: "object",
properties: { properties: {
version,
state,
shippingDate: {
title: "发货时间",
type: "DateTime",
},
wmsBillNum: { wmsBillNum: {
title: "发运单号", title: "发运单号",
type: "string", type: "string",
}, },
lu: { billTime: {
title: "发货时间",
type: "string",
input: "datetime",
},
partCode: {
title: "零件号", title: "零件号",
type: "string", type: "string",
}, },
pn: { batch: {
title: "生产号", title: "批次",
type: "string",
},
oper: {
title: "发货人",
type: "string", type: "string",
}, },
keyCode: { dnBillNum: {
title: "组合键值(LU+PN)", title: "DN单据号",
type: "string", type: "string",
}, },
qty: { dnBillTime: {
title: "数量", title: "DN单据时间",
type: "decimal", type: "string",
input: "datetime",
}, },
seqNumber: { dnOper: {
title: "日顺序号", title: "DN单添加人",
type: "string", type: "string",
}, },
assemblyCode: { deliveryIndex: {
title: "小总成号", title: "交付索引",
type: "string", type: "string",
}, },
injectionCode: { custId: {
title: "注塑码", title: "客户",
type: "string", type: "string",
}, },
beginDate: { deliveryHose: {
title: "订单时间", title: "发货仓库",
type: "DateTime", type: "string",
},
fromLocCode: {
title: "来源库位",
type: "string",
},
fromHose: {
title: "来源仓库",
type: "string",
},
fromErpLocCode: {
title: "来源ERP库存",
type: "string",
},
toLocCode: {
title: "目标库位",
type: "string",
},
toErpLocCode: {
title: "目标Erp库位",
type: "string",
},
toHose: {
title: "目标仓库",
type: "string",
},
remark: {
title: "备注",
type: "string",
}, },
}, },
}; };
@ -107,6 +136,10 @@ export default function () {
sorting: { sorting: {
hidden: true, hidden: true,
}, },
businessType: {
hidden: true,
default: 0,
},
}, },
}, },
}, },

1
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/purchase_price_service.js

@ -78,7 +78,6 @@ export default function () {
table: { table: {
schema: schema, schema: schema,
}, },
edit: { edit: {
importUrl, importUrl,
exportUrl, exportUrl,

9
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/tb_re-parts-relationship_service.js

@ -1,3 +1,5 @@
import businessTypes from "./business-type.js";
const schema = { const schema = {
title: "客户替换件关系", title: "客户替换件关系",
type: "object", type: "object",
@ -10,13 +12,10 @@ const schema = {
title: "替换客户零件号", title: "替换客户零件号",
type: "string", type: "string",
}, },
clientCode: {
title: "客户编码",
type: "string",
},
businessType: { businessType: {
title: "业务类型", title: "业务类型",
type: "EnumBusinessType", input: "select",
options: businessTypes,
}, },
}, },
}; };

44
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/router/business.js

@ -108,15 +108,6 @@ export default [
isTop: true, isTop: true,
}, },
}, },
// {
// path: "delete",
// meta: {
// type: "button",
// title: "删除",
// icon: "file",
// isTop: true,
// },
// },
{ {
path: "synchronous", path: "synchronous",
meta: { meta: {
@ -192,7 +183,6 @@ export default [
type: "page", type: "page",
title: "EDI与发运数据对比", title: "EDI与发运数据对比",
icon: "file", icon: "file",
enumBusinessType: "BBAC",
}, },
children: [ children: [
{ {
@ -238,7 +228,6 @@ export default [
type: "page", type: "page",
title: "EDI、发运与结算比对", title: "EDI、发运与结算比对",
icon: "file", icon: "file",
enumBusinessType: "BBAC",
}, },
children: [ children: [
{ {
@ -644,15 +633,6 @@ export default [
isTop: true, isTop: true,
}, },
}, },
// {
// path: "delete",
// meta: {
// type: "button",
// title: "删除",
// icon: "file",
// isTop: true,
// },
// },
{ {
path: "synchronous", path: "synchronous",
meta: { meta: {
@ -728,7 +708,6 @@ export default [
type: "page", type: "page",
title: "EDI与发运数据对比", title: "EDI与发运数据对比",
icon: "file", icon: "file",
enumBusinessType: "HBPO",
}, },
children: [ children: [
{ {
@ -774,7 +753,6 @@ export default [
type: "page", type: "page",
title: "EDI、发运与结算比对", title: "EDI、发运与结算比对",
icon: "file", icon: "file",
enumBusinessType: "HBPO",
}, },
children: [ children: [
{ {
@ -1071,7 +1049,6 @@ export default [
}, },
], ],
}, },
{ {
path: "jit", path: "jit",
meta: { meta: {
@ -1646,7 +1623,6 @@ export default [
}, },
], ],
}, },
{ {
path: "bj", path: "bj",
meta: { meta: {
@ -1756,15 +1732,6 @@ export default [
isTop: true, isTop: true,
}, },
}, },
// {
// path: "delete",
// meta: {
// type: "button",
// title: "删除",
// icon: "file",
// isTop: true,
// },
// },
{ {
path: "synchronous", path: "synchronous",
meta: { meta: {
@ -2079,7 +2046,6 @@ export default [
}, },
], ],
}, },
{ {
path: "in", path: "in",
meta: { meta: {
@ -2189,15 +2155,6 @@ export default [
isTop: true, isTop: true,
}, },
}, },
// {
// path: "delete",
// meta: {
// type: "button",
// title: "删除",
// icon: "file",
// isTop: true,
// },
// },
{ {
path: "synchronous", path: "synchronous",
meta: { meta: {
@ -2512,7 +2469,6 @@ export default [
}, },
], ],
}, },
{ {
path: "invoice", path: "invoice",
meta: { meta: {

9
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/base-data/centralized-control.js

@ -15,10 +15,13 @@ export default {
const onCommand = async (item, rows, load) => { const onCommand = async (item, rows, load) => {
if (item.path === "open-version" || item.path === "closed-version") { if (item.path === "open-version" || item.path === "closed-version") {
try { try {
await ElMessageBox.confirm("删除", "提示", { await ElMessageBox.confirm(
format(`确认${item.path === "open-version" ? "启用" : "停用"}选中的%s行数据吗?`, rows.length),
"提示",
{
type: "warning", type: "warning",
message: format(`确认${item.path === "open-version" ? "启用" : "停用"}选中的%s行数据吗?`, rows.length), }
}); );
const url = `${config.baseUrl}/${item.path}`; const url = `${config.baseUrl}/${item.path}`;
await request( await request(
url, url,

24
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/base-data/user.js

@ -3,7 +3,7 @@ import html from "html";
import useConfig from "../../models/user.js"; import useConfig from "../../models/user.js";
import request from "../../request/index.js"; import request from "../../request/index.js";
import { format } from "../../utils/index.js"; import { format } from "../../utils/index.js";
import { ElMessage } from "element-plus"; import { ElMessage, ElMessageBox } from "element-plus";
export default { export default {
components: { AppList }, components: { AppList },
@ -17,11 +17,31 @@ export default {
if (item.path === "%s/reset-password") { if (item.path === "%s/reset-password") {
const url = format(item.path, rows[0].id); const url = format(item.path, rows[0].id);
await request(`base/user/${url}`, null, { method: item.meta.method }); await request(`base/user/${url}`, null, { method: item.meta.method });
try {
await ElMessageBox.confirm(format("是否重置用户%s密码", rows[0].userName), "提示", {
type: "warning",
});
await ElMessage({
type: "info",
message: "密码已经成功重置为123456",
});
const url = `${config.baseUrl}/${item.path}`;
await request(
url,
rows.map((o) => o.id),
{ method: "POST" }
);
console.log(context);
await load();
} catch (error) {
if (error === "cancel") {
ElMessage({ ElMessage({
type: "info", type: "info",
message: format("用户%s的密码已经成功重置为123456", rows[0].userName), message: "操作取消",
}); });
} }
}
}
}; };
return { config, onCommand }; return { config, onCommand };
}, },

1
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/bj/input/bj_pub_se_detail_service.js

@ -10,6 +10,7 @@ export default {
const onCommand = async (item, rows) => { const onCommand = async (item, rows) => {
console.log(item.path, item, rows); console.log(item.path, item, rows);
}; };
config.query.schema.properties.businessType.default = 7;
return { config, onCommand }; return { config, onCommand };
}, },
}; };

4
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/home.js

@ -1,7 +1,5 @@
import html from "html"; import html from "html";
import Md from "../components/markdown/index.js";
export default { export default {
components: { Md }, template: html`<a href="../assets/导入模版.zip" target="blank">导入模板下载</a>`,
template: html`<md name="home" />`,
}; };

1
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/in/input/in_pub_se_detail_service.js

@ -10,6 +10,7 @@ export default {
const onCommand = async (item, rows) => { const onCommand = async (item, rows) => {
console.log(item.path, item, rows); console.log(item.path, item, rows);
}; };
config.query.schema.properties.businessType.default = 8;
return { config, onCommand }; return { config, onCommand };
}, },
}; };

108
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/invoice/invoice_map_group.js

@ -16,46 +16,27 @@ export default {
<el-tab-pane label="invoicE_WAIT_DETAIL" v-if="model.invoicE_WAIT_DETAIL.length"> <el-tab-pane label="invoicE_WAIT_DETAIL" v-if="model.invoicE_WAIT_DETAIL.length">
<el-auto-resizer> <el-auto-resizer>
<template #default="{ height, width }"> <template #default="{ height, width }">
<el-table-v2 <el-table-v2 :data="model.invoicE_WAIT_DETAIL" :columns="columns1" :width="width" :height="height" />
fixed
:data="model.invoicE_WAIT_DETAIL"
:columns="columns1"
:width="width"
:height="height"
/>
</template> </template>
</el-auto-resizer> </el-auto-resizer>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="invoicE_MAP_GROUP" v-if="model.invoicE_MAP_GROUP.length"> <el-tab-pane label="invoicE_MAP_GROUP" v-if="model.invoicE_MAP_GROUP.length">
<el-auto-resizer> <el-auto-resizer>
<template #default="{ height, width }"> <template #default="{ height, width }">
<el-table-v2 <el-table-v2 :data="model.invoicE_MAP_GROUP" :columns="columns2" :width="width" :height="height" />
fixed
:data="model.invoicE_MAP_GROUP"
:columns="columns2"
:width="width"
:height="height"
/>
</template> </template>
</el-auto-resizer> </el-auto-resizer>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="invoicE_NOT_SETTLE" v-if="model.invoicE_NOT_SETTLE.length"> <el-tab-pane label="invoicE_NOT_SETTLE" v-if="model.invoicE_NOT_SETTLE.length">
<el-auto-resizer> <el-auto-resizer>
<template #default="{ height, width }"> <template #default="{ height, width }">
<el-table-v2 <el-table-v2 :data="model.invoicE_NOT_SETTLE" :columns="columns3" :width="width" :height="height" />
fixed
:data="model.invoicE_NOT_SETTLE"
:columns="columns3"
:width="width"
:height="height"
/>
</template> </template>
</el-auto-resizer> </el-auto-resizer>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
</el-col> </el-col>
</el-row> </el-row>
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer">
<el-button type="primary" @click="drawer=false"> {{$t('confirm')}} </el-button> <el-button type="primary" @click="drawer=false"> {{$t('confirm')}} </el-button>
@ -76,7 +57,28 @@ export default {
const drawer = ref(false); const drawer = ref(false);
const loading = ref(false); const loading = ref(false);
const model = ref({ const model = ref({
invoicE_WAIT_DETAIL: [{ version: "version" }], invoicE_WAIT_DETAIL: [
{
version: 11111,
invbillNum: "INV230725142640-001",
inGroupNum: "INV2023",
lu: "lu",
price: 11111,
qty: 11111,
amt: 11111,
bussiessType: "bussiessType",
},
{
version: 22222,
invbillNum: "INV230725142640-002",
inGroupNum: "INV2023",
lu: "lu",
price: 22222,
qty: 22222,
amt: 22222,
bussiessType: "bussiessType",
},
],
invoicE_MAP_GROUP: [{ version: "version" }], invoicE_MAP_GROUP: [{ version: "version" }],
invoicE_NOT_SETTLE: [{ version: "version" }], invoicE_NOT_SETTLE: [{ version: "version" }],
}); });
@ -96,18 +98,78 @@ export default {
dataKey: "version", dataKey: "version",
title: "期间", title: "期间",
}, },
{
dataKey: "invbillNum",
title: "发票号",
},
{
dataKey: "invGroupNum",
title: "发票分组号",
},
{
dataKey: "lu",
title: "零件号",
},
{
dataKey: "price",
title: "单价",
},
{
dataKey: "qty",
title: "数量",
},
{
dataKey: "amt",
title: "金额",
},
{
dataKey: "bussiessType",
title: "业务分类",
},
]; ];
const columns2 = [ const columns2 = [
{ {
dataKey: "version", dataKey: "version",
title: "期间", title: "期间",
}, },
{
dataKey: "invbillNum",
title: "发票号",
},
{
dataKey: "inGroupNum",
title: "发票分组号",
},
{
dataKey: "settleGroupNum",
title: "结算分组号",
},
{
dataKey: "amt",
title: "金额",
},
]; ];
const columns3 = [ const columns3 = [
{ {
dataKey: "version", dataKey: "version",
title: "期间", title: "期间",
}, },
{
dataKey: "invGroupNum",
title: "发票分组号",
},
{
dataKey: "settleGroupNum",
title: "结算分组号",
},
{
dataKey: "lu",
title: "可结算分组号",
},
{
dataKey: "lu1",
title: "不可结算分组号",
},
]; ];
return { config, onCommand, drawer, loading, model, columns1, columns2, columns3 }; return { config, onCommand, drawer, loading, model, columns1, columns2, columns3 };
}, },

1
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/jit/input/bbac_jit_pub_se_detail_service.js

@ -10,6 +10,7 @@ export default {
const onCommand = async (item, rows) => { const onCommand = async (item, rows) => {
console.log(item.path, item, rows); console.log(item.path, item, rows);
}; };
config.query.schema.properties.businessType.default = 3;
return { config, onCommand }; return { config, onCommand };
}, },
}; };

1
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/jit/input/hbpo_jit_pub_se_detail_service.js

@ -10,6 +10,7 @@ export default {
const onCommand = async (item, rows) => { const onCommand = async (item, rows) => {
console.log(item.path, item, rows); console.log(item.path, item, rows);
}; };
config.query.schema.properties.businessType.default = 4;
return { config, onCommand }; return { config, onCommand };
}, },
}; };

28
code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/PUB_SA_DTO.cs

@ -1,4 +1,5 @@
using Magicodes.ExporterAndImporter.Core; using Magicodes.ExporterAndImporter.Core;
using Microsoft.AspNetCore.Http;
using System; using System;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using Volo.Abp.Application.Dtos; using Volo.Abp.Application.Dtos;
@ -29,6 +30,33 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos
public string State { get; set; } public string State { get; set; }
} }
/// <summary>
/// 查询
/// </summary>
public class PUB_SARequestDto : RequestDto
{
/// <summary>
/// 业务类别
/// </summary>
public EnumBusinessType BusinessType { get; set; }
}
/// <summary>
/// 导入请求
/// </summary>
public class PUB_SAImportRequestDto
{
/// <summary>
/// 文件
/// </summary>
public IFormFileCollection Files { get; set; }
/// <summary>
/// 是否是备件
/// </summary>
public EnumBusinessType BusinessType { get; set; }
}
/// <summary> /// <summary>
/// 导入 /// 导入
/// </summary> /// </summary>

6
code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/MaterialRelationship/MaterialRelationshipDtoBase.cs

@ -91,12 +91,6 @@ namespace Win.Sfs.SettleAccount.MaterialRelationships
/// </summary> /// </summary>
[Display(Name = "客户物料号")] [Display(Name = "客户物料号")]
public string SettleMaterialCode { get; set; } public string SettleMaterialCode { get; set; }
/// <summary>
/// 备注
/// </summary>
[Display(Name = "备注")]
public string Remark { get; set; }
} }
/// <summary> /// <summary>

36
code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/Materials/MaterialDtoBase.cs

@ -5,6 +5,7 @@ using System.ComponentModel.DataAnnotations;
using System.Linq; using System.Linq;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using Volo.Abp.Application.Dtos;
using Win.Sfs.Shared; using Win.Sfs.Shared;
using Win.Sfs.Shared.Constant; using Win.Sfs.Shared.Constant;
using Win.Sfs.Shared.DtoBase; using Win.Sfs.Shared.DtoBase;
@ -276,37 +277,24 @@ namespace Win.Sfs.SettleAccount.Entities.Materials
} }
public class MaterialDto : AuditedEntityDtoBase<Guid>, IBranch<Guid>
{
/// <summary> /// <summary>
///工厂 /// 列表
/// </summary> /// </summary>
public virtual string Factory { set; get; } public class MaterialDto : AuditedEntityDto<Guid>
/// <summary>
/// 物料编码
/// </summary>
public virtual string MaterialCode { set; get; }
/// <summary>
///物料描述
/// </summary>
public virtual string MaterialDesc
{ {
set; get;
}
/// <summary>
/// 基础单位
/// </summary>
public virtual string Unit { set; get; }
/// <summary> /// <summary>
/// 估价类 /// 厂内物料号
/// </summary> /// </summary>
public virtual string EstimateType { set; get; } [Display(Name = "厂内物料号")]
public string MaterialCode { set; get; }
/// <summary> /// <summary>
/// 估价类描述 /// 厂内物料描述
/// </summary> /// </summary>
public virtual string EstimateTypeDesc { set; get; } [Display(Name = "厂内物料描述")]
public Guid BranchId { get; set ; } public string MaterialDesc { set; get; }
} }
[ImportProject(Name = SettleAccountModuleName.Material)] [ImportProject(Name = SettleAccountModuleName.Material)]
public class MaterialImportDto public class MaterialImportDto
{ {
@ -369,12 +357,14 @@ namespace Win.Sfs.SettleAccount.Entities.Materials
/// <summary> /// <summary>
/// 厂内物料号 /// 厂内物料号
/// </summary> /// </summary>
[Display(Name = "厂内物料号")]
[ExporterHeader(DisplayName = "厂内物料号")] [ExporterHeader(DisplayName = "厂内物料号")]
public string MaterialCode { set; get; } public string MaterialCode { set; get; }
/// <summary> /// <summary>
/// 厂内物料描述 /// 厂内物料描述
/// </summary> /// </summary>
[Display(Name = "厂内物料描述")]
[ExporterHeader(DisplayName = "厂内物料描述")] [ExporterHeader(DisplayName = "厂内物料描述")]
public string MaterialDesc { set; get; } public string MaterialDesc { set; get; }
} }

48
code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/Prices/PriceListDtoBase.cs

@ -12,40 +12,46 @@ namespace Win.Sfs.SettleAccount.Entities.Prices;
public class PriceListDto : EntityDto<Guid> public class PriceListDto : EntityDto<Guid>
{ {
/// <summary> /// <summary>
/// 版本 /// 零件号
/// </summary> /// </summary>
[Display(Name = "版本")] [Display(Name = "零件号")]
public string Version { set; get; } public string LU { get; set; }
/// <summary>
/// 价格
/// </summary>
[Display(Name = "价格")]
public Decimal Price { set; get; }
/// <summary> /// <summary>
/// 开始时间 /// 开始时间
/// </summary> /// </summary>
[Display(Name = "开始时间")] [Display(Name = "开始时间")]
public DateTime BeginDate { get; set; } public DateTime BeginTime { set; get; }
/// <summary> /// <summary>
///结算时间 /// 结束时间
/// </summary> /// </summary>
[Display(Name = "结算时间")] [Display(Name = "结束时间")]
public DateTime EndDate { get; set; } public DateTime EndTime { set; get; }
/// <summary> /// <summary>
///价格 /// 客户编码
/// </summary> /// </summary>
[Display(Name = "价格")] [Display(Name = "客户编码")]
public decimal Price { get; set; } public string ClientCode { get; set; }
/// <summary> /// <summary>
///物料编号 /// 合同签订时间
/// </summary> /// </summary>
[Display(Name = "物料编号")] [Display(Name = "合同签订时间")]
public string MaterialCode { get; set; } public DateTime Date { get; set; }
/// <summary> /// <summary>
///价格类型 /// 合同号
/// </summary> /// </summary>
[Display(Name = "价格类型")] [Display(Name = "合同号")]
public int Type { get; set; } public string ContractNo { get; set; }
public Guid ParentId { set; get; }
[Display(Name = "客户")]
public string CustomerCode { get; set; }
} }
/// <summary> /// <summary>

163
code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SA_SERVICE.cs

@ -6,6 +6,7 @@ using System.Threading.Tasks;
using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using SettleAccount.Domain.BQ; using SettleAccount.Domain.BQ;
using Volo.Abp; using Volo.Abp;
using Volo.Abp.Application.Dtos; using Volo.Abp.Application.Dtos;
@ -20,10 +21,11 @@ using Win.Sfs.SettleAccount.Entities.Prices;
using Win.Sfs.SettleAccount.ExcelImporter; using Win.Sfs.SettleAccount.ExcelImporter;
using Win.Sfs.SettleAccount.ExportReports; using Win.Sfs.SettleAccount.ExportReports;
using Win.Sfs.SettleAccount.MaterialRelationships; using Win.Sfs.SettleAccount.MaterialRelationships;
using Win.Sfs.Shared.Filter;
using Win.Sfs.Shared.RepositoryBase; using Win.Sfs.Shared.RepositoryBase;
namespace Win.Sfs.SettleAccount.Entities.BQ namespace Win.Sfs.SettleAccount.Entities.BQ;
{
/// <summary> /// <summary>
/// PUB结算 /// PUB结算
/// </summary> /// </summary>
@ -103,9 +105,9 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
/// 导入 /// 导入
/// </summary> /// </summary>
[HttpPost] [HttpPost]
public async Task<string> ImportByBusinessTypeAsync([FromForm] IFormFileCollection files, EnumBusinessType businessType) public async Task<string> ImportByBusinessTypeAsync([FromForm] PUB_SAImportRequestDto pubSaImportRequestDto)
{ {
return await ImportAsync(files, businessType); return await ImportAsync(pubSaImportRequestDto.Files, pubSaImportRequestDto.BusinessType);
} }
#endregion #endregion
@ -114,8 +116,9 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
/// 获取列表 /// 获取列表
/// </summary> /// </summary>
[HttpPost] [HttpPost]
public async Task<PagedResultDto<PUB_SA_DTO>> GetListAsync(RequestDto input) public async Task<PagedResultDto<PUB_SA_DTO>> GetListAsync(PUB_SARequestDto input)
{ {
input.Filters.Add(new FilterCondition("BusinessType", input.BusinessType.ToString(), EnumFilterAction.Equal, EnumFilterLogic.And));
var entities = await _repository.GetListByFilterAsync(input.Filters, input.Sorting, input.MaxResultCount, input.SkipCount, true); var entities = await _repository.GetListByFilterAsync(input.Filters, input.Sorting, input.MaxResultCount, input.SkipCount, true);
var totalCount = await _repository.GetCountByFilterAsync(input.Filters); var totalCount = await _repository.GetCountByFilterAsync(input.Filters);
var dtos = ObjectMapper.Map<List<PUB_SA>, List<PUB_SA_DTO>>(entities); var dtos = ObjectMapper.Map<List<PUB_SA>, List<PUB_SA_DTO>>(entities);
@ -129,52 +132,109 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
public async Task DeleteAsync(Guid id) public async Task DeleteAsync(Guid id)
{ {
//结算主表 //结算主表
PUB_SA pubSaDelEntity; List<PUB_SA> pubSas = new List<PUB_SA>();
//结算明细 //结算明细
List<PUB_SA_DETAIL> pubSaDetailDelEntitys; List<PUB_SA_DETAIL> pubSaDetails = new List<PUB_SA_DETAIL>();
//可结算主表 //可结算主表
List<PUB_CAN_SA> pubCanSaDelEntitys; List<PUB_CAN_SA> pubCanSas = new List<PUB_CAN_SA>();
//可结算明细 //可结算明细
List<PUB_CAN_SA_DETAIL> pubCanSaDetailDelEntitys; List<PUB_CAN_SA_DETAIL> pubCanSaDetails = new List<PUB_CAN_SA_DETAIL>();
//不可结算 //不可结算
List<PUB_NOT_SA_DETAIL> pubNotSaDetailDelEntitys; List<PUB_NOT_SA_DETAIL> pubNotSaDetails = new List<PUB_NOT_SA_DETAIL>();
pubSaDelEntity = await _repository.FindAsync(id);
if (pubSaDelEntity == null) return;
//结算单据
string pubSaBillNum = pubSaDelEntity.BillNum;
try
{
var pubSaDelItems = await GetPubSaDelItemsAsync(id);
pubSas.AddRange(pubSaDelItems.pubSas);
pubSaDetails.AddRange(pubSaDelItems.pubSaDetails);
pubCanSas.AddRange(pubSaDelItems.pubCanSas);
pubCanSaDetails.AddRange(pubSaDelItems.pubCanSaDetails);
pubNotSaDetails.AddRange(pubSaDelItems.pubNotSaDetails);
}
catch (Exception)
{
throw;
}
pubCanSaDelEntitys = await _pubCanSaRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum); //删除
//验证可结算主表状态 if (pubSas.Any())
if (pubCanSaDelEntitys.Any(t => t.State != SettleBillState.)) {
await _repository.DeleteManyAsync(pubSas);
}
if (pubSaDetails.Any())
{
await _pubSaDetailRepository.DeleteManyAsync(pubSaDetails);
}
if (pubCanSas.Any())
{
await _pubCanSaRepository.DeleteManyAsync(pubCanSas);
}
if (pubCanSaDetails.Any())
{ {
throw new UserFriendlyException($"该单据可结算单状态无法删除!", "400"); await _pubCanSaDetailRepository.DeleteManyAsync(pubCanSaDetails);
}
if (pubNotSaDetails.Any())
{
await _pubNotSaDetailRepository.DeleteManyAsync(pubNotSaDetails);
}
} }
pubSaDetailDelEntitys = await _pubSaDetailRepository.GetListAsync(t => t.BillNum == pubSaBillNum); /// <summary>
pubCanSaDetailDelEntitys = await _pubCanSaDetailRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum); /// 删除
pubNotSaDetailDelEntitys = await _pubNotSaDetailRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum); /// </summary>
[HttpPost]
public async Task DeleteListAsync(List<Guid> ids)
{
//结算主表
List<PUB_SA> pubSas = new List<PUB_SA>();
//结算明细
List<PUB_SA_DETAIL> pubSaDetails = new List<PUB_SA_DETAIL>();
//可结算主表
List<PUB_CAN_SA> pubCanSas = new List<PUB_CAN_SA>();
//可结算明细
List<PUB_CAN_SA_DETAIL> pubCanSaDetails = new List<PUB_CAN_SA_DETAIL>();
//不可结算
List<PUB_NOT_SA_DETAIL> pubNotSaDetails = new List<PUB_NOT_SA_DETAIL>();
foreach (var id in ids)
{
try
{
var pubSaDelItems = await GetPubSaDelItemsAsync(id);
pubSas.AddRange(pubSaDelItems.pubSas);
pubSaDetails.AddRange(pubSaDelItems.pubSaDetails);
pubCanSas.AddRange(pubSaDelItems.pubCanSas);
pubCanSaDetails.AddRange(pubSaDelItems.pubCanSaDetails);
pubNotSaDetails.AddRange(pubSaDelItems.pubNotSaDetails);
}
catch (Exception)
{
throw;
}
}
//删除 //删除
await _repository.DeleteAsync(pubSaDelEntity); if (pubSas.Any())
if (pubSaDetailDelEntitys.Any())
{ {
await _pubSaDetailRepository.DeleteManyAsync(pubSaDetailDelEntitys); await _repository.DeleteManyAsync(pubSas);
} }
if (pubCanSaDelEntitys.Any()) if (pubSaDetails.Any())
{ {
await _pubCanSaRepository.DeleteManyAsync(pubCanSaDelEntitys); await _pubSaDetailRepository.DeleteManyAsync(pubSaDetails);
} }
if (pubCanSaDetailDelEntitys.Any()) if (pubCanSas.Any())
{ {
await _pubCanSaDetailRepository.DeleteManyAsync(pubCanSaDetailDelEntitys); await _pubCanSaRepository.DeleteManyAsync(pubCanSas);
} }
if (pubNotSaDetailDelEntitys.Any()) if (pubCanSaDetails.Any())
{ {
await _pubNotSaDetailRepository.DeleteManyAsync(pubNotSaDetailDelEntitys); await _pubCanSaDetailRepository.DeleteManyAsync(pubCanSaDetails);
}
if (pubNotSaDetails.Any())
{
await _pubNotSaDetailRepository.DeleteManyAsync(pubNotSaDetails);
} }
} }
#endregion #endregion
@ -332,6 +392,43 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
return ApplicationConsts.SuccessStr; return ApplicationConsts.SuccessStr;
} }
#endregion
/// <summary>
/// 获取结算关联项
/// </summary>
private async Task<(List<PUB_SA> pubSas, List<PUB_SA_DETAIL> pubSaDetails, List<PUB_CAN_SA> pubCanSas, List<PUB_CAN_SA_DETAIL> pubCanSaDetails, List<PUB_NOT_SA_DETAIL> pubNotSaDetails)> GetPubSaDelItemsAsync(Guid id)
{
//结算主表
List<PUB_SA> pubSas = new List<PUB_SA>();
//结算明细
List<PUB_SA_DETAIL> pubSaDetails = new List<PUB_SA_DETAIL>();
//可结算主表
List<PUB_CAN_SA> pubCanSas = new List<PUB_CAN_SA>();
//可结算明细
List<PUB_CAN_SA_DETAIL> pubCanSaDetails = new List<PUB_CAN_SA_DETAIL>();
//不可结算
List<PUB_NOT_SA_DETAIL> pubNotSaDetails = new List<PUB_NOT_SA_DETAIL>();
var pubSaEntity = await _repository.FirstOrDefaultAsync(t => t.Id.Equals(id));
if (pubSaEntity != null)
{
//结算单据
string pubSaBillNum = pubSaEntity.BillNum;
pubCanSas = await _pubCanSaRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum);
//验证可结算主表状态
if (pubCanSas.Any(t => t.State != SettleBillState.) == false)
{
throw new UserFriendlyException($"{pubSaBillNum} 该单据可结算单状态无法删除!", "400");
}
pubSas.Add(pubSaEntity);
pubSaDetails = await _pubSaDetailRepository.GetListAsync(t => t.BillNum == pubSaBillNum);
pubCanSaDetails = await _pubCanSaDetailRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum);
pubNotSaDetails = await _pubNotSaDetailRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum);
} }
return (pubSas, pubSaDetails, pubCanSas , pubCanSaDetails, pubNotSaDetails);
}
#endregion
} }

9
code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SE_DETAIL_SERVICE.cs

@ -1,9 +1,11 @@
using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc;
using Microsoft.OpenApi.Extensions;
using SettleAccount.Domain.BQ; using SettleAccount.Domain.BQ;
using Shouldly; using Shouldly;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Threading.Tasks; using System.Threading.Tasks;
using Volo.Abp.Application.Dtos; using Volo.Abp.Application.Dtos;
using Volo.Abp.Application.Services; using Volo.Abp.Application.Services;
@ -45,9 +47,12 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
/// 导出 /// 导出
/// </summary> /// </summary>
[HttpPost] [HttpPost]
public async Task<string> ExportAsync(RequestDto input) public async Task<string> ExportAsync(PUB_SE_DETAIL_RequestDto input)
{ {
string fileName = $"PUB发运单_{Guid.NewGuid()}.xlsx"; input.Filters.Add(new FilterCondition("BusinessType", input.BusinessType.ToString(), EnumFilterAction.Equal, EnumFilterLogic.And));
var businessTypeDisplayName = input.BusinessType.GetDisplayName();
string fileName = $"{businessTypeDisplayName}发运数据_{Guid.NewGuid()}.xlsx";
var entities = await _repository.GetListByFilterAsync(input.Filters, input.Sorting, int.MaxValue, 0, true); var entities = await _repository.GetListByFilterAsync(input.Filters, input.Sorting, int.MaxValue, 0, true);
var dtos = ObjectMapper.Map<List<PUB_SE_DETAIL>, List<PUB_SE_DETAIL_EXPORT_DTO>>(entities); var dtos = ObjectMapper.Map<List<PUB_SE_DETAIL>, List<PUB_SE_DETAIL_EXPORT_DTO>>(entities);

14
code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs

@ -1,20 +1,15 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Magicodes.ExporterAndImporter.Core; using Magicodes.ExporterAndImporter.Core;
using Magicodes.ExporterAndImporter.Csv;
using Magicodes.ExporterAndImporter.Excel; using Magicodes.ExporterAndImporter.Excel;
using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc;
using NPOI.SS.UserModel;
using NPOI.SS.Util;
using Shouldly; using Shouldly;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Volo.Abp.Application.Dtos; using Volo.Abp.Application.Dtos;
using Volo.Abp.Application.Services;
using Volo.Abp.Caching; using Volo.Abp.Caching;
using Volo.Abp.Domain.Repositories;
using Win.Abp.Snowflakes; using Win.Abp.Snowflakes;
using Win.Sfs.BaseData.ImportExcelCommon; using Win.Sfs.BaseData.ImportExcelCommon;
using Win.Sfs.SettleAccount.CommonManagers; using Win.Sfs.SettleAccount.CommonManagers;
@ -124,7 +119,6 @@ public class PriceListAppService : SettleAccountApplicationBase<PriceList>
[HttpPost] [HttpPost]
public virtual async Task<string> ExportAsync(RequestDto input) public virtual async Task<string> ExportAsync(RequestDto input)
{ {
IExporter _csv = new CsvExporter();
IExporter _excel = new ExcelExporter(); IExporter _excel = new ExcelExporter();
var entities = await _priceListManager.GetListAsync(input.Filters, input.Sorting, int.MaxValue, 0, true); var entities = await _priceListManager.GetListAsync(input.Filters, input.Sorting, int.MaxValue, 0, true);
var dtoDetails = ObjectMapper.Map<List<PriceList>, List<PriceListExportDto>>(entities); var dtoDetails = ObjectMapper.Map<List<PriceList>, List<PriceListExportDto>>(entities);

12
code/src/SettleAccount.sln

@ -6,16 +6,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Shared", "Shared", "{61F213
EndProject EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Modules", "Modules", "{A6179011-0C7F-440A-A559-B9C90BB0229A}" Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Modules", "Modules", "{A6179011-0C7F-440A-A559-B9C90BB0229A}"
EndProject EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "MicroServices", "MicroServices", "{1C1B27DC-DEDF-4067-9791-660302A09C66}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Win.Abp", "Win.Abp", "{1853A9CF-DB6D-4612-A6EA-8815E011F2C9}" Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Win.Abp", "Win.Abp", "{1853A9CF-DB6D-4612-A6EA-8815E011F2C9}"
EndProject EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BaseService.Host", "Modules\BaseService\BaseService.Host\BaseService.Host.csproj", "{7E3E3AEB-C7C4-495D-B963-8A3B4DB0CB3B}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Win.Sfs.Shared", "Shared\Win.Sfs.Shared\Win.Sfs.Shared.csproj", "{9B9733F4-F13E-428E-AA4A-BA68432FE3B8}" Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Win.Sfs.Shared", "Shared\Win.Sfs.Shared\Win.Sfs.Shared.csproj", "{9B9733F4-F13E-428E-AA4A-BA68432FE3B8}"
EndProject EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Hosts", "Hosts", "{5E5C6DAB-A70E-44A9-93C9-4A2C4AE837A7}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SettleAccount", "SettleAccount", "{9C23A6A4-4292-47F2-89C1-94993C61DBB5}" Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SettleAccount", "SettleAccount", "{9C23A6A4-4292-47F2-89C1-94993C61DBB5}"
EndProject EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SettleAccount.Domain", "Modules\SettleAccount\src\SettleAccount.Domain\SettleAccount.Domain.csproj", "{187B2ECE-6EF4-4C06-8110-FEAD592C343B}" Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SettleAccount.Domain", "Modules\SettleAccount\src\SettleAccount.Domain\SettleAccount.Domain.csproj", "{187B2ECE-6EF4-4C06-8110-FEAD592C343B}"
@ -62,10 +56,6 @@ Global
Release|Any CPU = Release|Any CPU Release|Any CPU = Release|Any CPU
EndGlobalSection EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution GlobalSection(ProjectConfigurationPlatforms) = postSolution
{7E3E3AEB-C7C4-495D-B963-8A3B4DB0CB3B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7E3E3AEB-C7C4-495D-B963-8A3B4DB0CB3B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7E3E3AEB-C7C4-495D-B963-8A3B4DB0CB3B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7E3E3AEB-C7C4-495D-B963-8A3B4DB0CB3B}.Release|Any CPU.Build.0 = Release|Any CPU
{9B9733F4-F13E-428E-AA4A-BA68432FE3B8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {9B9733F4-F13E-428E-AA4A-BA68432FE3B8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9B9733F4-F13E-428E-AA4A-BA68432FE3B8}.Debug|Any CPU.Build.0 = Debug|Any CPU {9B9733F4-F13E-428E-AA4A-BA68432FE3B8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9B9733F4-F13E-428E-AA4A-BA68432FE3B8}.Release|Any CPU.ActiveCfg = Release|Any CPU {9B9733F4-F13E-428E-AA4A-BA68432FE3B8}.Release|Any CPU.ActiveCfg = Release|Any CPU
@ -144,7 +134,6 @@ Global
EndGlobalSection EndGlobalSection
GlobalSection(NestedProjects) = preSolution GlobalSection(NestedProjects) = preSolution
{1853A9CF-DB6D-4612-A6EA-8815E011F2C9} = {61F21377-02D4-40C5-80B3-F0C2999CE6B7} {1853A9CF-DB6D-4612-A6EA-8815E011F2C9} = {61F21377-02D4-40C5-80B3-F0C2999CE6B7}
{7E3E3AEB-C7C4-495D-B963-8A3B4DB0CB3B} = {5E5C6DAB-A70E-44A9-93C9-4A2C4AE837A7}
{9B9733F4-F13E-428E-AA4A-BA68432FE3B8} = {61F21377-02D4-40C5-80B3-F0C2999CE6B7} {9B9733F4-F13E-428E-AA4A-BA68432FE3B8} = {61F21377-02D4-40C5-80B3-F0C2999CE6B7}
{9C23A6A4-4292-47F2-89C1-94993C61DBB5} = {A6179011-0C7F-440A-A559-B9C90BB0229A} {9C23A6A4-4292-47F2-89C1-94993C61DBB5} = {A6179011-0C7F-440A-A559-B9C90BB0229A}
{187B2ECE-6EF4-4C06-8110-FEAD592C343B} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5} {187B2ECE-6EF4-4C06-8110-FEAD592C343B} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5}
@ -154,7 +143,6 @@ Global
{C40757EE-FAA8-4D49-9C78-CFB54996FFDE} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5} {C40757EE-FAA8-4D49-9C78-CFB54996FFDE} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5}
{0C90B328-0E35-426C-8E9D-AA4A06A17E7C} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5} {0C90B328-0E35-426C-8E9D-AA4A06A17E7C} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5}
{5E340FD0-13A3-40ED-9E3D-6A0A73AFDCDB} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5} {5E340FD0-13A3-40ED-9E3D-6A0A73AFDCDB} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5}
{37844A66-3402-43B6-8AC1-86D0F56A51CA} = {5E5C6DAB-A70E-44A9-93C9-4A2C4AE837A7}
{E9292DE0-20BC-4885-ADED-F429BA821A28} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5} {E9292DE0-20BC-4885-ADED-F429BA821A28} = {9C23A6A4-4292-47F2-89C1-94993C61DBB5}
{A38483F2-F00B-4171-94C1-9A4EF96BF39A} = {61F21377-02D4-40C5-80B3-F0C2999CE6B7} {A38483F2-F00B-4171-94C1-9A4EF96BF39A} = {61F21377-02D4-40C5-80B3-F0C2999CE6B7}
{50D7C4D1-188C-4553-A477-500DD9B4FBE2} = {1853A9CF-DB6D-4612-A6EA-8815E011F2C9} {50D7C4D1-188C-4553-A477-500DD9B4FBE2} = {1853A9CF-DB6D-4612-A6EA-8815E011F2C9}

Loading…
Cancel
Save