feat: migrate boiler control implementation to BoilerMonitor namespace and add budget handling logic
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
using HomeAssistant.Models;
|
||||
using NetDaemon.Extensions.MqttEntityManager;
|
||||
|
||||
namespace BoilerMonitor.Models;
|
||||
|
||||
public class BoilerMonitorEntity : EntityCreateModel
|
||||
{
|
||||
public string Domain { get; set; }
|
||||
public string Identifier { get; set; }
|
||||
public string Name { get; set; }
|
||||
|
||||
public BoilerMonitorEntity(string domain, string identifier, string name)
|
||||
{
|
||||
Domain = domain;
|
||||
Identifier = identifier;
|
||||
EntityId = $"{Domain}.{Identifier}";
|
||||
Name = string.IsNullOrWhiteSpace(name) ? identifier : name;
|
||||
|
||||
Options = new EntityCreationOptions
|
||||
{
|
||||
UniqueId = EntityId,
|
||||
Name = Name
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user