namespace MiaoYu.Core.CodeGenerator.Abstractions;
///
/// 数据源配置
///
public class DataSourceConfig
{
///
/// 数据库标识(如:Admin, MiaoYuChat, LiveForum)
///
public string DatabaseKey { get; set; } = string.Empty;
///
/// 显示名称
///
public string DisplayName { get; set; } = string.Empty;
///
/// 实体项目命名空间
///
public string EntityNamespace { get; set; } = string.Empty;
///
/// 实体类路径模板(支持占位符:{RootPath}, {Namespace}, {EntityName}, {EntityNamePlural}, {TableName})
///
public string ModelPathTemplate { get; set; } = string.Empty;
///
/// 服务层路径模板
///
public string ServicePathTemplate { get; set; } = string.Empty;
///
/// 控制器路径模板
///
public string ControllerPathTemplate { get; set; } = string.Empty;
///
/// 前端Index页面路径模板
///
public string ClientIndexPathTemplate { get; set; } = string.Empty;
///
/// 前端Info页面路径模板
///
public string ClientInfoPathTemplate { get; set; } = string.Empty;
///
/// 前端Service路径模板
///
public string ClientServicePathTemplate { get; set; } = string.Empty;
///
/// 代码生成模板目录
///
public string TemplatePath { get; set; } = string.Empty;
///
/// 实体类命名规则(保持原名 or 驼峰转换)
///
public EntityNamingStrategy NamingStrategy { get; set; }
///
/// 排序权重(数字越小越靠前)
///
public int Order { get; set; }
///
/// 是否启用实体类名前缀(用于避免多数据源同名表冲突)
///
public bool EnableEntityPrefix { get; set; } = false;
///
/// 实体类名前缀(如:Chat、Forum)
///
public string EntityPrefix { get; set; } = string.Empty;
///
/// 是否使用复数形式的路径(如 /Users/ vs /User/)
///
public bool UsesPluralPath { get; set; } = true;
}