新增日志

master
rszn 5 months ago
parent 40da862e6a
commit 831b81a074

@ -90,9 +90,9 @@ public class CloudClient : IMqttClientConnectedHandler, IMqttApplicationMessageR
public MsgPair<VehicleDataReporting, VehicleDataReportingResp> VehicleData { get; set; } = new(); public MsgPair<VehicleDataReporting, VehicleDataReportingResp> VehicleData { get; set; } = new();
public MsgPair<ChargeRecordUpLoad, ChargeRecordUploadRes> ChargeRecordUpLoad { get; set; } = new(); public MsgPair<ChargeRecordUpLoad, ChargeRecordUploadRes> ChargeRecordUpLoad { get; set; } = new();
public MsgPair<ChargeDevDataInfo, ChargeDevDataInfoRes> ChargeDevDataInfo { get; set; } = new(); public MsgPair<ChargeDevDataInfo, ChargeDevDataInfoRes> ChargeDevDataInfo { get; set; } = new();
public MsgPair<PileEndCharge, PileEndChargeResp> PileEndCharge { get; set; } = new(); public MsgPair<PileEndCharge, PileEndChargeResp> PileEndCharge { get; set; } = new();
public MsgPair<PileChargeRealtime, PileChargeRealtimeResp> PileChargeRealtime { get; set; } = new(); public MsgPair<PileChargeRealtime, PileChargeRealtimeResp> PileChargeRealtime { get; set; } = new();
public MsgPair<PileRealtime, PileRealtimeResp> PileRealtime { get; set; } = new(); public MsgPair<PileRealtime, PileRealtimeResp> PileRealtime { get; set; } = new();
@ -267,7 +267,7 @@ public class CloudClient : IMqttClientConnectedHandler, IMqttApplicationMessageR
DateFormatString = "yyyy-MM-dd HH:mm:ss", DateFormatString = "yyyy-MM-dd HH:mm:ss",
NullValueHandling = NullValueHandling.Ignore NullValueHandling = NullValueHandling.Ignore
}; };
Log.Info(JsonConvert.SerializeObject(model, settings)); Log.Info($"send {JsonConvert.SerializeObject(model, settings)}");
var appMsg = new MqttApplicationMessage var appMsg = new MqttApplicationMessage
{ {
Topic = PubTopic, Topic = PubTopic,
@ -513,21 +513,21 @@ public class CloudClient : IMqttClientConnectedHandler, IMqttApplicationMessageR
this.Publish(req); this.Publish(req);
return ChargeDevDataInfo.GetResp(timeSpan); return ChargeDevDataInfo.GetResp(timeSpan);
} }
public PileEndChargeResp? SendPileEndCharge(PileEndCharge req, TimeSpan? timeSpan = null) public PileEndChargeResp? SendPileEndCharge(PileEndCharge req, TimeSpan? timeSpan = null)
{ {
this.PileEndCharge.Req = req; this.PileEndCharge.Req = req;
this.Publish(req); this.Publish(req);
return PileEndCharge.GetResp(timeSpan); return PileEndCharge.GetResp(timeSpan);
} }
public PileChargeRealtimeResp? SendPileChargeRealtime(PileChargeRealtime req, TimeSpan? timeSpan = null) public PileChargeRealtimeResp? SendPileChargeRealtime(PileChargeRealtime req, TimeSpan? timeSpan = null)
{ {
this.PileChargeRealtime.Req = req; this.PileChargeRealtime.Req = req;
this.Publish(req); this.Publish(req);
return PileChargeRealtime.GetResp(timeSpan); return PileChargeRealtime.GetResp(timeSpan);
} }
public PileRealtimeResp? SendPileRealtime(PileRealtime req, TimeSpan? timeSpan = null) public PileRealtimeResp? SendPileRealtime(PileRealtime req, TimeSpan? timeSpan = null)
{ {
this.PileRealtime.Req = req; this.PileRealtime.Req = req;

Loading…
Cancel
Save