diff --git a/Entity/DbModel/Station/ChargeOrder.cs b/Entity/DbModel/Station/ChargeOrder.cs index 60fff6c..bf3ae98 100644 --- a/Entity/DbModel/Station/ChargeOrder.cs +++ b/Entity/DbModel/Station/ChargeOrder.cs @@ -138,37 +138,37 @@ namespace Entity.DbModel.Station [SugarColumn(ColumnName = "ac_elec_count")] public decimal? AcElecCount { get; set; } - /// + /*/// /// Desc:充电开始交流表电量 /// Default: /// Nullable:True /// [SugarColumn(ColumnName = "start_ac_elec")] - public decimal? StartAcElec { get; set; } + public decimal? StartAcElec { get; set; }*/ - /// + /*/// /// Desc:充电结束交流表电量 /// Default: /// Nullable:True /// [SugarColumn(ColumnName = "stop_ac_elec")] - public decimal? StopAcElec { get; set; } + public decimal? StopAcElec { get; set; }*/ - /// + /*/// /// Desc:充电开始直流表电量 /// Default: /// Nullable:True /// [SugarColumn(ColumnName = "start_dc_elec")] - public decimal? StartDcElec { get; set; } + public decimal? StartDcElec { get; set; }*/ - /// + /*/// /// Desc:充电结束直流表电量 /// Default: /// Nullable:True /// [SugarColumn(ColumnName = "stop_dc_elec")] - public decimal? StopDcElec { get; set; } + public decimal? StopDcElec { get; set; }*/ /// /// Desc:停止原因;0:满电自动停止;1-人工停止 @@ -178,7 +178,7 @@ namespace Entity.DbModel.Station [SugarColumn(ColumnName = "stop_reason")] public int? StopReason { get; set; } - /// + /*/// /// Desc:尖时段电量 /// Default: /// Nullable:True @@ -240,15 +240,15 @@ namespace Entity.DbModel.Station /// Nullable:True /// [SugarColumn(ColumnName = "ac_valley_elec_count")] - public decimal? ACValleyElecCount { get; set; } + public decimal? ACValleyElecCount { get; set; }*/ - /// + /*/// /// Desc:电价版本号 /// Default: /// Nullable:True /// [SugarColumn(ColumnName = "elec_price_model_version")] - public string ElecPriceModelVersion { get; set; } + public string ElecPriceModelVersion { get; set; }*/ /// /// Desc:换电订单编号 @@ -289,10 +289,81 @@ namespace Entity.DbModel.Station [SugarColumn(ColumnName = "start_type")] public int StartType { get; set; } - /// + /*/// /// 上报次数 /// [SugarColumn(ColumnName = "reporting_times")] - public int ReportingTimes { get; set; } + public int ReportingTimes { get; set; }*/ + + /// + /// Desc:充电开始交流表电量 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName = "start_ac_elec1")] + public decimal? StartAcElec1 { get; set; } + + [SugarColumn(ColumnName = "start_ac_elec2")] + public decimal? StartAcElec2 { get; set; } + + /// + /// Desc:充电结束交流表电量 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName = "stop_ac_elec1")] + public decimal? StopAcElec1 { get; set; } + + [SugarColumn(ColumnName = "stop_ac_elec2")] + public decimal? StopAcElec2 { get; set; } + + /// + /// Desc:充电开始直流表电量 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName = "start_dc_elec1")] + public decimal? StartDcElec1 { get; set; } + + [SugarColumn(ColumnName = "start_dc_elec2")] + public decimal? StartDcElec2 { get; set; } + + /// + /// Desc:充电结束直流表电量 + /// Default: + /// Nullable:True + /// + [SugarColumn(ColumnName = "stop_dc_elec1")] + public decimal? StopDcElec1 { get; set; } + + [SugarColumn(ColumnName = "stop_dc_elec2")] + public decimal? StopDcElec2 { get; set; } + + /// + /// 充电金额 + /// + [SugarColumn(ColumnName = "charge_amount")] + public decimal? ChargeAmount { get; set; } + + /// + /// 充电前卡余额 + /// + [SugarColumn(ColumnName = "card_balance_before")] + public decimal? CardBalanceBefore { get; set; } + + /// + /// 充电后卡余额 + /// + [SugarColumn(ColumnName = "card_balance_behind")] + public decimal? CardBalanceBehind { get; set; } + + + /// + /// 交易流水号 + /// + [SugarColumn(ColumnName = "transaction_serial_num")] + public string TransactionSerialNum { get; set; } + + } } \ No newline at end of file diff --git a/Service/Station/ChargeOrderService.cs b/Service/Station/ChargeOrderService.cs index 175cad7..f12e39f 100644 --- a/Service/Station/ChargeOrderService.cs +++ b/Service/Station/ChargeOrderService.cs @@ -147,11 +147,11 @@ public class ChargeOrderService : BaseServices Expression> condition2Expr = u => u.StopReason == chargeOrder.StopReason; where = where == null ? condition2Expr : Expression.Lambda>(Expression.AndAlso(where.Body, condition2Expr.Body), parameter); } - if (!string.IsNullOrEmpty(chargeOrder.ElecPriceModelVersion)) + /*if (!string.IsNullOrEmpty(chargeOrder.ElecPriceModelVersion)) { Expression> condition2Expr = u => u.ElecPriceModelVersion == chargeOrder.ElecPriceModelVersion; where = where == null ? condition2Expr : Expression.Lambda>(Expression.AndAlso(where.Body, condition2Expr.Body), parameter); - } + }*/ if (!string.IsNullOrEmpty(chargeOrder.SwapOrderSn)) { Expression> condition2Expr = u => u.SwapOrderSn == chargeOrder.SwapOrderSn; diff --git a/Service/Station/MonitorService.cs b/Service/Station/MonitorService.cs index 4afa5a1..73461b9 100644 --- a/Service/Station/MonitorService.cs +++ b/Service/Station/MonitorService.cs @@ -98,14 +98,18 @@ public class MonitorService var tboxCarInfoModel = StationSoftMgr.SwappingStateMachine.BoxCarInfoModel; List binInfos = BinInfoRepository.QueryListByClause(i => i.Exists == 1 && i.Status == 1); + + var plcSwapModel = new PlcSwapModelResp(); + if(ClientMgr.PlcClient!=null) + { + plcSwapModel.ModelState = ClientMgr.PlcClient.Auto ? 1010 : 1000; + plcSwapModel.ControlModel = ClientMgr.PlcClient.Remote ? 1010 : 1000; + } + SwapMonitorScreenResp monitorScreenResp = new() { - PlcSwapModel = new PlcSwapModelResp() - { - ModelState = ClientMgr.PlcClient.Auto?1010:1000, - //StationInLampSts = ClientMgr.PlcClient. - ControlModel = ClientMgr.PlcClient.Remote?1010:1000, - }, + + PlcSwapModel = plcSwapModel, StateInfo = stateInfoList, VehicleInfo = new SwapVehicleResp() {