diff --git a/Service/FireControl/Client/FireControlMgr.cs b/Service/FireControl/Client/FireControlMgr.cs index 1734d1e..d9255e5 100644 --- a/Service/FireControl/Client/FireControlMgr.cs +++ b/Service/FireControl/Client/FireControlMgr.cs @@ -7,14 +7,14 @@ namespace Service.FireControl.Client; public class FireControlMgr { - public static Subzone2 Subzone2 { get; set; } - public static Subzone3 Subzone3 { get; set; } - public static Subzone4 Subzone4 { get; set; } - public static Subzone5 Subzone5 { get; set; } - public static Subzone6 Subzone6 { get; set; } - public static Subzone7 Subzone7 { get; set; } - public static Subzone8 Subzone8 { get; set; } - public static Subzone9 Subzone9 { get; set; } + public static Subzone2 Subzone2 = new Subzone2(); + public static Subzone3 Subzone3 = new Subzone3(); + public static Subzone4 Subzone4 = new Subzone4(); + public static Subzone5 Subzone5 = new Subzone5(); + public static Subzone6 Subzone6 = new Subzone6(); + public static Subzone7 Subzone7 = new Subzone7(); + public static Subzone8 Subzone8 = new Subzone8(); + public static Subzone9 Subzone9 = new Subzone9(); public static FireControlClient? FireControlClient { get; set; } diff --git a/WebStarter/Controllers/FireControlController.cs b/WebStarter/Controllers/FireControlController.cs index e8b858d..1ea9adc 100644 --- a/WebStarter/Controllers/FireControlController.cs +++ b/WebStarter/Controllers/FireControlController.cs @@ -1,6 +1,7 @@ using HybirdFrameworkCore.Entity; using Microsoft.AspNetCore.Mvc; using Service.FireControl.Client; +using Service.FireControl.Msg; namespace WebStarter.Controllers; @@ -178,5 +179,84 @@ public class FireControlController { return Result.Success(FireControlMgr.AutomaticModeOff()); } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone2")] + public Result GetSubzone2() + { + return Result.Success(FireControlMgr.Subzone2); + } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone3")] + public Result GetSubzone3() + { + return Result.Success(FireControlMgr.Subzone3); + } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone4")] + public Result GetSubzone4() + { + return Result.Success(FireControlMgr.Subzone4); + } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone5")] + public Result GetSubzone5() + { + return Result.Success(FireControlMgr.Subzone5); + } + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone2")] + public Result GetSubzone6() + { + return Result.Success(FireControlMgr.Subzone6); + } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone7")] + public Result GetSubzone7() + { + return Result.Success(FireControlMgr.Subzone7); + } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone2")] + public Result GetSubzone8() + { + return Result.Success(FireControlMgr.Subzone8); + } + + /// + /// 获取读取到的信息 + /// + /// + [HttpGet("GetSubzone9")] + public Result GetSubzone9() + { + return Result.Success(FireControlMgr.Subzone9); + } } \ No newline at end of file