This commit is contained in:
he
2022-04-20 20:52:03 +08:00
parent 04ba060c84
commit ca94b33d7c
6 changed files with 40 additions and 4 deletions
@@ -20,6 +20,7 @@ using IRaCIS.Core.Infrastructure.Extention;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Newtonsoft.Json;
namespace IRaCIS.Core.API.Controllers
{
@@ -33,6 +34,7 @@ namespace IRaCIS.Core.API.Controllers
private readonly IUserInfo _userInfo;
private readonly ITrialDocumentService _trialDocumentService;
private readonly IQCListService _qCListService;
private readonly IHttpContextAccessor _httpContext;
private readonly ITrialConfigService _trialConfigService;
private readonly INoneDicomStudyService _noneDicomStudyService;
private readonly ISubjectService _subjectService;
@@ -51,6 +53,7 @@ namespace IRaCIS.Core.API.Controllers
ITrialDocumentService trialDocumentService,
IRepository<DataInspection> dataInspectionRepository,
IQCListService _qCListService,
IHttpContextAccessor httpContext,
IInspectionService sinspectionService,
ITrialConfigService _trialConfigService,
INoneDicomStudyService noneDicomStudyService,
@@ -68,6 +71,7 @@ namespace IRaCIS.Core.API.Controllers
this._inspectionService = sinspectionService;
this._trialDocumentService = trialDocumentService;
this._qCListService = _qCListService;
this._httpContext = httpContext;
this._trialConfigService = _trialConfigService;
this._noneDicomStudyService = noneDicomStudyService;
this._subjectService = _subjectService;
@@ -353,7 +357,23 @@ namespace IRaCIS.Core.API.Controllers
return await _inspectionService.Enforcement(opt.OptCommand, opt.AuditInfo, opt.SignInfo, fun);
}
/// <summary>
/// 一致性核查 excel上传 支持三种格式
/// </summary>
/// <param name="opt"></param>
/// <returns></returns>
[HttpPost, Route("Inspection/QCOperation/UploadVisitCheckExcel")]
[UnitOfWork]
public async Task<IResponseOutput> UploadVisitCheckExcel(IFormFile file, [FromForm]UploadVisitCheckExcelDto opt)
{
var fun = await _qCOperationService.UploadVisitCheckExcel(file, opt.trialId);
var data = JsonConvert.DeserializeObject<DataInspectionAddDTO>(opt.AuditInfo);
return await _inspectionService.Enforcement(opt.trialId, data, null, null, fun);
}
#endregion
#region