修改文档返回状态
parent
cbfc2f9538
commit
a21cca53f8
|
@ -58,12 +58,7 @@ namespace IRaCIS.Core.Application.Contracts
|
||||||
public string RealName { get; set; } = string.Empty;
|
public string RealName { get; set; } = string.Empty;
|
||||||
|
|
||||||
|
|
||||||
//[JsonIgnore]
|
public string DocTypeCode { get; set; }
|
||||||
//public string IdentityUserTypes { get; set; }
|
|
||||||
|
|
||||||
//[JsonIgnore]
|
|
||||||
//public string DocNeedSignUserTypes { get; set; }
|
|
||||||
|
|
||||||
|
|
||||||
public List<string> UserConfirmedUserTypeList => (DocNeedSignUserTypeList != null && IdentityUserTypeList != null) ? IdentityUserTypeList.Intersect(DocNeedSignUserTypeList).ToList() : new List<string>();
|
public List<string> UserConfirmedUserTypeList => (DocNeedSignUserTypeList != null && IdentityUserTypeList != null) ? IdentityUserTypeList.Intersect(DocNeedSignUserTypeList).ToList() : new List<string>();
|
||||||
|
|
||||||
|
|
|
@ -150,7 +150,7 @@ namespace IRaCIS.Core.Application.Services
|
||||||
var query = from sysDoc in _systemDocumentRepository.AsQueryable(true)
|
var query = from sysDoc in _systemDocumentRepository.AsQueryable(true)
|
||||||
.Where(t => t.NeedConfirmedUserTypeList.Any(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId))
|
.Where(t => t.NeedConfirmedUserTypeList.Any(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId))
|
||||||
.WhereIf(!string.IsNullOrEmpty(inQuery.Name), t => t.Name.Contains(inQuery.Name))
|
.WhereIf(!string.IsNullOrEmpty(inQuery.Name), t => t.Name.Contains(inQuery.Name))
|
||||||
//外部人员 只签署 文档类型枚举值有值的
|
//外部人员 只签署 外部需要签署的
|
||||||
.WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter)
|
.WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter)
|
||||||
.WhereIf(inQuery.FileTypeId != null, t => t.FileTypeId == inQuery.FileTypeId)
|
.WhereIf(inQuery.FileTypeId != null, t => t.FileTypeId == inQuery.FileTypeId)
|
||||||
join confirm in _systemDocConfirmedUserRepository.Where() on new { ConfirmUserId = _userInfo.IdentityUserId, SystemDocumentId = sysDoc.Id } equals new { confirm.ConfirmUserId, confirm.SystemDocumentId } into cc
|
join confirm in _systemDocConfirmedUserRepository.Where() on new { ConfirmUserId = _userInfo.IdentityUserId, SystemDocumentId = sysDoc.Id } equals new { confirm.ConfirmUserId, confirm.SystemDocumentId } into cc
|
||||||
|
@ -178,6 +178,8 @@ namespace IRaCIS.Core.Application.Services
|
||||||
RealName = user.FullName,
|
RealName = user.FullName,
|
||||||
UserName = user.UserName,
|
UserName = user.UserName,
|
||||||
|
|
||||||
|
DocTypeCode=sysDoc.FileType.Code
|
||||||
|
|
||||||
//UserTypeId = user.UserTypeId,
|
//UserTypeId = user.UserTypeId,
|
||||||
//UserTypeShortName = user.UserTypeRole.UserTypeShortName
|
//UserTypeShortName = user.UserTypeRole.UserTypeShortName
|
||||||
};
|
};
|
||||||
|
@ -187,7 +189,7 @@ namespace IRaCIS.Core.Application.Services
|
||||||
.Where(t => !(t.IsDeleted == true && t.ConfirmTime == null))
|
.Where(t => !(t.IsDeleted == true && t.ConfirmTime == null))
|
||||||
.WhereIf(inQuery.IsSigned == true, t => t.ConfirmTime != null)
|
.WhereIf(inQuery.IsSigned == true, t => t.ConfirmTime != null)
|
||||||
.WhereIf(inQuery.IsSigned == false, t => t.ConfirmTime == null)
|
.WhereIf(inQuery.IsSigned == false, t => t.ConfirmTime == null)
|
||||||
.ToPagedListAsync(inQuery);
|
.ToPagedListAsync(inQuery,nameof(UnionDocumentWithConfirmInfoView.DocTypeCode));
|
||||||
|
|
||||||
|
|
||||||
return list;
|
return list;
|
||||||
|
|
|
@ -461,6 +461,8 @@ namespace IRaCIS.Core.Application.Contracts
|
||||||
|
|
||||||
public bool IsHaveSysDocNeedNeedSign { get; set; }
|
public bool IsHaveSysDocNeedNeedSign { get; set; }
|
||||||
|
|
||||||
|
public bool IsFirstSysDocNeedSign { get; set; }
|
||||||
|
|
||||||
//public List<TrialDocNeedSign> TrialNeedSignList { get; set; }=new List<TrialDocNeedSign>();
|
//public List<TrialDocNeedSign> TrialNeedSignList { get; set; }=new List<TrialDocNeedSign>();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -665,7 +665,7 @@ namespace IRaCIS.Core.Application
|
||||||
{
|
{
|
||||||
|
|
||||||
var query = _trialRepository.Where(t => t.TrialStatusStr == StaticData.TrialState.TrialOngoing)
|
var query = _trialRepository.Where(t => t.TrialStatusStr == StaticData.TrialState.TrialOngoing)
|
||||||
.Where(t => t.TrialIdentityUserList.Any(t => t.IdentityUserId == _userInfo.IdentityUserId && t.TrialUserRoleList.Any(t=>t.UserRole.UserTypeId==_userInfo.UserTypeId)))
|
.Where(t => t.TrialIdentityUserList.Any(t => t.IdentityUserId == _userInfo.IdentityUserId && t.TrialUserRoleList.Any(t => t.UserRole.UserTypeId == _userInfo.UserTypeId)))
|
||||||
.Where(t => t.QCProcessEnum != TrialQCProcess.NotAudit)
|
.Where(t => t.QCProcessEnum != TrialQCProcess.NotAudit)
|
||||||
.Select(t => new ImageQualityToBeDoneDto()
|
.Select(t => new ImageQualityToBeDoneDto()
|
||||||
{
|
{
|
||||||
|
@ -1124,10 +1124,18 @@ namespace IRaCIS.Core.Application
|
||||||
|
|
||||||
var needSignSysDocCont = await _systemDocumentRepository.AsQueryable(true)
|
var needSignSysDocCont = await _systemDocumentRepository.AsQueryable(true)
|
||||||
.Where(t => t.IsDeleted == false && !t.SystemDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null))
|
.Where(t => t.IsDeleted == false && !t.SystemDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null))
|
||||||
//外部人员 只签署 文档类型枚举值有值的
|
//外部人员 只签署 外部需要签署的
|
||||||
.WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter)
|
.WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter)
|
||||||
.SelectMany(t => t.NeedConfirmedUserTypeList)
|
.SelectMany(t => t.NeedConfirmedUserTypeList)
|
||||||
.CountAsync(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId);
|
.CountAsync(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId);
|
||||||
|
//电子阅片声明是否已经签署
|
||||||
|
|
||||||
|
var isfirstSysDocNeedSign = await _systemDocumentRepository.AsQueryable(true)
|
||||||
|
.Where(t => t.IsDeleted == false && !t.SystemDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null))
|
||||||
|
//外部人员 只签署 外部需要签署的
|
||||||
|
.WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter)
|
||||||
|
.SelectMany(t => t.NeedConfirmedUserTypeList)
|
||||||
|
.AnyAsync(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId && t.SystemDocument.FileType.Code == "-1");
|
||||||
|
|
||||||
var signedTrialCount = await _trialDocumentRepository.AsQueryable(true)
|
var signedTrialCount = await _trialDocumentRepository.AsQueryable(true)
|
||||||
.Where(t => t.Trial.TrialIdentityUserList.Any(t => t.IdentityUserId == _userInfo.IdentityUserId && t.TrialUserRoleList.Any(t => t.UserRole.UserTypeId == _userInfo.UserTypeId)))
|
.Where(t => t.Trial.TrialIdentityUserList.Any(t => t.IdentityUserId == _userInfo.IdentityUserId && t.TrialUserRoleList.Any(t => t.UserRole.UserTypeId == _userInfo.UserTypeId)))
|
||||||
|
@ -1170,7 +1178,7 @@ namespace IRaCIS.Core.Application
|
||||||
|
|
||||||
var record = new UserToBeDoneRecord()
|
var record = new UserToBeDoneRecord()
|
||||||
{
|
{
|
||||||
|
IsFirstSysDocNeedSign= isfirstSysDocNeedSign,
|
||||||
IsHaveSysDocNeedNeedSign = needSignSysDocCont > 0,
|
IsHaveSysDocNeedNeedSign = needSignSysDocCont > 0,
|
||||||
//TrialNeedSignList= trialNeedSignList,
|
//TrialNeedSignList= trialNeedSignList,
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue