Admin.Core/src/platform/ZhonTai.Admin/Core/Configs/UploadConfig.cs
(开头部分) 1KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.IO;
namespace ZhonTai.Admin.Core.Configs;
/// <summary>
/// 上传配置
/// </summary>
public class UploadConfig
{
/// <summary>
/// 头像上传配置
/// </summary>
public FileUploadConfig Avatar { get; set; }
/// <summary>
/// 文档图片上传配置
/// </summary>
public FileUploadConfig Document { get; set; }
}
/// <summary>
/// 文件上传配置
/// </summary>
public class FileUploadConfig
{
private string _uploadPath;
/// <summary>
/// 上传路径
/// </summary>
public string UploadPath
{
get
{
if (_uploadPath.IsNull())
{
_uploadPath = Path.Combine(AppContext.BaseDirectory, "upload").ToPath();
}
if (!Path.IsPathRooted(_uploadPath))
{
_uploadPath = Path.Combine(AppContext.BaseDirectory, _uploadPath).ToPath();
}
return _uploadPath;
}
set => _uploadPath = value;
}
/// <summary>
/// 请求路径
/// </summary>
public string RequestPath { get; set; }
/// <summary>
/// 路径格式
/// </summary>
public string Format { get; set; }
后面还有 20 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
