diff --git a/Entity/DbModel/Station/BatteryOpModel.cs b/Entity/DbModel/Station/BatteryOpModel.cs new file mode 100644 index 0000000..fece6bf --- /dev/null +++ b/Entity/DbModel/Station/BatteryOpModel.cs @@ -0,0 +1,67 @@ +using System; +using System.Linq; +using System.Text; +using SqlSugar; + +namespace Entity.DbModel.Station +{ + /// + ///电池运营模型 + /// + [SugarTable("battery_op_model")] + public partial class BatteryOpModel + { + public BatteryOpModel(){ + + + } + /// + /// Desc:id + /// Default: + /// Nullable:False + /// + [SugarColumn(IsPrimaryKey=true,IsIdentity=true,ColumnName="id")] + public int Id {get;set;} + + /// + /// Desc:模型id + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="model_id")] + public int? ModelId {get;set;} + + /// + /// Desc:创建人 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="created_by")] + public string CreatedBy {get;set;} + + /// + /// Desc:创建时间 + /// Default:CURRENT_TIMESTAMP + /// Nullable:True + /// + [SugarColumn(ColumnName="created_time")] + public DateTime? CreatedTime {get;set;} + + /// + /// Desc:更新人 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="updated_by")] + public string UpdatedBy {get;set;} + + /// + /// Desc:更新时间 + /// Default:CURRENT_TIMESTAMP + /// Nullable:True + /// + [SugarColumn(ColumnName="updated_time")] + public DateTime? UpdatedTime {get;set;} + + } +} diff --git a/Entity/DbModel/Station/BatteryOpModelDetail.cs b/Entity/DbModel/Station/BatteryOpModelDetail.cs new file mode 100644 index 0000000..c3213b6 --- /dev/null +++ b/Entity/DbModel/Station/BatteryOpModelDetail.cs @@ -0,0 +1,99 @@ +using System; +using System.Linq; +using System.Text; +using SqlSugar; + +namespace Entity.DbModel.Station +{ + /// + ///电池运营模型详情 + /// + [SugarTable("battery_op_model_detail")] + public partial class BatteryOpModelDetail + { + public BatteryOpModelDetail(){ + + + } + /// + /// Desc:id + /// Default: + /// Nullable:False + /// + [SugarColumn(IsPrimaryKey=true,ColumnName="id")] + public int Id {get;set;} + + /// + /// Desc:模型Id + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="model_id")] + public int? ModelId {get;set;} + + /// + /// Desc:开始时间:06:00:00 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="start_time")] + public string StartTime {get;set;} + + /// + /// Desc:结束时间:06:00:01 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="end_time")] + public string EndTime {get;set;} + + /// + /// Desc:需要电池数量 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="battery_count")] + public int? BatteryCount {get;set;} + + /// + /// Desc:需要电池类型 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="battery_type")] + public string BatteryType {get;set;} + + /// + /// Desc:创建人 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="created_by")] + public string CreatedBy {get;set;} + + /// + /// Desc:创建时间 + /// Default:CURRENT_TIMESTAMP + /// Nullable:True + /// + [SugarColumn(ColumnName="created_time")] + public DateTime? CreatedTime {get;set;} + + /// + /// Desc:更新人 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName="updated_by")] + public string UpdatedBy {get;set;} + + /// + /// Desc:更新时间 + /// Default:CURRENT_TIMESTAMP + /// Nullable:True + /// + [SugarColumn(ColumnName="updated_time")] + public DateTime? UpdatedTime {get;set;} + + } +} diff --git a/Repository/Station/BatteryOpModelDetailRepository.cs b/Repository/Station/BatteryOpModelDetailRepository.cs new file mode 100644 index 0000000..3242768 --- /dev/null +++ b/Repository/Station/BatteryOpModelDetailRepository.cs @@ -0,0 +1,13 @@ +using Entity.DbModel.Station; +using HybirdFrameworkCore.Autofac.Attribute; +using SqlSugar; + +namespace Repository.Station; + +[Scope("SingleInstance")] +public class BatteryOpModelDetailRepository : BaseRepository +{ + public BatteryOpModelDetailRepository(ISqlSugarClient sqlSugar) : base(sqlSugar) + { + } +} \ No newline at end of file diff --git a/Repository/Station/BatteryOpModelRepository.cs b/Repository/Station/BatteryOpModelRepository.cs new file mode 100644 index 0000000..842b8bf --- /dev/null +++ b/Repository/Station/BatteryOpModelRepository.cs @@ -0,0 +1,13 @@ +using Entity.DbModel.Station; +using HybirdFrameworkCore.Autofac.Attribute; +using SqlSugar; + +namespace Repository.Station; + +[Scope("SingleInstance")] +public class BatteryOpModelRepository : BaseRepository +{ + public BatteryOpModelRepository(ISqlSugarClient sqlSugar) : base(sqlSugar) + { + } +} \ No newline at end of file diff --git a/Service/BusinessTask/MyTask/SwapOrderReportCloudTask.cs b/Service/BusinessTask/MyTask/SwapOrderReportCloudTask.cs index 31b5dd0..9dfd932 100644 --- a/Service/BusinessTask/MyTask/SwapOrderReportCloudTask.cs +++ b/Service/BusinessTask/MyTask/SwapOrderReportCloudTask.cs @@ -7,8 +7,8 @@ namespace Service.BusinessTask.MyTask; /// public class SwapOrderReportCloudTask : AbstractTaskHandler { + private static readonly ILog Log = LogManager.GetLogger(typeof(SwapOrderReportCloudTask)); - private static readonly ILog _log = LogManager.GetLogger(typeof(SwapOrderReportCloudTask)); protected override int Interval() { return 20 * 1000; @@ -16,12 +16,10 @@ public class SwapOrderReportCloudTask : AbstractTaskHandler protected override void Handle() { - } protected override string Name() { return "SwapOrderReportCloudTask"; } - } \ No newline at end of file diff --git a/Service/Cloud/Handler/BatteryOperatingModelHandler.cs b/Service/Cloud/Handler/BatteryOperatingModelHandler.cs new file mode 100644 index 0000000..572f2c4 --- /dev/null +++ b/Service/Cloud/Handler/BatteryOperatingModelHandler.cs @@ -0,0 +1,68 @@ +using Entity.DbModel.Station; +using HybirdFrameworkCore.Autofac.Attribute; +using Newtonsoft.Json; +using Repository.Station; +using Service.Cloud.Client; +using Service.Cloud.Common; +using Service.Cloud.Msg.Cloud.Req; +using Service.Cloud.Msg.Host.Resp; + +namespace Service.Cloud.Handler; + +[Scope("InstancePerDependency")] +public class BatteryOperatingModelHandler: IBaseHandler +{ + + private readonly BatteryOpModelRepository _batteryOpModelRepository; + private readonly BatteryOpModelDetailRepository _batteryOpModelDetailRepository; + + public BatteryOperatingModelHandler(BatteryOpModelRepository batteryOpModelRepository, + BatteryOpModelDetailRepository batteryOpModelDetailRepository) + { + _batteryOpModelRepository = batteryOpModelRepository; + _batteryOpModelDetailRepository = batteryOpModelDetailRepository; + } + public bool CanHandle(string cmd) + { + return CloudConst.setOpModel == cmd; + } + + public void Handle(string t) + { + BatteryOperatingModel? req = JsonConvert.DeserializeObject(t); + if (req != null) + { + + BatteryOpModel batteryOpModel = new BatteryOpModel() + { + ModelId = req.oid, + CreatedTime = req.ut + }; + + _batteryOpModelRepository.Insert(batteryOpModel); + + if (req.seg is {Count: > 0}) + { + List list = new(); + foreach (var d in req.seg) + { + list.Add(new BatteryOpModelDetail() + { + ModelId = req.oid, + BatteryType = d.btc, + BatteryCount = d.bc, + StartTime = d.st, + EndTime = d.et + }); + } + + _batteryOpModelDetailRepository.Insert(list); + } + + + + BatteryOperatingModelResp resp = new BatteryOperatingModelResp(); + CloudClientMgr.CloudClient?.Publish(resp); + } + } +} \ No newline at end of file diff --git a/Service/Cloud/Handler/BusinessHourHandler.cs b/Service/Cloud/Handler/BusinessHourHandler.cs new file mode 100644 index 0000000..f69b406 --- /dev/null +++ b/Service/Cloud/Handler/BusinessHourHandler.cs @@ -0,0 +1,36 @@ +using HybirdFrameworkCore.Autofac.Attribute; +using NewLife; +using Newtonsoft.Json; +using Service.Cloud.Client; +using Service.Cloud.Common; +using Service.Cloud.Msg.Cloud.Req; +using Service.Cloud.Msg.Host.Resp; +using Service.Init; + +namespace Service.Cloud.Handler; + +[Scope("InstancePerDependency")] +public class BusinessHourHandler : IBaseHandler +{ + public bool CanHandle(string cmd) + { + return CloudConst.setOpTime == cmd; + } + + public void Handle(string t) + { + BusinessHour? req = JsonConvert.DeserializeObject(t); + if (req != null) + { + List reqSeg = req.seg; + if (reqSeg is { Count: > 0 }) + { + StaticStationInfo.OperationStartTime = reqSeg.Select(i => i.st).Join(); + StaticStationInfo.OperationEndTime = reqSeg.Select(i => i.et).Join(); + } + + BusinessHourResp resp = new BusinessHourResp(); + CloudClientMgr.CloudClient?.Publish(resp); + } + } +} \ No newline at end of file diff --git a/Service/Cloud/Handler/DeliverBasicInformationHandler.cs b/Service/Cloud/Handler/DeliverBasicInformationHandler.cs new file mode 100644 index 0000000..51bd7f0 --- /dev/null +++ b/Service/Cloud/Handler/DeliverBasicInformationHandler.cs @@ -0,0 +1,33 @@ +using HybirdFrameworkCore.Autofac.Attribute; +using Newtonsoft.Json; +using Service.Cloud.Client; +using Service.Cloud.Common; +using Service.Cloud.Msg.Cloud.Req; +using Service.Cloud.Msg.Host.Resp; +using Service.Init; + +namespace Service.Cloud.Handler; + +[Scope("InstancePerDependency")] +public class DeliverBasicInformationHandler : IBaseHandler +{ + public bool CanHandle(string cmd) + { + return CloudConst.setStBaseInfo == cmd; + } + + public void Handle(string t) + { + DeliverBasicInformation? deliverBasicInformation = JsonConvert.DeserializeObject(t); + if (deliverBasicInformation != null) + { + StaticStationInfo.StationNo = deliverBasicInformation.sn; + StaticStationInfo.StationName = deliverBasicInformation.Sm; + StaticStationInfo.StationSn = deliverBasicInformation.SS; + //TODO 补全StaticStationInfo后赋值 + + DeliverBasicInformationResp resp = new DeliverBasicInformationResp(); + CloudClientMgr.CloudClient?.Publish(resp); + } + } +} \ No newline at end of file diff --git a/Service/Cloud/Handler/ParameterAcquisitionHandler.cs b/Service/Cloud/Handler/ParameterAcquisitionHandler.cs new file mode 100644 index 0000000..262013f --- /dev/null +++ b/Service/Cloud/Handler/ParameterAcquisitionHandler.cs @@ -0,0 +1,32 @@ +using HybirdFrameworkCore.Autofac.Attribute; +using Newtonsoft.Json; +using Service.Cloud.Client; +using Service.Cloud.Common; +using Service.Cloud.Msg.Cloud.Req; +using Service.Cloud.Msg.Host.Resp; +using Service.Init; + +namespace Service.Cloud.Handler; + +[Scope("InstancePerDependency")] +public class ParameterAcquisitionHandler : IBaseHandler +{ + public bool CanHandle(string cmd) + { + return CloudConst.getConfig == cmd; + } + + public void Handle(string t) + { + ParameterAcquisition? req = JsonConvert.DeserializeObject(t); + if (req != null) + { + ParameterAcquisitionResp resp = new ParameterAcquisitionResp(); + resp.chsoc = Char.Parse(StaticStationInfo.SwapSoc); + resp.eid = StaticStationInfo.Eid; + resp.oid = StaticStationInfo.Oid; + resp.ceid = StaticStationInfo.Ceid; + CloudClientMgr.CloudClient?.Publish(resp); + } + } +} \ No newline at end of file diff --git a/Service/Cloud/Handler/ServiceableStateHandler.cs b/Service/Cloud/Handler/ServiceableStateHandler.cs new file mode 100644 index 0000000..af25d46 --- /dev/null +++ b/Service/Cloud/Handler/ServiceableStateHandler.cs @@ -0,0 +1,30 @@ +using HybirdFrameworkCore.Autofac.Attribute; +using Newtonsoft.Json; +using Service.Cloud.Client; +using Service.Cloud.Common; +using Service.Cloud.Msg.Cloud.Req; +using Service.Cloud.Msg.Host.Resp; +using Service.Init; + +namespace Service.Cloud.Handler; + + +[Scope("InstancePerDependency")] +public class ServiceableStateHandler:IBaseHandler +{ + public bool CanHandle(string cmd) + { + return CloudConst.setServiceRes == cmd; + } + + public void Handle(string t) + { + ServiceableState? req = JsonConvert.DeserializeObject(t); + if (req != null) + { + StaticStationInfo.StationStatus = req.st; + ServiceableStateResp resp = new ServiceableStateResp(); + CloudClientMgr.CloudClient?.Publish(resp); + } + } +} \ No newline at end of file diff --git a/Service/Cloud/Handler/SetConfigurationParametersHandler.cs b/Service/Cloud/Handler/SetConfigurationParametersHandler.cs new file mode 100644 index 0000000..d9bb61d --- /dev/null +++ b/Service/Cloud/Handler/SetConfigurationParametersHandler.cs @@ -0,0 +1,34 @@ +using HybirdFrameworkCore.Autofac.Attribute; +using Newtonsoft.Json; +using Service.Cloud.Client; +using Service.Cloud.Common; +using Service.Cloud.Msg.Cloud.Req; +using Service.Cloud.Msg.Host.Resp; +using Service.Init; + +namespace Service.Cloud.Handler; + +[Scope("InstancePerDependency")] +public class SetConfigurationParametersHandler : IBaseHandler +{ + public bool CanHandle(string cmd) + { + return CloudConst.setStBaseInfo == cmd; + } + + public void Handle(string t) + { + SetConfigurationParameters? setConfigurationParameters = JsonConvert.DeserializeObject(t); + if (setConfigurationParameters != null) + { + char chsoc = setConfigurationParameters.chsoc; + StaticStationInfo.SwapSoc = chsoc.ToString(); + StaticStationInfo.Eid = setConfigurationParameters.eid; + StaticStationInfo.Oid = setConfigurationParameters.oid; + StaticStationInfo.Ceid = setConfigurationParameters.ceid; + + SetConfigurationParametersResp resp = new SetConfigurationParametersResp(); + CloudClientMgr.CloudClient?.Publish(resp); + } + } +} \ No newline at end of file diff --git a/Service/Cloud/Msg/Cloud/Req/BatteryOperatingModel.cs b/Service/Cloud/Msg/Cloud/Req/BatteryOperatingModel.cs index 6798e1a..24110c3 100644 --- a/Service/Cloud/Msg/Cloud/Req/BatteryOperatingModel.cs +++ b/Service/Cloud/Msg/Cloud/Req/BatteryOperatingModel.cs @@ -1,9 +1,4 @@ using Service.Cloud.Common; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Service.Cloud.Msg.Cloud.Req { @@ -16,29 +11,40 @@ namespace Service.Cloud.Msg.Cloud.Req /// 运营模型ID /// public int oid { get; set; } + /// /// 更新时间 /// - public string ut { get; set; } + public DateTime ut { get; set; } + + public List? seg { get; set; } + + public string GetCmd() + { + return CloudConst.setOpModel; + } + } + + public class Detail + { /// /// 开始时段 /// public string st { get; set; } + /// /// 结束时段 /// public string et { get; set; } + /// /// 该时段需要的电池类型编 号 /// public string btc { get; set; } + /// /// 该时段需要的电池数量 /// public int bc { get; set; } - public string GetCmd() - { - return CloudConst.setOpModel; - } } -} +} \ No newline at end of file diff --git a/Service/Cloud/Msg/Cloud/Req/ParameterAcquisition.cs b/Service/Cloud/Msg/Cloud/Req/ParameterAcquisition.cs index 470cd99..d2f5b46 100644 --- a/Service/Cloud/Msg/Cloud/Req/ParameterAcquisition.cs +++ b/Service/Cloud/Msg/Cloud/Req/ParameterAcquisition.cs @@ -1,9 +1,4 @@ using Service.Cloud.Common; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Service.Cloud.Msg.Cloud.Req { @@ -15,10 +10,16 @@ namespace Service.Cloud.Msg.Cloud.Req /// /// 自定义 /// - public string param { get; set; } + public List? Data { get; set; } + public string GetCmd() { return CloudConst.getConfig; } } -} + + public class Parameter + { + public string param { get; set; } + } +} \ No newline at end of file diff --git a/Service/Cloud/Msg/Cloud/Req/SetStBaseInfo.cs b/Service/Cloud/Msg/Cloud/Req/SetStBaseInfo.cs index 5142007..75e7102 100644 --- a/Service/Cloud/Msg/Cloud/Req/SetStBaseInfo.cs +++ b/Service/Cloud/Msg/Cloud/Req/SetStBaseInfo.cs @@ -1,9 +1,4 @@ using Service.Cloud.Common; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Service.Cloud.Msg.Cloud.Req { @@ -16,79 +11,98 @@ namespace Service.Cloud.Msg.Cloud.Req /// 电站编码 /// public string sn { get; set; } + /// /// 换电站名称 /// public string Sm { get; set; } + /// /// 换电站识别号 /// public string SS { get; set; } + /// /// 地理位置 /// public string sl { get; set; } + /// /// 换电站类型 /// public string st { get; set; } + /// /// 经度 /// public string ld { get; set; } + /// /// 纬度 /// public string lt { get; set; } + /// /// 区域编号 /// public string ac { get; set; } + /// /// 区域名称 /// public string am { get; set; } + /// /// 营运时间 /// public DateTime ot { get; set; } + ///投放时间 public DateTime lm { get; set; } + /// /// 联系方式 /// public string cw { get; set; } + /// /// 负责人 /// public string pp { get; set; } + /// /// 所属运营企业 /// public string sc { get; set; } + /// /// 所属运营企业统一社 会信用代码 /// public string cc { get; set; } + /// /// 站控主机软件版本号 /// public string sv { get; set; } + /// /// 供应商代码 /// public string sp { get; set; } + /// /// 封面图片文件id /// public long cb { get; set; } + /// /// 换电站基础信息版本号 /// public string bs { get; set; } + public string GetCmd() { return CloudConst.setStBaseInfo; } } -} +} \ No newline at end of file diff --git a/Service/Cloud/Msg/Host/Resp/SetStBaseInfoRes.cs b/Service/Cloud/Msg/Host/Resp/SetStBaseInfoRes.cs index 384c6ba..074bd1d 100644 --- a/Service/Cloud/Msg/Host/Resp/SetStBaseInfoRes.cs +++ b/Service/Cloud/Msg/Host/Resp/SetStBaseInfoRes.cs @@ -1,9 +1,4 @@ using Service.Cloud.Common; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Service.Cloud.Msg.Host.Resp { @@ -15,11 +10,11 @@ namespace Service.Cloud.Msg.Host.Resp /// /// 应答结果 /// - public int re { get; set; } + public int re { get; set; } = 0; public string GetCmd() { return CloudConst.setStBaseInfoRes; } } -} +} \ No newline at end of file diff --git a/Service/Execute/Step/StationReadyState.cs b/Service/Execute/Step/StationReadyState.cs index 8b080c3..ca8e08e 100644 --- a/Service/Execute/Step/StationReadyState.cs +++ b/Service/Execute/Step/StationReadyState.cs @@ -5,8 +5,6 @@ using Entity.Constant; using Entity.DbModel.Station; using HybirdFrameworkCore.Autofac; using log4net; -using Microsoft.OpenApi.Extensions; -using Microsoft.VisualBasic; using Newtonsoft.Json; using Repository.Station; using Service.Execute.Api; @@ -156,7 +154,7 @@ public class StationReadyState : IState { var statusDes = BaseEnumExtensions.GetEnumDescriptionByCode( - int.Parse(StaticStationInfo.StationStatus)); + StaticStationInfo.StationStatus); _log.Info($"换电站处于{statusDes}状态"); var wayDes = BaseEnumExtensions.GetEnumDescriptionByCode( @@ -164,7 +162,7 @@ public class StationReadyState : IState _log.Info($"换电站处于{wayDes}模式"); if (StationConstant.StationStatus.Run == - BaseEnumExtensions.GetEnumByCode(int.Parse(StaticStationInfo.StationStatus)) + BaseEnumExtensions.GetEnumByCode(StaticStationInfo.StationStatus) && StationConstant.StationWay.Auto == BaseEnumExtensions.GetEnumByCode(int.Parse(StaticStationInfo.StationWay))) { diff --git a/Service/Init/StaticStationInfo.cs b/Service/Init/StaticStationInfo.cs index 51a89ca..6c138e0 100644 --- a/Service/Init/StaticStationInfo.cs +++ b/Service/Init/StaticStationInfo.cs @@ -12,11 +12,21 @@ public class StaticStationInfo { - public static string StationStatus + public static int StationStatus { - get => Resolve(StationParamConst.StationStatus); + get => int.Parse(Resolve(StationParamConst.StationStatus)); set => Set(StationParamConst.StationStatus, value); } + public static string OperationStartTime + { + get => Resolve(StationParamConst.OperationStartTime); + set => Set(StationParamConst.OperationStartTime, value); + } + public static string OperationEndTime + { + get => Resolve(StationParamConst.OperationEndTime); + set => Set(StationParamConst.OperationEndTime, value); + } public static string StationWay { get => Resolve(StationParamConst.StationWay); @@ -41,6 +51,11 @@ public class StaticStationInfo get => Resolve(StationParamConst.StationNo); set => Set(StationParamConst.StationNo, value); } + public static string StationSn + { + get => Resolve(StationParamConst.StationSn); + set => Set(StationParamConst.StationSn, value); + } public static string SwapFinishChargeTime { @@ -53,6 +68,25 @@ public class StaticStationInfo get => Resolve(StationParamConst.SwapSoc); set => Set(StationParamConst.SwapSoc, value); } + + public static int Eid + { + get => int.Parse(Resolve(StationParamConst.Eid)); + set => Set(StationParamConst.Eid, value); + } + + public static string Oid + { + get => Resolve(StationParamConst.Oid); + set => Set(StationParamConst.Oid, value); + } + + public static int Ceid + { + get => int.Parse(Resolve(StationParamConst.Ceid)); + set => Set(StationParamConst.Ceid, value); + } + #region cloud diff --git a/Service/Station/StationParamConst.cs b/Service/Station/StationParamConst.cs index 45df184..ae1604d 100644 --- a/Service/Station/StationParamConst.cs +++ b/Service/Station/StationParamConst.cs @@ -42,11 +42,11 @@ public class StationParamConst /// /// 营运开始时间 /// - public static readonly string OperatetionStartTime = "Station.OperatetionStartTime"; + public static readonly string OperationStartTime = "Station.OperationStartTime"; /// /// 营运结束时间 /// - public static readonly string OperatetionEndtime = "Station.OperatetionEndtime"; + public static readonly string OperationEndTime = "Station.OperationEndTime"; /// /// 服务状态 /// @@ -153,7 +153,11 @@ public class StationParamConst public static readonly string SwapFinishChargeTime = "Station.SwapFinishChargeTime"; //选包策略换电Soc public static readonly string SwapSoc = "Station.SwapSoc"; - + + + public static readonly string Eid = "Station.Eid"; + public static readonly string Oid = "Station.Oid"; + public static readonly string Ceid = "Station.Ceid"; public static readonly string StationStatus = "Station.StationStatus"; public static readonly string StationWay = "Station.StationWay"; diff --git a/Service/System/SysConfigService.cs b/Service/System/SysConfigService.cs index 21efcbe..534a0b9 100644 --- a/Service/System/SysConfigService.cs +++ b/Service/System/SysConfigService.cs @@ -217,7 +217,7 @@ namespace Service.System SysFlag = YesNoEnum.N, Name = key }); - setResult = insertResult > 0 ? true : false; + setResult = insertResult > 0; } else {