[修改计费系统路径问题]

master
hang 2024-01-26 12:56:18 +08:00
parent f6af2bba91
commit 747f1777dc
6 changed files with 28 additions and 24 deletions

View File

@ -50,7 +50,7 @@ namespace IRaCIS.Api.Controllers
_hostEnvironment = hostEnvironment;
_webHostEnvironment = webHostEnvironment;
_fileSizeLimit = config.GetValue<long>("FileSizeLimit");
defaultUploadFilePath = Directory.GetParent(_hostEnvironment.ContentRootPath).FullName;
defaultUploadFilePath = Path.GetFullPath(Path.Combine(webHostEnvironment.ContentRootPath, ".."));
_logger = logger;
_logger.LogError("File Path:"+ defaultUploadFilePath);

View File

@ -71,7 +71,7 @@
</ItemGroup>
<ItemGroup>
<Content Update="nlog.config">
<Content Update="nLog.config">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Update="wwwroot\Template\Payment Summary.xlsx">

View File

@ -4,7 +4,7 @@
xsi:schemaLocation="http://www.nlog-project.org/schemas/NLog.xsd NLog.xsd"
autoReload="true"
throwExceptions="true"
internalLogLevel="Off" internalLogFile="c:\temp\nlog-internal.log">
internalLogLevel="Off" >
<targets>
<target xsi:type="File" name="file" fileName="${basedir}/logs/${shortdate}.log"

Binary file not shown.

View File

@ -10,12 +10,15 @@ using IRaCIS.Core.Domain.Share;
using IRaCIS.WX.CoreApi.Utility;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Http.Features;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.FileProviders;
using Microsoft.Extensions.Hosting;
using Newtonsoft.Json;
using System;
using System.IO;
using System.Reflection;
namespace IRaCIS.Core.API
@ -64,11 +67,11 @@ namespace IRaCIS.Core.API
services.AddControllers().AddNewtonsoftJson(options =>
{
// 忽略循环引用
// 忽略循环引用
options.SerializerSettings.ReferenceLoopHandling = ReferenceLoopHandling.Serialize;
// 不使用驼峰
// 不使用驼峰
options.SerializerSettings.ContractResolver = new NullToEmptyStringResolver(); //new DefaultContractResolver();// new NullToEmptyStringResolver();
// 设置时间格式
// 设置时间格式
options.SerializerSettings.DateFormatString = "yyyy-MM-dd HH:mm:ss";
});
@ -118,7 +121,7 @@ namespace IRaCIS.Core.API
{
if (env.IsDevelopment())
{
////不能放在静态方法中
////不能放在静态方法中
//app.UseSwaggerUI(options =>
//{
// options.IndexStream = () =>
@ -132,12 +135,15 @@ namespace IRaCIS.Core.API
app.UseStaticFiles();
//app.UseStaticFiles(new StaticFileOptions()
//{
// FileProvider = new PhysicalFileProvider(
// Path.Combine(Directory.GetCurrentDirectory(), @"UploadFile")),
// RequestPath = new PathString("/UploadFile")
//});
app.UseStaticFiles(new StaticFileOptions()
{
FileProvider = new PhysicalFileProvider(
Path.Combine(Path.GetFullPath(Path.Combine(env.ContentRootPath, "..")), @"UploadFile")),
RequestPath = new PathString("/UploadFile"),
ServeUnknownFileTypes = true,
DefaultContentType = "application/octet-stream"
});
//app.UseMiddleware<AuthMiddleware>();

View File

@ -1,9 +1,7 @@
{
"ConnectionStrings": {
// "RemoteNew": "Server=101.132.193.237,1434;Database=IRaCIS_History_Cost;User ID=sa;Password=zhanying@2021;", --
"RemoteNew": "Server=123.56.94.154,1433\\MSSQLSERVER;Database=IRaCIS_P;User ID=sa;Password=dev123456DEV;",
"RemoteNew": "Server=192.168.3.68,1434;Database=IRaCIS_B;User ID=sa;Password=xc@123456;",
"hang": "Server=ZHOU;Database=IRaCIS;User ID=sa;Password=sa123456;"
//"RemoteTest": "Server=123.56.181.144,14333\\MSSQLExpress14;Database=IRaCIS_B;User ID=sa;Password=dev123456DEV;"
},
"Logging": {
"IncludeScopes": false,
@ -15,20 +13,20 @@
},
"AllowedHosts": "*",
"JwtSetting": {
"SecurityKey": "3e6dbfa227234a03977a2f421bdb7f4f", // <EFBFBD><EFBFBD>Կ
"Issuer": "jwtIssuertest1", // <EFBFBD><EFBFBD><EFBFBD>
"Audience": "jwtAudiencetest1", // <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
"TokenExpireDays": "7" // <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>7day<EFBFBD><EFBFBD>
"SecurityKey": "3e6dbfa227234a03977a2f421bdb7f4f",
"Issuer": "jwtIssuertest1",
"Audience": "jwtAudiencetest1",
"TokenExpireDays": "7"
},
"RootUrl": "http://123.56.181.144:8000",
"RootUrl": "http://192.168.3.68:9030",
"CodePrefix": "RE",
"UserCodePrefix": "U",
"VisitPlanNumPrefix": "VT",
"StoredFilesPath": "D:\\Upload", //<EFBFBD>ýڵ<EFBFBD>û<EFBFBD>õ<EFBFBD>
"DicomFileArchivedPath": "D:\\Upload", //
"StoredFilesPath": "D:\\Upload",
"DicomFileArchivedPath": "D:\\Upload",
"Share": false, //
"FileSizeLimit": 1073741824,
"LoginExpiredTimeSpan": "<EFBFBD><EFBFBD>15", // Minute
"LoginExpiredTimeSpan": "15", // Minute
"OpenLog": true,
"AddClinicalInfo": true,
"easycaching": {