using System.Text; using Common.Util; using HybirdFrameworkCore.Autofac.Attribute; using NewLife.Remoting; using Newtonsoft.Json; using Service.Cloud.Common; using Service.Cloud.Msg.Cloud.OutCharger.Req; namespace Service.Cloud.Handler.OutCharger; [Scope("InstancePerDependency")] public class PileStartChargeHandler : IBaseHandler { public bool CanHandle(string cmd) { return CloudConst.pileStartCharge == cmd; } public void Handle(string t) { PileStartCharge? pileStartCharge = JsonConvert.DeserializeObject(t); if (pileStartCharge != null) { HttpUtil.SendPostRequest(pileStartCharge, "http://127.0.0.1:5035/api/OutCharger/SendStartOutCharger"); } } }