初始化 MiGu.Server 项目,包含基本的 ASP.NET Core 8 配置、JWT 鉴权、RBAC 权限管理、YARP 反向代理及相关配置文件。新增 build-and-run 脚本以简化构建与运行流程,添加 README 文档以指导用户快速上手。
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
namespace MiGu.Server.Configs;
|
||||
|
||||
public record ScenarioTemplate(string Id, string Name, string Category, string Version, string BaselineJson);
|
||||
public record TemplateDslPolicy(bool Enabled, string SchemaVersion);
|
||||
public record LowCodePolicy(bool Enabled, string Editor);
|
||||
public record TemplateVersionPolicy(int KeepVersions, bool AllowRollback);
|
||||
|
||||
public record ScenarioTemplateConfig(
|
||||
List<ScenarioTemplate> Templates,
|
||||
TemplateDslPolicy DslPolicy,
|
||||
LowCodePolicy LowCode,
|
||||
TemplateVersionPolicy VersionPolicy)
|
||||
{
|
||||
public static ScenarioTemplateConfig Default() => new(
|
||||
Templates: new List<ScenarioTemplate>
|
||||
{
|
||||
new("tpl-sps", "SPS 物料配送", "SPS", "1.0.0", "{}"),
|
||||
new("tpl-pack", "电池 Pack 自动化产线", "BatteryPack", "1.0.0", "{}"),
|
||||
new("tpl-loop", "环线运行", "Loop", "1.0.0", "{}"),
|
||||
new("tpl-p2p", "点对点柔性搬运", "P2P", "1.0.0", "{}")
|
||||
},
|
||||
DslPolicy: new TemplateDslPolicy(true, "1"),
|
||||
LowCode: new LowCodePolicy(false, "json"),
|
||||
VersionPolicy: new TemplateVersionPolicy(10, true));
|
||||
}
|
||||
Reference in New Issue
Block a user