MC LastMessage to LastState

This commit is contained in:
Thomas Fransolet 2020-03-31 14:53:33 +02:00
parent 8ff0ffaa99
commit 8934a860fc
2 changed files with 11 additions and 8 deletions

View File

@ -23,6 +23,8 @@ namespace MyCore.DTO.MyControlPanel
public LocationDTO Location { get; set; } public LocationDTO Location { get; set; }
public DateTime LastStateDate { get; set; }
public bool Battery { get; set; } public bool Battery { get; set; }
public int BatteryStatus { get; set; } public int BatteryStatus { get; set; }
@ -54,9 +56,9 @@ namespace MyCore.DTO.MyControlPanel
public DateTime UpdatedDate { get; set; } public DateTime UpdatedDate { get; set; }
public string LastMessage { get; set; } // TODO UNIFORMISATION ? public string LastState { get; set; } // TODO UNIFORMISATION ?
public DateTime LastMessageDate { get; set; } public DateTime LastStateDate { get; set; }
public string IpAddress { get; set; } public string IpAddress { get; set; }

View File

@ -53,11 +53,11 @@ namespace MyCore.Models.MyControlPanel.Database
[BsonElement("UpdatedDate")] [BsonElement("UpdatedDate")]
public DateTime UpdatedDate { get; set; } public DateTime UpdatedDate { get; set; }
[BsonElement("LastMessage")] [BsonElement("LastState")]
public string LastMessage { get; set; } // TODO UNIFORMISATION ? public string LastState { get; set; } // TODO UNIFORMISATION ?
[BsonElement("LastMessageDate")] [BsonElement("LastStateDate")]
public DateTime LastMessageDate { get; set; } public DateTime LastStateDate { get; set; }
[BsonElement("IpAddress")] [BsonElement("IpAddress")]
public string IpAddress { get; set; } public string IpAddress { get; set; }
@ -95,6 +95,7 @@ namespace MyCore.Models.MyControlPanel.Database
ConnectionStatus = ConnectionStatus, ConnectionStatus = ConnectionStatus,
LocationId = LocationId, // Check if correct way LocationId = LocationId, // Check if correct way
// Location = // Location =
LastStateDate = LastStateDate,
Battery = Battery, Battery = Battery,
BatteryStatus = BatteryStatus BatteryStatus = BatteryStatus
}; };
@ -116,8 +117,8 @@ namespace MyCore.Models.MyControlPanel.Database
MeansOfCommunications = MeansOfCommunications, MeansOfCommunications = MeansOfCommunications,
CreatedDate = CreatedDate, CreatedDate = CreatedDate,
UpdatedDate = UpdatedDate, UpdatedDate = UpdatedDate,
LastMessage = LastMessage, LastState = LastState,
LastMessageDate = LastMessageDate, LastStateDate = LastStateDate,
IpAddress = IpAddress, IpAddress = IpAddress,
ServiceIdentification = ServiceIdentification, ServiceIdentification = ServiceIdentification,
ProviderId = ProviderId, ProviderId = ProviderId,