Uat_Study
he 2022-07-08 11:19:45 +08:00
parent fde57c12cb
commit ec5bf392af
7 changed files with 99 additions and 2 deletions

View File

@ -5746,6 +5746,13 @@
删除协议
</summary>
</member>
<member name="M:IRaCIS.Application.Services.DoctorWorkloadService.SetEnrollReadingCategory(IRaCIS.Application.Contracts.SetEnrollReadingCategoryInDto)">
<summary>
修改项目医生的阅片类型
</summary>
<param name="inDto"></param>
<returns></returns>
</member>
<member name="M:IRaCIS.Application.Services.DoctorWorkloadService.UpdateReviewerReadingType(System.Guid,System.Guid,System.Int32)">
<summary>
0代表裁判和Tp 都可以 1、代表Tp 2 代表裁判

View File

@ -1,4 +1,5 @@
using System.ComponentModel.DataAnnotations;
using IRaCIS.Core.Domain.Share;
using IRaCIS.Core.Infrastructure.Extention;
namespace IRaCIS.Application.Contracts
@ -139,7 +140,13 @@ namespace IRaCIS.Application.Contracts
[Required(ErrorMessage = "需要有效的医生列表")]
public List<Guid> NeedCalculateReviewers { get; set; } = new List<Guid>();
}
public class SetEnrollReadingCategoryInDto
{
[NotDefault]
public Guid EnrollId { get; set; }
public List<ReadingCategory> ReadingCategorys { get; set; }
}
public class WorkLoadDoctorQueryDTO : PageInput
{
public Guid TrialId { get; set; } = Guid.Empty;
@ -218,6 +225,7 @@ namespace IRaCIS.Application.Contracts
public class WorkLoadAndAgreementDTO : WorkLoadAndTrainingDTO
{
public Guid EnrollId { get; set; }
public DateTime? OutEnrollTime { get; set; }
public Guid AgreementId { get; set; }
@ -226,6 +234,9 @@ namespace IRaCIS.Application.Contracts
public string? AgreementFileName => AgreementPath?.Split('/').Last();
public string AgreementFullPath => AgreementPath;
public List<ReadingCategory> ReadingCategorys { get; set; }
}

View File

@ -17,6 +17,7 @@ namespace IRaCIS.Application.Services
private readonly IRepository<Enroll> _enrollRepository;
private readonly IRepository<Doctor> _doctorRepository;
private readonly IRepository<Workload> _doctorWorkloadRepository;
private readonly IRepository<EnrollReadingCategory> _enrollReadingCategoryRepository;
private readonly IRepository<Attachment> _attachmentRepository;
private readonly IRepository<Payment> _costStatisticsRepository;
private readonly IRepository<TrialRevenuesPrice> _trialRevenuesPriceRepository;
@ -27,6 +28,7 @@ namespace IRaCIS.Application.Services
IRepository<Enroll> intoGroupRepository,
IRepository<Doctor> doctorInfoRepository,
IRepository<Workload> doctorWorkloadRepository,
IRepository<EnrollReadingCategory> enrollReadingCategoryRepository,
IRepository<Attachment> attachmentRepository,
IRepository<Payment> costStatisticsRepository,
IRepository<TrialRevenuesPrice> trialRevenuesPriceRepository,
@ -37,6 +39,7 @@ namespace IRaCIS.Application.Services
_enrollRepository = intoGroupRepository;
_doctorRepository = doctorInfoRepository;
_doctorWorkloadRepository = doctorWorkloadRepository;
this._enrollReadingCategoryRepository = enrollReadingCategoryRepository;
_attachmentRepository = attachmentRepository;
_costStatisticsRepository = costStatisticsRepository;
_trialRevenuesPriceRepository = trialRevenuesPriceRepository;
@ -93,6 +96,31 @@ namespace IRaCIS.Application.Services
return ResponseOutput.Result(success1 && success2);
}
/// <summary>
/// 修改项目医生的阅片类型
/// </summary>
/// <param name="inDto"></param>
/// <returns></returns>
[TypeFilter(typeof(TrialResourceFilter))]
[Authorize(Policy = IRaCISPolicy.PM_APM)]
public async Task<IResponseOutput> SetEnrollReadingCategory(SetEnrollReadingCategoryInDto inDto)
{
await _enrollReadingCategoryRepository.BatchDeleteNoTrackingAsync(x => x.EnrollId == inDto.EnrollId);
List<EnrollReadingCategory> enrollReadings = inDto.ReadingCategorys.Select(x => new EnrollReadingCategory()
{
EnrollId = inDto.EnrollId,
ReadingCategory = x
}).ToList();
await _enrollReadingCategoryRepository.AddRangeAsync(enrollReadings);
var result = await _enrollReadingCategoryRepository.SaveChangesAsync();
return ResponseOutput.Ok(result);
}
/// <summary>
/// 0代表裁判和Tp 都可以 1、代表Tp 2 代表裁判
/// </summary>
@ -148,7 +176,8 @@ namespace IRaCIS.Application.Services
select new WorkLoadAndAgreementDTO()
{
EnrollId= intoGroup.Id,
ReadingCategorys = intoGroup.EnrollReadingCategoryList.Select(x=>x.ReadingCategory).ToList(),
DoctorId = doctor.Id,
Code = doctor.ReviewerCode,
FirstName = doctor.FirstName,

View File

@ -1,4 +1,5 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models
@ -56,5 +57,8 @@ namespace IRaCIS.Core.Domain.Models
public int DoctorTrialState { get; set; }
public List<EnrollReadingCategory> EnrollReadingCategoryList { get; set; }
}
}

View File

@ -0,0 +1,42 @@
//--------------------------------------------------------------------
// 此代码由T4模板自动生成 byzhouhang 20210918
// 生成时间 2022-07-08 10:43:53
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
using System;
using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models
{
///<summary>
///EnrollReadingCategory
///</summary>
[Table("EnrollReadingCategory")]
public class EnrollReadingCategory : Entity, IAuditAdd
{
/// <summary>
/// EnrollId
/// </summary>
public Guid EnrollId { get; set; }
/// <summary>
/// ReadingCategory
/// </summary>
public ReadingCategory ReadingCategory { get; set; }
/// <summary>
/// CreateUserId
/// </summary>
public Guid CreateUserId { get; set; }
/// <summary>
/// CreateTime
/// </summary>
public DateTime CreateTime { get; set; }
[ForeignKey("EnrollId")]
public Enroll Enroll { get; set; }
}
}

View File

@ -184,6 +184,10 @@ namespace IRaCIS.Core.Infra.EFCore
public virtual DbSet<Workload> DoctorWorkload { get; set; }
public virtual DbSet<Enroll> IntoGroup { get; set; }
public virtual DbSet<EnrollReadingCategory> EnrollReadingCategory { get; set; }
public virtual DbSet<EnrollDetail> EnrollDetails { get; set; }

View File

@ -4,7 +4,7 @@
public static readonly string ConnectionString = "Server=123.56.94.154,1433\\MSSQLSERVER;Database=IRaCIS_New_Tet;User ID=sa;Password=dev123456DEV;TrustServerCertificate=true";
public static readonly string DbDatabase = "IRaCIS_New_Tet";
//表名称用字符串,拼接
public static readonly string TableName = "TaskConsistentRule";
public static readonly string TableName = "EnrollReadingCategory";
//具体文件里面 例如service 可以配置是否分页
}
#>