From 0a5164682fbb3e6a829e8c020e41a22399caff12 Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Thu, 11 Sep 2025 14:09:21 +0800 Subject: [PATCH] =?UTF-8?q?admin=20=E5=8F=AF=E4=BB=A5=E7=9C=8B=E6=89=80?= =?UTF-8?q?=E6=9C=89=E5=8C=BB=E9=99=A2=EF=BC=8C=E4=B8=8D=E5=8F=97=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E5=8C=BB=E9=99=A2=E5=BD=B1=E5=93=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IRaCIS.Core.API/appsettings.Test_HIR.json | 2 +- IRaCIS.Core.API/appsettings.Uat_HIR.json | 23 +++++++------------ .../IRaCIS.Core.Application.xml | 2 +- .../Service/TrialSiteUser/TrialService.cs | 2 +- .../Service/Visit/PatientService.cs | 2 +- IRaCIS.Core.Application/TestService.cs | 18 +++++++++++++++ 6 files changed, 30 insertions(+), 19 deletions(-) diff --git a/IRaCIS.Core.API/appsettings.Test_HIR.json b/IRaCIS.Core.API/appsettings.Test_HIR.json index 093dc9938..c2b5e67d4 100644 --- a/IRaCIS.Core.API/appsettings.Test_HIR.json +++ b/IRaCIS.Core.API/appsettings.Test_HIR.json @@ -42,7 +42,7 @@ "IsNeedChangePassWord": true, // 密码有效期(天),到期后必须修改 "ChangePassWordDays": 1000, - "OpenImageShare": true, + "OpenImageShare": true }, "SystemEmailSendConfig": { diff --git a/IRaCIS.Core.API/appsettings.Uat_HIR.json b/IRaCIS.Core.API/appsettings.Uat_HIR.json index e3293cd39..87bd29ced 100644 --- a/IRaCIS.Core.API/appsettings.Uat_HIR.json +++ b/IRaCIS.Core.API/appsettings.Uat_HIR.json @@ -36,20 +36,12 @@ "AutoLoginOutMinutes": 120, "AESKey": "HIR_System_AES_Key_Info", "CmoveIntervalMinutes": 1, - "CmoveInstanceIntervalMinutes": 1 - }, - "SystemHospitalConfig": { - "HospitalCode": "EI", - "HospitalLogoPath": "/System/GeneralDocuments/1716453306898_图片2.png", - "TrialKeepCount": 60, - "HospitalName": "上海展影医疗科技有限公司", - "HospitalAliasName": "展影医疗", - "Country": "中国", - "City": "上海", - "Province": "上海", - "Address": "上海市杨浦区国泰路复旦科技园", - "Phone": "021-60702575", - "IsCanConnectInternet": false + "CmoveInstanceIntervalMinutes": 1, + // 是否强制用户定期修改密码 + "IsNeedChangePassWord": true, + // 密码有效期(天),到期后必须修改 + "ChangePassWordDays": 1000, + "OpenImageShare": true }, "SystemEmailSendConfig": { "Port": 465, @@ -57,6 +49,7 @@ "FromEmail": "test-study@extimaging.com", "FromName": "Test_HIR", "AuthorizationCode": "zhanying123", - "SiteUrl": "http://hir.test.extimaging.com/login" + "SiteUrl": "http://hir.test.extimaging.com/login", + "EmailRegexStr": "^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\\.[a-zA-Z]{2,}$" } } \ No newline at end of file diff --git a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml index 1bf0fb780..1b7d56be5 100644 --- a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml +++ b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml @@ -7210,7 +7210,7 @@ 部位 - + 检查号 diff --git a/IRaCIS.Core.Application/Service/TrialSiteUser/TrialService.cs b/IRaCIS.Core.Application/Service/TrialSiteUser/TrialService.cs index 827288e03..4f1258df6 100644 --- a/IRaCIS.Core.Application/Service/TrialSiteUser/TrialService.cs +++ b/IRaCIS.Core.Application/Service/TrialSiteUser/TrialService.cs @@ -134,7 +134,7 @@ namespace IRaCIS.Core.Application.Service var hospitalInfo = await _fusionCache.GetOrSetAsync(CacheKeys.Hospital, _ => CacheHelper.GetHospitalCode(_hIRHospitalRepository), TimeSpan.FromDays(7)); return await _trialRepository.AsQueryable() //过滤医院,切换会有问题 - .Where(t => t.HospitalId == hospitalInfo.Id) + .WhereIf(_userInfo.UserTypeEnumInt != (int)UserTypeEnum.SuperAdmin && _userInfo.UserTypeEnumInt != (int)UserTypeEnum.Admin, t => t.HospitalId == hospitalInfo.Id) //SuperAdmin Admin OP OA .WhereIf(sap.Contains(_userInfo.UserTypeEnumInt), x => trialState.Contains(x.TrialStatusStr)) diff --git a/IRaCIS.Core.Application/Service/Visit/PatientService.cs b/IRaCIS.Core.Application/Service/Visit/PatientService.cs index cb9841148..a39dbad3c 100644 --- a/IRaCIS.Core.Application/Service/Visit/PatientService.cs +++ b/IRaCIS.Core.Application/Service/Visit/PatientService.cs @@ -218,7 +218,7 @@ namespace IRaCIS.Application.Services .WhereIf(!string.IsNullOrWhiteSpace(inQuery.TrialCode), t => t.TrialCode.Contains(inQuery.TrialCode)) //过滤医院,切换会有问题 - .Where(t => t.HospitalId == hospitalInfo.Id) + .WhereIf(_userInfo.UserTypeEnumInt != (int)UserTypeEnum.SuperAdmin && _userInfo.UserTypeEnumInt != (int)UserTypeEnum.Admin, t => t.HospitalId == hospitalInfo.Id) //GA 要过滤课题组 .WhereIf(_userInfo.UserTypeEnumInt == (int)UserTypeEnum.GA && hospitalGroupAdminIdList.Any(), t => hospitalGroupAdminIdList.Contains(t.HospitalGroupId)) .WhereIf(_userInfo.UserTypeEnumInt != (int)UserTypeEnum.SuperAdmin && _userInfo.UserTypeEnumInt != (int)UserTypeEnum.Admin && _userInfo.UserTypeEnumInt != (int)UserTypeEnum.OA diff --git a/IRaCIS.Core.Application/TestService.cs b/IRaCIS.Core.Application/TestService.cs index 36b3ccd24..e638eec97 100644 --- a/IRaCIS.Core.Application/TestService.cs +++ b/IRaCIS.Core.Application/TestService.cs @@ -300,6 +300,24 @@ namespace IRaCIS.Core.Application.Service return ResponseOutput.Ok(); } + [AllowAnonymous] + public async Task NewUserHospitalGroup( + [FromServices] IRepository _SCPStudyHospitalGroupRepository, + [FromServices] IRepository _SCPStudyRepository, Guid hospitalGroupId) + { + + var scpStudyIdList = _SCPStudyRepository.Where().Select(t => t.Id).ToList(); + + foreach (var item in scpStudyIdList) + { + await _SCPStudyHospitalGroupRepository.AddAsync(new SCPStudyHospitalGroup() { SCPStudyId = item, HospitalGroupId = hospitalGroupId }); + } + + await _SCPStudyRepository.SaveChangesAsync(); + + return ResponseOutput.Ok(); + } + /// /// 外部人员 中心调研人员维护 ///