GPSTrackerType.cs 963 B

123456789101112131415161718192021222324
  1. using InABox.Core;
  2. namespace Comal.Classes
  3. {
  4. public class GPSBatteryFormulaModel : IExpressionModel<double>
  5. {
  6. public double BatteryLevel { get; set; }
  7. }
  8. [UserTracking(typeof(GPSTracker))]
  9. public class GPSTrackerType : Entity, IGPSTrackerType, IRemotable, IPersistent, ILicense<GPSTrackerLicense>, IExportable, IImportable
  10. {
  11. [TextBoxEditor(Visible = Visible.Default, Editable = Editable.Enabled)]
  12. public string Description { get; set; }
  13. /// <summary>
  14. /// An expression (see <see cref="CoreExpression"/>) that should always return a percentage battery level remaining.
  15. /// <br/><br/>
  16. /// If null, fills the battery level on GPS Tracker Location with either a voltage or a battery level - whatever OEM returns.
  17. /// </summary>
  18. [ExpressionEditor(typeof(GPSBatteryFormulaModel), Visible = Visible.Optional)]
  19. public string? BatteryFormula { get; set; }
  20. }
  21. }