PC端 实时订单/异常订单优化
This commit is contained in:
parent
2dfb722430
commit
35b1aad4e4
@ -27,7 +27,7 @@ public class HxpcChargeOrderController extends BaseController {
|
||||
private IHxpcChargeOrderService iHxpcChargeOrderService;
|
||||
|
||||
/**
|
||||
* 实时订单
|
||||
* 实时订单(微信)
|
||||
*/
|
||||
@GetMapping("/getHistotyChargeOrderMessage")
|
||||
public AjaxResult getHistotyChargeOrderMessage(@RequestParam Long userId)
|
||||
@ -36,7 +36,7 @@ public class HxpcChargeOrderController extends BaseController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 异常订单
|
||||
* 异常订单(微信)
|
||||
*/
|
||||
@GetMapping("/getHistotyChargeOrderStatusList")
|
||||
public TableDataInfo getHistotyChargeOrderStatusList(@RequestParam Long userId)
|
||||
|
||||
@ -27,7 +27,7 @@ public class XhpcRealTimeOrderController extends BaseController {
|
||||
|
||||
|
||||
/**
|
||||
* 实时订单接口
|
||||
* 实时/异常订单接口(PC)
|
||||
* @param phone 用户账号
|
||||
* @param transactionNumber 订单编号
|
||||
* @param source 用户类型 0C端用户 1流量用户
|
||||
@ -36,18 +36,19 @@ public class XhpcRealTimeOrderController extends BaseController {
|
||||
* @param operatorId 运营商
|
||||
* @param startTime 订单开始时间
|
||||
* @param endTime 订单结束时间
|
||||
* @param status 状态(-1准备充电 0开始充电 1自动结算,2异常,3平台结算)
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(String phone,String transactionNumber,Integer source,String chargingStationName,String terminalName,Long operatorId,String startTime,String endTime)
|
||||
public TableDataInfo list(String phone,String transactionNumber,Integer source,String chargingStationName,String terminalName,Long operatorId,String startTime,String endTime,@RequestParam("status") Integer status)
|
||||
{
|
||||
startPage();
|
||||
List<Map<String,Object>> list = xhpcRealTimeOrderService.list(phone, transactionNumber, source, chargingStationName,terminalName, operatorId, startTime, endTime);
|
||||
List<Map<String,Object>> list = xhpcRealTimeOrderService.list(phone, transactionNumber, source, chargingStationName,terminalName, operatorId, startTime, endTime,status);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 实时订单详情
|
||||
* 实时/异常订单详情(PC)
|
||||
*/
|
||||
@GetMapping("/getMessage")
|
||||
public AjaxResult getMessage(@RequestParam Long realTimeOrderId)
|
||||
@ -57,7 +58,7 @@ public class XhpcRealTimeOrderController extends BaseController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 实时订单详情数据列表(PC)
|
||||
* 实时/异常订单详情数据列表(PC)
|
||||
* @param chargingOrderId
|
||||
* @return
|
||||
*/
|
||||
@ -70,7 +71,7 @@ public class XhpcRealTimeOrderController extends BaseController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 实时订单详情数据图表(PC)
|
||||
* 实时/异常订单详情数据图表(PC)
|
||||
* @param chargingOrderId
|
||||
* @return
|
||||
*/
|
||||
|
||||
@ -59,7 +59,7 @@ public interface XhpcRealTimeOrderMapper {
|
||||
* @param type 0 都没有 1 phone 有 2 用户类型有 3 都有
|
||||
* @return
|
||||
*/
|
||||
List<Map<String,Object>> list(@Param("phone") String phone,@Param("transactionNumber") String transactionNumber,@Param("source") Integer source,@Param("chargingStationName") String chargingStationName,@Param("terminalName")String terminalName,@Param("operatorId") Long operatorId,@Param("startTime") String startTime,@Param("endTime") String endTime,@Param("type") Integer type);
|
||||
List<Map<String,Object>> list(@Param("phone") String phone,@Param("transactionNumber") String transactionNumber,@Param("source") Integer source,@Param("chargingStationName") String chargingStationName,@Param("terminalName")String terminalName,@Param("operatorId") Long operatorId,@Param("startTime") String startTime,@Param("endTime") String endTime,@Param("type") Integer type,@Param("status")Integer status);
|
||||
|
||||
/**
|
||||
* 实时订单详情接口(PC端)
|
||||
|
||||
@ -30,9 +30,10 @@ public interface IXhpcRealTimeOrderService {
|
||||
* @param operatorId 运营商
|
||||
* @param startTime 订单开始时间
|
||||
* @param endTime 订单结束时间
|
||||
* @param status 状态(-1准备充电 0开始充电 1自动结算,2异常,3平台结算)
|
||||
* @return
|
||||
*/
|
||||
List<Map<String,Object>> list(String phone,String transactionNumber,Integer source,String chargingStationName,String terminalName,Long operatorId,String startTime,String endTime);
|
||||
List<Map<String,Object>> list(String phone,String transactionNumber,Integer source,String chargingStationName,String terminalName,Long operatorId,String startTime,String endTime,Integer status);
|
||||
|
||||
/**
|
||||
* 实时订单详情接口(PC端)
|
||||
|
||||
@ -49,7 +49,7 @@ public class XhpcRealTimeOrderServiceImpl implements IXhpcRealTimeOrderService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Map<String, Object>> list(String phone, String transactionNumber, Integer source, String chargingStationName, String terminalName, Long operatorId, String startTime, String endTime) {
|
||||
public List<Map<String, Object>> list(String phone, String transactionNumber, Integer source, String chargingStationName, String terminalName, Long operatorId, String startTime, String endTime,Integer status) {
|
||||
|
||||
Integer type =0;
|
||||
if(!"".equals(phone) && phone!=null && !"".equals(source) && source !=null){
|
||||
@ -59,7 +59,7 @@ public class XhpcRealTimeOrderServiceImpl implements IXhpcRealTimeOrderService {
|
||||
}else{
|
||||
type =2;
|
||||
}
|
||||
return xhpcRealTimeOrderMapper.list(phone,transactionNumber,source,chargingStationName,terminalName,operatorId,startTime,endTime,type);
|
||||
return xhpcRealTimeOrderMapper.list(phone,transactionNumber,source,chargingStationName,terminalName,operatorId,startTime,endTime,type,status);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -77,7 +77,7 @@ public class XhpcRealTimeOrderServiceImpl implements IXhpcRealTimeOrderService {
|
||||
Map<String,Object> map =new HashMap();
|
||||
map.put("soc",xhpcRealTimeOrderMapper.timeChartSOCList(chargingOrderId));
|
||||
map.put("voltage",xhpcRealTimeOrderMapper.timeChartVoltageList(chargingOrderId));
|
||||
map.put("soc",xhpcRealTimeOrderMapper.timeChartCurrentList(chargingOrderId));
|
||||
map.put("current",xhpcRealTimeOrderMapper.timeChartCurrentList(chargingOrderId));
|
||||
return AjaxResult.success(map);
|
||||
}
|
||||
|
||||
|
||||
@ -372,7 +372,7 @@
|
||||
|
||||
<select id="list" resultType="map">
|
||||
select
|
||||
ro.real_time_order_id as realTimeOrderId,
|
||||
co.charge_order_id as chargeOrderId,
|
||||
co.serial_number as serialNumber,
|
||||
ct.name as chargingStationName,
|
||||
ter.pile_serial_number as pileSerialNumber,
|
||||
@ -381,21 +381,21 @@
|
||||
op.name as operatorName,
|
||||
cp.power as power,
|
||||
cp.type as type,
|
||||
ro.soc as soc,
|
||||
co.status as status,
|
||||
co.create_time as createTime,
|
||||
ro.charging_degree as chargingDegree,
|
||||
ro.charging_time as chargingTime,
|
||||
(select real_time_order_id from xhpc_real_time_order where transaction_number =co.serial_number order by create_time desc limit 1) realTimeOrderId,
|
||||
(select soc from xhpc_real_time_order where transaction_number =co.serial_number order by create_time desc limit 1) soc,
|
||||
(select charging_degree from xhpc_real_time_order where transaction_number =co.serial_number order by create_time desc limit 1) chargingDegree,
|
||||
(select charging_time from xhpc_real_time_order where transaction_number =co.serial_number order by create_time desc limit 1) chargingTime,
|
||||
co.source as source,
|
||||
(SELECT phone FROM xhpc_app_user where app_user_id = co.user_id) as appUserPhone,
|
||||
(SELECT phone from xhpc_internet_user where internet_user_id = co.user_id) as internetUserPhone
|
||||
from xhpc_charge_order co
|
||||
left join xhpc_real_time_order as ro on co.serial_number = ro.transaction_number
|
||||
left join xhpc_charging_station as ct on ct.charging_station_id = ro.charging_station_id
|
||||
left join xhpc_charging_station as ct on ct.charging_station_id = co.charging_station_id
|
||||
left join xhpc_operator as op on op.operator_id = ct.operator_id
|
||||
left join xhpc_terminal as ter on ter.serial_number = ro.gun_number
|
||||
left join xhpc_terminal as ter on ter.terminal_id = co.terminal_id
|
||||
left join xhpc_charging_pile as cp on cp.charging_pile_id = ter.charging_pile_id
|
||||
where co.status=0 and co.del_flag=0
|
||||
where co.status=#{status} and co.del_flag=0
|
||||
<if test="startTime !=null and startTime !=''">
|
||||
and co.start_time >= #{startTime}
|
||||
</if>
|
||||
@ -479,7 +479,8 @@
|
||||
gun_line_temperature as gunLineTemperature,
|
||||
charging_time as chargingTime,
|
||||
remaining_time as remainingTime,
|
||||
vehicle_gun_status as vehicleGunStatus
|
||||
vehicle_gun_status as vehicleGunStatus,
|
||||
status
|
||||
from xhpc_real_time_order
|
||||
where charging_order_id=#{chargingOrderId}
|
||||
order by create_time desc
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user