Merge branch 'Test_IRC_Net8' of https://gitea.frp.extimaging.com/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
a12db2637e
|
@ -11,6 +11,7 @@ using IRaCIS.Core.Application.ViewModel;
|
|||
using IRaCIS.Core.Infrastructure.Extention;
|
||||
using System.Threading.Tasks;
|
||||
using IRaCIS.Core.Infra.EFCore;
|
||||
using IRaCIS.Core.Infrastructure;
|
||||
namespace IRaCIS.Core.Application.Service;
|
||||
|
||||
/// <summary>
|
||||
|
@ -58,17 +59,12 @@ public class TrialFinalRecordService(IRepository<TrialFinalRecord> _trialFinalRe
|
|||
if (inDto.SignFileRecord != null) inDto.SignFileRecord.TrialFileTypeId = inDto.TrialFileTypeId;
|
||||
if (inDto.HistoryFileRecord != null) inDto.HistoryFileRecord.TrialFileTypeId = inDto.TrialFileTypeId;
|
||||
|
||||
|
||||
|
||||
|
||||
var verifyExp = new EntityVerifyExp<TrialFinalRecord>()
|
||||
if (await _trialFinalRecordRepository.AnyAsync(x => x.Id != inDto.Id && x.TrialFileTypeId == inDto.TrialFileTypeId && x.Name == inDto.Name && x.Version == inDto.Version))
|
||||
{
|
||||
VerifyExp = u => u.Name == inDto.Name,
|
||||
throw new BusinessValidationFailedException(_localizer["TrialFinalRecord_NameRepeat"]);
|
||||
}
|
||||
|
||||
// "当前类型启用的文件类型名称重复"
|
||||
VerifyMsg = _localizer["TrialFileType_NameRepeat"],
|
||||
|
||||
};
|
||||
if (inDto.Id != null)
|
||||
{
|
||||
var trialFinalRecord = await _trialFinalRecordRepository.Where(x => x.Id == inDto.Id.Value).FirstNotNullAsync();
|
||||
|
|
|
@ -150,7 +150,9 @@ namespace IRaCIS.Core.Application.Services
|
|||
{
|
||||
var list = _siteRepository
|
||||
.WhereIf(!string.IsNullOrWhiteSpace(siteName), t => t.SiteName.Contains(siteName) || t.SiteNameCN.Contains(siteName) || t.AliasName.Contains(siteName))
|
||||
.Select(t => new TrialSiteSelect() { SiteId = t.Id, SiteName = _userInfo.IsEn_Us ? t.SiteName : t.SiteNameCN, AliasName = t.AliasName }).ToList();
|
||||
.Select(t => new TrialSiteSelect() { SiteId = t.Id, SiteName = _userInfo.IsEn_Us ? t.SiteName : t.SiteNameCN, AliasName = t.AliasName })
|
||||
.OrderBy(x=>x.SiteName)
|
||||
.ToList();
|
||||
|
||||
return list;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue