diff --git a/src/InterfaceForward.Application/Services/App/AppsService.cs b/src/InterfaceForward.Application/Services/App/AppsService.cs index 18865b1..dd0bb77 100644 --- a/src/InterfaceForward.Application/Services/App/AppsService.cs +++ b/src/InterfaceForward.Application/Services/App/AppsService.cs @@ -172,6 +172,11 @@ public class AppsService : ApplicationService (await _interfaceRepository.GetListAsync(x => interfaceIds.Contains(x.Id), x => new { x.Id, x.Code })) .ToDictionary(x => x.Id, x => x.Code); + if (interfaceDic.Count != interfaceIds.Count) + { + throw new BusinessException(message: "有接口不存在,请检查"); + } + using (var ts = TransacationHelper.GetReadCommitted()) { var id = await _appRepository.InsertReturnIdentityAsync(entity); diff --git a/src/InterfaceForward.Repositories/App/Entitys/AppEntity.cs b/src/InterfaceForward.Repositories/App/Entitys/AppEntity.cs index af13f35..03e3b58 100644 --- a/src/InterfaceForward.Repositories/App/Entitys/AppEntity.cs +++ b/src/InterfaceForward.Repositories/App/Entitys/AppEntity.cs @@ -4,7 +4,7 @@ /// 应用表 /// [SugarTable("t_app")] -public class AppEntity : FullAuditedAggregateRoot +public class AppEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/App/Entitys/AppScopeEntity.cs b/src/InterfaceForward.Repositories/App/Entitys/AppScopeEntity.cs index fb9a89c..8cb6984 100644 --- a/src/InterfaceForward.Repositories/App/Entitys/AppScopeEntity.cs +++ b/src/InterfaceForward.Repositories/App/Entitys/AppScopeEntity.cs @@ -4,7 +4,7 @@ /// 应用可用接口表 /// [SugarTable("t_app_scope")] - public class AppScopeEntity : FullAuditedAggregateRoot + public class AppScopeEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/App/Entitys/AppSubscribeConfigEntity.cs b/src/InterfaceForward.Repositories/App/Entitys/AppSubscribeConfigEntity.cs index cacc267..333affd 100644 --- a/src/InterfaceForward.Repositories/App/Entitys/AppSubscribeConfigEntity.cs +++ b/src/InterfaceForward.Repositories/App/Entitys/AppSubscribeConfigEntity.cs @@ -4,7 +4,7 @@ /// 应用mq订阅配置表 /// [SugarTable("t_app_subscribe_config")] -public class AppSubscribeConfigEntity : FullAuditedAggregateRoot +public class AppSubscribeConfigEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceCategoryEntity.cs b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceCategoryEntity.cs index 52006bf..0222cc3 100644 --- a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceCategoryEntity.cs +++ b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceCategoryEntity.cs @@ -4,7 +4,7 @@ /// 接口分类表 /// [SugarTable("t_interface_category")] - public class InterfaceCategoryEntity : FullAuditedAggregateRoot + public class InterfaceCategoryEntity : FullAuditedAggregateRoot { /// /// 父分类id diff --git a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceEntity.cs b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceEntity.cs index 16099ac..4a10afc 100644 --- a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceEntity.cs +++ b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceEntity.cs @@ -6,7 +6,7 @@ namespace InterfaceForward.Repositories.Interface.Entitys; /// 接口表 /// [SugarTable("t_interface")] -public class InterfaceEntity : FullAuditedAggregateRoot +public class InterfaceEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapDetailEntity.cs b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapDetailEntity.cs index bd82a2e..fb117fe 100644 --- a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapDetailEntity.cs +++ b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapDetailEntity.cs @@ -4,7 +4,7 @@ /// 接口映射明细表 /// [SugarTable("t_interface_map_detail")] -public class InterfaceMapDetailEntity: FullAuditedAggregateRoot +public class InterfaceMapDetailEntity: FullAuditedAggregateRoot { /// /// 映射明细id diff --git a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapEntity.cs b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapEntity.cs index 5e57888..bb49bfc 100644 --- a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapEntity.cs +++ b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapEntity.cs @@ -4,7 +4,7 @@ /// 接口映射表 /// [SugarTable("t_interface_map")] - public class InterfaceMapEntity : FullAuditedAggregateRoot + public class InterfaceMapEntity : FullAuditedAggregateRoot { /// diff --git a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapPublishedEntity.cs b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapPublishedEntity.cs index a8dffbe..e2a7c12 100644 --- a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapPublishedEntity.cs +++ b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceMapPublishedEntity.cs @@ -6,7 +6,7 @@ namespace InterfaceForward.Repositories.Interface.Entitys; /// 接口映射明细表 /// [SugarTable("t_interface_map_published")] -public class InterfaceMapPublishedEntity: AggregateRoot, IHasCreateUserId, IHasCreateTime +public class InterfaceMapPublishedEntity: AggregateRoot, IHasCreateUserId, IHasCreateTime { /// /// id @@ -62,6 +62,6 @@ public class InterfaceMapPublishedEntity: AggregateRoot, IHasCreateUserId, [SugarColumn(ColumnName = "Description")] public string Description { get; set; } - public Guid CreateUserId { get; } + public int CreateUserId { get; } public DateTime CreateTime { get; } } \ No newline at end of file diff --git a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceReturnConfigEntity.cs b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceReturnConfigEntity.cs index 5cfd174..6b365db 100644 --- a/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceReturnConfigEntity.cs +++ b/src/InterfaceForward.Repositories/Interface/Entitys/InterfaceReturnConfigEntity.cs @@ -6,7 +6,7 @@ namespace InterfaceForward.Repositories.Interface.Entitys; /// 接口返回配置 /// [SugarTable("t_interface_return_config")] -public class InterfaceReturnConfigEntity : FullAuditedAggregateRoot +public class InterfaceReturnConfigEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/Parameter/Entities/FixedParameterEntity.cs b/src/InterfaceForward.Repositories/Parameter/Entities/FixedParameterEntity.cs index abf2a7f..82bba2c 100644 --- a/src/InterfaceForward.Repositories/Parameter/Entities/FixedParameterEntity.cs +++ b/src/InterfaceForward.Repositories/Parameter/Entities/FixedParameterEntity.cs @@ -4,7 +4,7 @@ /// 固定参数 /// [SugarTable("t_parameter_fixed")] -public class FixedParameterEntity : FullAuditedAggregateRoot +public class FixedParameterEntity : FullAuditedAggregateRoot { /// diff --git a/src/InterfaceForward.Repositories/Parameter/Entities/FormParameterEntity.cs b/src/InterfaceForward.Repositories/Parameter/Entities/FormParameterEntity.cs index a7826b1..b23c013 100644 --- a/src/InterfaceForward.Repositories/Parameter/Entities/FormParameterEntity.cs +++ b/src/InterfaceForward.Repositories/Parameter/Entities/FormParameterEntity.cs @@ -4,7 +4,7 @@ /// 表单参数 /// [SugarTable("t_parameter_form")] -public class FormParameterEntity : FullAuditedAggregateRoot +public class FormParameterEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/Parameter/Entities/ParameterEntity.cs b/src/InterfaceForward.Repositories/Parameter/Entities/ParameterEntity.cs index b325795..1727b5a 100644 --- a/src/InterfaceForward.Repositories/Parameter/Entities/ParameterEntity.cs +++ b/src/InterfaceForward.Repositories/Parameter/Entities/ParameterEntity.cs @@ -6,7 +6,7 @@ namespace InterfaceForward.Repositories.Interface.Entitys /// 参数表 /// [SugarTable("t_parameter")] - public class ParameterEntity : FullAuditedAggregateRoot + public class ParameterEntity : FullAuditedAggregateRoot { /// diff --git a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountEntity.cs b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountEntity.cs index 5d1c1e6..6623e02 100644 --- a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountEntity.cs +++ b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountEntity.cs @@ -4,7 +4,7 @@ /// 服务商账户表 /// [SugarTable("t_service_provider_account")] - public class ServiceProviderAccountEntity : FullAuditedAggregateRoot + public class ServiceProviderAccountEntity : FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountFieldEntity.cs b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountFieldEntity.cs index 2d36032..b11a39f 100644 --- a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountFieldEntity.cs +++ b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAccountFieldEntity.cs @@ -2,7 +2,7 @@ /// 服务商账户字段表 /// [SugarTable("t_service_provider_account_field")] -public class ServiceProviderAccountFieldEntity : FullAuditedAggregateRoot +public class ServiceProviderAccountFieldEntity : FullAuditedAggregateRoot { /// diff --git a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAuthConfigEntity.cs b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAuthConfigEntity.cs index e61d692..92536e7 100644 --- a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAuthConfigEntity.cs +++ b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderAuthConfigEntity.cs @@ -6,7 +6,7 @@ namespace InterfaceForward.Repositories.ServiceProvider.Entitys; /// 服务商授权配置表 /// [SugarTable("t_service_provider_auth_config")] -public class ServiceProviderAuthConfigEntity: FullAuditedAggregateRoot +public class ServiceProviderAuthConfigEntity: FullAuditedAggregateRoot { /// /// 自增主键 diff --git a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderEntity.cs b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderEntity.cs index ea24751..7aecbb4 100644 --- a/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderEntity.cs +++ b/src/InterfaceForward.Repositories/ServiceProvider/Entitys/ServiceProviderEntity.cs @@ -4,7 +4,7 @@ /// 服务商主表 /// [SugarTable("t_service_provider")] -public class ServiceProviderEntity : FullAuditedAggregateRoot +public class ServiceProviderEntity : FullAuditedAggregateRoot { ///