update API for more simple approach.

This commit is contained in:
programmingPug committed 2025-01-14 17:50:34 -05:00
1 parent 2de48f1fc9
commit f65ead854c
11 files changed
+130 -202

No files matched your search

+1 -1
View File
@@ -13,6 +13,6 @@ namespace SoilMoistureAPI.Models
public string Nickname { get; set; }
// Navigation Property
public ICollection<SoilMoisture> SoilMoistures { get; set; }
//public ICollection<SoilMoisture> SoilMoistures { get; set; }
}
}
@@ -0,0 +1,12 @@
namespace SoilMoistureAPI.Models
{
public class SoilMoistureFlat
{
public int Id { get; set; }
public string DeviceId { get; set; } // Unique identifier for the sensor device
public float MoistureLevel { get; set; } // Current moisture reading
public DateTime Timestamp { get; set; } = DateTime.UtcNow;
public string Nickname { get; set; } // A friendly name for the device
}
}