Skip to content

Commit

Permalink
Merge pull request #1652 from pkuehnel/feat/removeConfigurabilityForA…
Browse files Browse the repository at this point in the history
…piRefreshInterval

feat(Car): remove configureability of api refresh interval
  • Loading branch information
pkuehnel authored Nov 25, 2024
2 parents 2fca176 + 38d4398 commit f19670b
Show file tree
Hide file tree
Showing 14 changed files with 967 additions and 21 deletions.
1 change: 0 additions & 1 deletion TeslaSolarCharger.Model/Entities/TeslaSolarCharger/Car.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ public class Car
public DateTime? ChargingCommandsRateLimitedUntil { get; set; }
public bool UseBle { get; set; }
public bool UseBleForWakeUp { get; set; }
public int ApiRefreshIntervalSeconds { get; set; }
public string? BleApiBaseUrl { get; set; }
public bool UseFleetTelemetry { get; set; }
public bool UseFleetTelemetryForLocationData { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,6 @@ protected override void OnModelCreating(ModelBuilder modelBuilder)
.HasIndex(h => new { h.RestValueConfigurationId, h.Key })
.IsUnique();

modelBuilder.Entity<Car>()
.Property(c => c.ApiRefreshIntervalSeconds)
.HasDefaultValue(500);

var timeListToString = new ValueConverter<List<DateTime>, string?>(
v => JsonConvert.SerializeObject(v),
v => v == null ? new() : JsonConvert.DeserializeObject<List<DateTime>>(v) ?? new List<DateTime>()
Expand Down
Loading

0 comments on commit f19670b

Please sign in to comment.