diff --git a/IRaCIS.Core.Application/Service/Common/DTO/InternationalizationViewModel.cs b/IRaCIS.Core.Application/Service/Common/DTO/InternationalizationViewModel.cs
index 2425ca8e9..19498038f 100644
--- a/IRaCIS.Core.Application/Service/Common/DTO/InternationalizationViewModel.cs
+++ b/IRaCIS.Core.Application/Service/Common/DTO/InternationalizationViewModel.cs
@@ -22,7 +22,7 @@ namespace IRaCIS.Core.Application.ViewModel
///InternationalizationQuery 列表查询参数模型
public class InternationalizationQuery : PageInput
{
-
+ public int? State { get; set; }
public string? Description { get; set; }
public string? Code { get; set; }
public string? Value { get; set; }
@@ -36,10 +36,10 @@ namespace IRaCIS.Core.Application.ViewModel
{
public Guid? Id { get; set; }
public int State { get; set; }
- public string Description { get; set; }
+ public string Description { get; set; } = string.Empty;
public string Code { get; set; }
- public string Value { get; set; }
- public string ValueCN { get; set; }
+ public string Value { get; set; } = string.Empty;
+ public string ValueCN { get; set; } = string.Empty;
public int InternationalizationType { get; set; }
}
diff --git a/IRaCIS.Core.Application/Service/Common/InternationalizationService.cs b/IRaCIS.Core.Application/Service/Common/InternationalizationService.cs
index a110049bb..ebbcc3f58 100644
--- a/IRaCIS.Core.Application/Service/Common/InternationalizationService.cs
+++ b/IRaCIS.Core.Application/Service/Common/InternationalizationService.cs
@@ -31,6 +31,9 @@ namespace IRaCIS.Core.Application.Service
var internationalizationQueryable =_internationalizationRepository
.WhereIf(inQuery.Description!=null,t=>t.Description.Contains(inQuery.Description))
.WhereIf(inQuery.Code != null, t => t.Code.Contains(inQuery.Code))
+ .WhereIf(inQuery.State != null, t => t.State==inQuery.State)
+ .WhereIf(inQuery.InternationalizationType != null, t => t.InternationalizationType == inQuery.InternationalizationType)
+
.WhereIf(inQuery.Value != null, t => t.Value.Contains(inQuery.Value))
.WhereIf(inQuery.ValueCN != null, t => t.ValueCN.Contains(inQuery.ValueCN))
.ProjectTo(_mapper.ConfigurationProvider);
diff --git a/IRaCIS.Core.Application/Service/Institution/HospitalService.cs b/IRaCIS.Core.Application/Service/Institution/HospitalService.cs
index 28ba06b8b..2707fb556 100644
--- a/IRaCIS.Core.Application/Service/Institution/HospitalService.cs
+++ b/IRaCIS.Core.Application/Service/Institution/HospitalService.cs
@@ -43,7 +43,7 @@ namespace IRaCIS.Application.Services
};
- var hospital = await _hospitalRepository.InsertOrUpdateAsync(hospitalCommand, true, exp);
+ var hospital = await _hospitalRepository.InsertOrUpdateAsync(hospitalCommand, true, exp,exp1);
return ResponseOutput.Ok(hospital.Id.ToString());
diff --git a/IRaCIS.Core.Application/TestService.cs b/IRaCIS.Core.Application/TestService.cs
index 398e52540..78b43a002 100644
--- a/IRaCIS.Core.Application/TestService.cs
+++ b/IRaCIS.Core.Application/TestService.cs
@@ -1,5 +1,6 @@
using BeetleX.BNR;
using IRaCIS.Core.Application.Service;
+using IRaCIS.Core.Application.ViewModel;
using IRaCIS.Core.Domain.Share;
using IRaCIS.Core.Infrastructure;
using Microsoft.AspNetCore.Authorization;
@@ -7,6 +8,7 @@ using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Caching.Distributed;
using Microsoft.Extensions.Options;
+using MiniExcelLibs;
using System.Linq.Expressions;
using System.Security.Cryptography;
using System.Text;
@@ -43,6 +45,27 @@ namespace IRaCIS.Application.Services
//_cache = cache;
}
+
+
+
+ [AllowAnonymous]
+ public async Task InternationazitionInit()
+ {
+
+
+ var rows = await MiniExcel.QueryAsync(@"C:\Users\Administrator\Desktop\Export\NetCore.xlsx");
+
+ foreach (var row in rows)
+ {
+ await _repository.InsertOrUpdateAsync(row);
+
+ }
+
+ await _repository.SaveChangesAsync();
+
+ return ResponseOutput.Ok();
+ }
+
[UnitOfWork]
public async Task Get()
{
@@ -151,7 +174,7 @@ namespace IRaCIS.Application.Services
[AllowAnonymous]
public async Task testwwwww([FromServices] IWebHostEnvironment env)
{
- await Task.CompletedTask;
+ await Task.CompletedTask;
}