From 21dd3f455c51558aeed43811885223c1c0c15211 Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Wed, 16 Jul 2025 09:38:24 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=8C=87=E6=B4=BE=E5=85=B6=E4=BB=96?= =?UTF-8?q?=E8=B4=A8=E6=8E=A7-uat-12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../TrialSiteUser/DTO/TrialSiteViewModel.cs | 11 ++++++++++ .../TrialSiteUser/TrialMaintenanceService.cs | 20 +++++++++++++++++-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/IRaCIS.Core.Application/Service/TrialSiteUser/DTO/TrialSiteViewModel.cs b/IRaCIS.Core.Application/Service/TrialSiteUser/DTO/TrialSiteViewModel.cs index e09765994..240586d0b 100644 --- a/IRaCIS.Core.Application/Service/TrialSiteUser/DTO/TrialSiteViewModel.cs +++ b/IRaCIS.Core.Application/Service/TrialSiteUser/DTO/TrialSiteViewModel.cs @@ -139,5 +139,16 @@ namespace IRaCIS.Core.Application.Contracts.DTO } + public class TrialSelectUserBasicInfo + { + public Guid UserRoleId { get; set; } + public string FullName { get; set; } + + public string UserName { get; set; } + + public string Email { get; set; } + + public string Phone { get; set; } + } } \ No newline at end of file diff --git a/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs b/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs index 178493ee8..ff815ec90 100644 --- a/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs +++ b/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs @@ -56,8 +56,8 @@ namespace IRaCIS.Core.Application.Service IsDeleted = t.IsDeleted, UserTypeId = t.UserRole.UserTypeRole.Id, UserTypeShortName = t.UserRole.UserTypeRole.UserTypeShortName, - CreateTime=t.CreateTime, - UpdateTime=t.UpdateTime, + CreateTime = t.CreateTime, + UpdateTime = t.UpdateTime, }).ToList(), }).ToPagedListAsync(inQuery); @@ -315,7 +315,23 @@ namespace IRaCIS.Core.Application.Service } + public async Task> GetTrialUserRoleList(Guid trialId, UserTypeEnum? userTypeEnum) + { + var list = await _trialIdentityUserRepository.Where(t => t.TrialId == trialId) + .SelectMany(t => t.TrialUserRoleList) + .WhereIf(userTypeEnum != null, t => t.UserRole.UserTypeEnum == userTypeEnum) + .Select(t => new TrialSelectUserBasicInfo() + { + FullName = t.TrialUser.IdentityUser.FullName, + UserRoleId = t.UserRole.Id, + UserName = t.TrialUser.IdentityUser.UserName, + Phone = t.TrialUser.IdentityUser.Phone, + Email = t.TrialUser.IdentityUser.EMail + }) + .ToListAsync(); + return list; + } } } From ff08efd97834a4845e85c0477c0710aac81f920a Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Wed, 16 Jul 2025 10:11:24 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=8C=87=E6=B4=BE=E5=85=B6=E4=BB=96?= =?UTF-8?q?=E8=B4=A8=E6=8E=A7-uat-13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/TrialSiteUser/TrialMaintenanceService.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs b/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs index ff815ec90..ae9de60e8 100644 --- a/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs +++ b/IRaCIS.Core.Application/Service/TrialSiteUser/TrialMaintenanceService.cs @@ -320,6 +320,7 @@ namespace IRaCIS.Core.Application.Service var list = await _trialIdentityUserRepository.Where(t => t.TrialId == trialId) .SelectMany(t => t.TrialUserRoleList) .WhereIf(userTypeEnum != null, t => t.UserRole.UserTypeEnum == userTypeEnum) + .Where(t => t.UserRole.Id != _userInfo.UserRoleId)//iQC 指派过滤自己 .Select(t => new TrialSelectUserBasicInfo() { FullName = t.TrialUser.IdentityUser.FullName,