Merge branch 'Test_IRC_Net8' of http://192.168.3.68:2000/XCKJ/irc-netcore-api into Test_IRC_Net8
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
commit
a4d20d9f08
|
@ -90,8 +90,9 @@ public class LimitUserRequestAuthorization : IAsyncAuthorizationFilter
|
|||
{
|
||||
context.HttpContext.Response.ContentType = "application/json";
|
||||
context.HttpContext.Response.StatusCode = StatusCodes.Status403Forbidden;
|
||||
context.Result = new JsonResult(ResponseOutput.NotOk("登录无操作超时自动退出", ApiResponseCodeEnum.AutoLoginOut));
|
||||
|
||||
context.Result = new JsonResult(ResponseOutput.NotOk(_localizer["LimitUser_AccountAuto_LoginOut"], ApiResponseCodeEnum.AutoLoginOut));
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -40,11 +40,11 @@ namespace IRaCIS.Core.Application.Service
|
|||
{
|
||||
var cacheList= _provider.Get<List<InternationalizationSimpleDto>>(StaticData.InternationalData.Front).Value;
|
||||
|
||||
if(cacheList != null && cacheList.Count!=0)
|
||||
{
|
||||
return cacheList;
|
||||
}
|
||||
else
|
||||
//if(cacheList != null && cacheList.Count!=0)
|
||||
//{
|
||||
// return cacheList;
|
||||
//}
|
||||
//else
|
||||
{
|
||||
var list = await _internationalizationRepository.Where(t => t.InternationalizationType == 0).Select(t => new InternationalizationSimpleDto()
|
||||
{
|
||||
|
|
|
@ -29,6 +29,8 @@ namespace IRaCIS.Core.Application.Contracts
|
|||
public bool IsDeleted { get; set; }
|
||||
public bool IsReading { get; set; } = true;
|
||||
|
||||
public string SliceThickness { get; set; } = String.Empty;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -86,6 +86,7 @@ namespace IRaCIS.Core.Application.Service
|
|||
|
||||
CreateMap<DicomInstance, DicomInstanceDTO>()
|
||||
.ForMember(o => o.IsDeleted, t => t.MapFrom(u => u.DicomSerie.IsDeleted))
|
||||
.ForMember(o => o.SliceThickness, t => t.MapFrom(u => u.DicomSerie.SliceThickness))
|
||||
.ForMember(o => o.IsReading, t => t.MapFrom(u => u.DicomSerie.IsReading));
|
||||
CreateMap<DicomStudy, DicomStudyDTO>();
|
||||
CreateMap<DicomSeries, DicomSeriesDTO>();
|
||||
|
|
|
@ -35,7 +35,7 @@ namespace IRaCIS.Application.Services
|
|||
/// <summary> 根据CRO 名称查询所有CRO 列表 </summary>
|
||||
public async Task<IEnumerable<CroSelectDTO>> GetAllCROList(Guid? croId)
|
||||
{
|
||||
return await _croRepository.Where(t => t.IsTrialLevel == false || t.Id == croId).ProjectTo<CroSelectDTO>(_mapper.ConfigurationProvider, new { isEn_Us = _userInfo.IsEn_Us }).ToListAsync();
|
||||
return await _croRepository/*.Where(t => t.IsTrialLevel == false || t.Id == croId)*/.ProjectTo<CroSelectDTO>(_mapper.ConfigurationProvider, new { isEn_Us = _userInfo.IsEn_Us }).ToListAsync();
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ namespace IRaCIS.Application.Services
|
|||
public async Task<IEnumerable<SponsorSelectDTO>> GetAllSponsorList(Guid? sponsorId)
|
||||
{
|
||||
|
||||
var sponsorQueryable = _sponsorRepository.Where(t => t.IsTrialLevel == false || t.Id == sponsorId).ProjectTo<SponsorSelectDTO>(_mapper.ConfigurationProvider,new { isEn_Us= _userInfo.IsEn_Us});
|
||||
var sponsorQueryable = _sponsorRepository/*.Where(t => t.IsTrialLevel == false || t.Id == sponsorId)*/.ProjectTo<SponsorSelectDTO>(_mapper.ConfigurationProvider,new { isEn_Us= _userInfo.IsEn_Us});
|
||||
return await sponsorQueryable.ToListAsync();
|
||||
}
|
||||
|
||||
|
|
|
@ -789,10 +789,11 @@ namespace IRaCIS.Application.Services
|
|||
return pageList;
|
||||
}
|
||||
|
||||
[AllowAnonymous]
|
||||
[HttpGet]
|
||||
public async Task<IResponseOutput> LoginOut()
|
||||
public async Task<IResponseOutput> LoginOut(Guid userId)
|
||||
{
|
||||
await _userLogRepository.AddAsync(new UserLog() { IP = _userInfo.IP, LoginUserId = _userInfo.Id, OptUserId = _userInfo.Id, OptType = UserOptType.LoginOut },true);
|
||||
await _userLogRepository.AddAsync(new UserLog() { IP = _userInfo.IP, LoginUserId = userId, OptUserId = _userInfo.Id, OptType = UserOptType.LoginOut }, true);
|
||||
|
||||
return ResponseOutput.Ok();
|
||||
}
|
||||
|
|
|
@ -73,7 +73,7 @@ namespace IRaCIS.Core.Application.Contracts
|
|||
public async Task<IResponseOutput> SendEmialVerifyCode(SendEmialVerifyCodeInDto userInfo)
|
||||
{
|
||||
//检查手机或者邮箱是否有效
|
||||
if (!Regex.IsMatch(userInfo.Email, @"^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$"))
|
||||
if (!Regex.IsMatch(userInfo.Email, @"^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$"))
|
||||
{
|
||||
//---请输入正确的邮箱地址。
|
||||
throw new BusinessValidationFailedException(_localizer["TrialSiteSurvey_InvalidEmail"]);
|
||||
|
@ -139,7 +139,7 @@ namespace IRaCIS.Core.Application.Contracts
|
|||
public async Task<IResponseOutput> SendVerifyCode(SiteSurveySendVerifyCode userInfo)
|
||||
{
|
||||
//检查手机或者邮箱是否有效
|
||||
if (!Regex.IsMatch(userInfo.Email, @"^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$"))
|
||||
if (!Regex.IsMatch(userInfo.Email, @"^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$"))
|
||||
{
|
||||
//---请输入正确的邮箱地址。
|
||||
throw new BusinessValidationFailedException(_localizer["TrialSiteSurvey_InvalidEmail"]);
|
||||
|
|
|
@ -383,7 +383,7 @@ namespace IRaCIS.Application.Services
|
|||
.Select(t => new { t.EMail, t.FirstName, t.LastName }).ToListAsync();
|
||||
|
||||
|
||||
var errorList = emaiList.Where(t => !Regex.IsMatch(t.EMail, @"^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$"))
|
||||
var errorList = emaiList.Where(t => !Regex.IsMatch(t.EMail, @"^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$"))
|
||||
.ToList();
|
||||
|
||||
if (errorList.Count() > 0)
|
||||
|
|
Loading…
Reference in New Issue