修改设置文档浏览时间
parent
440a3f0554
commit
7403a853f7
|
@ -4,6 +4,7 @@
|
||||||
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
|
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
|
||||||
//--------------------------------------------------------------------
|
//--------------------------------------------------------------------
|
||||||
|
|
||||||
|
using System.Runtime.InteropServices.ComTypes;
|
||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using IRaCIS.Core.Infra.EFCore;
|
using IRaCIS.Core.Infra.EFCore;
|
||||||
using Microsoft.AspNetCore.Hosting;
|
using Microsoft.AspNetCore.Hosting;
|
||||||
|
@ -24,7 +25,7 @@ namespace IRaCIS.Core.Application.Services
|
||||||
private readonly IRepository<TrialDocument> _trialDocumentRepository;
|
private readonly IRepository<TrialDocument> _trialDocumentRepository;
|
||||||
private readonly IRepository<SystemDocument> _systemDocumentRepository;
|
private readonly IRepository<SystemDocument> _systemDocumentRepository;
|
||||||
|
|
||||||
public TrialDocumentService( IRepository<TrialDocument> trialDocumentRepository
|
public TrialDocumentService(IRepository<TrialDocument> trialDocumentRepository
|
||||||
, IRepository<SystemDocument> systemDocumentRepository)
|
, IRepository<SystemDocument> systemDocumentRepository)
|
||||||
{
|
{
|
||||||
_trialDocumentRepository = trialDocumentRepository;
|
_trialDocumentRepository = trialDocumentRepository;
|
||||||
|
@ -497,6 +498,24 @@ namespace IRaCIS.Core.Application.Services
|
||||||
return ResponseOutput.Result(success);
|
return ResponseOutput.Result(success);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[HttpPut("{documentId:guid}")]
|
||||||
|
public async Task<IResponseOutput> SetSystemDocFirstViewTime(Guid documentId)
|
||||||
|
{
|
||||||
|
await _repository.AddAsync(new SystemDocConfirmedUser() { SystemDocumentId = documentId, SignFirstViewTime = DateTime.Now });
|
||||||
|
var success = await _repository.SaveChangesAsync();
|
||||||
|
|
||||||
|
return ResponseOutput.Result(success);
|
||||||
|
}
|
||||||
|
|
||||||
|
[HttpPut("{trialId:guid}/{documentId:guid}")]
|
||||||
|
public async Task<IResponseOutput> SetTrialDocFirstViewTime(Guid documentId)
|
||||||
|
{
|
||||||
|
await _repository.AddAsync(new TrialDocUserTypeConfirmedUser() { TrialDocumentId = documentId, SignFirstViewTime = DateTime.Now });
|
||||||
|
var success = await _repository.SaveChangesAsync();
|
||||||
|
|
||||||
|
return ResponseOutput.Result(success);
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 用户 签名某个文档
|
/// 用户 签名某个文档
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
Loading…
Reference in New Issue