From b1f2f102034b4433201225b67a9fc78c08e532f0 Mon Sep 17 00:00:00 2001 From: Pu Zhibing <393733352@qq.com> Date: 星期五, 06 六月 2025 18:35:03 +0800 Subject: [PATCH] 修改bug和管理后台报表 --- ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/specialTrain/TOrderPrivateCarController.java | 59 ++++++++++++++++++++++++++++------------------------------- 1 files changed, 28 insertions(+), 31 deletions(-) diff --git a/ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/specialTrain/TOrderPrivateCarController.java b/ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/specialTrain/TOrderPrivateCarController.java index c4c7bb9..1703058 100644 --- a/ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/specialTrain/TOrderPrivateCarController.java +++ b/ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/specialTrain/TOrderPrivateCarController.java @@ -1,12 +1,10 @@ package com.stylefeng.guns.modular.system.controller.specialTrain; -import cn.hutool.system.UserInfo; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONObject; import com.baomidou.mybatisplus.mapper.EntityWrapper; import com.baomidou.mybatisplus.plugins.Page; -import com.google.gson.Gson; import com.stylefeng.guns.core.base.controller.BaseController; import com.stylefeng.guns.core.common.constant.factory.PageFactory; import com.stylefeng.guns.core.shiro.ShiroKit; @@ -34,7 +32,10 @@ import javax.annotation.Resource; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; -import java.io.*; +import java.io.BufferedReader; +import java.io.File; +import java.io.FileInputStream; +import java.io.InputStreamReader; import java.math.BigDecimal; import java.math.MathContext; import java.math.RoundingMode; @@ -80,9 +81,19 @@ @Resource private ITCarService carService; - - - + private ResultUtil resultUtil; + @Autowired + private ITCompanyService companyService; + @Autowired + private ITDriverService driverService; + @Autowired + private IIncomeService incomeService; + @Autowired + private PushUtil pushUtil; + @Autowired + private ITSystemNoticeService systemNoticeService; + @Resource + private TSystemPriceMapper systemPriceMapper; /** * 跳转到专车订单首页 @@ -104,6 +115,7 @@ model.addAttribute("item",item); return PREFIX + "tOrderPrivateCar_orderDetail.html"; } + /** * 跳转到修改专车订单 */ @@ -113,6 +125,7 @@ model.addAttribute("item",item); return PREFIX + "toChangeMoney.html"; } + /** * 跳转到出租车订单轨迹页面 */ @@ -149,8 +162,6 @@ page.setRecords(tOrderPrivateCarService.getPrivateCarOrderList(page,beginTime,endTime,ShiroKit.getUser().getRoleType(),ShiroKit.getUser().getObjectId(),orderNum,orderSource,userName,userPhone,passengers,passengersPhone,serverCarModelId,driver,state,smsNumber)); return super.packForBT(page); } - - private ResultUtil resultUtil; /** * 获取订单轨迹 @@ -191,17 +202,6 @@ return resultUtil; } - @Autowired - private ITCompanyService companyService; - - @Autowired - private ITDriverService driverService; - - @Autowired - private IIncomeService incomeService; - - - /** * 支付专车订单 */ @@ -212,12 +212,12 @@ orderPrivateCar.setAbnormalMoney(orderPrivateCar.getOrderMoney()); orderPrivateCar.setOrderMoney(money); orderPrivateCar.setPayMoney(money); + orderPrivateCar.setPayType(5); orderPrivateCar.setState(7); orderPrivateCar.setIsDispute(1); orderPrivateCar.updateById(); return SUCCESS_TIP; } - @RequestMapping(value = "/frozenOrder") @ResponseBody @@ -281,10 +281,10 @@ tOrderPrivateCarService.updateById(orderPrivateCar); //修改行程数据 - boolean updateTrip = fleetEngineUtil.updateTrip("COMPLETE", null, null, orderPrivateCar.getTripId(), null, null, null, null); + boolean updateTrip = fleetEngineUtil.updateTrip("COMPLETE", null, null, orderPrivateCar.getTripId(), null, null, null, null, orderPrivateCar.getId(), 1); if(!updateTrip){ for (int i = 0; i < 5; i++) { - updateTrip = fleetEngineUtil.updateTrip("COMPLETE", null, null, orderPrivateCar.getTripId(), null, null, null, null); + updateTrip = fleetEngineUtil.updateTrip("COMPLETE", null, null, orderPrivateCar.getTripId(), null, null, null, null, orderPrivateCar.getId(), 1); if(updateTrip){ orderPrivateCar.setIsover(1); tOrderPrivateCarService.updateById(orderPrivateCar); @@ -345,12 +345,7 @@ tOrderPrivateCarService.updateById(orderPrivateCar); return SUCCESS_TIP; } - @Autowired - private PushUtil pushUtil; - @Autowired - private ITSystemNoticeService systemNoticeService; - @Resource - private TSystemPriceMapper systemPriceMapper; + public TOrderPrivateCar setMoney(TOrderPrivateCar orderPrivateCar, Double parkingFee, Double crossingFee) throws Exception { System.err.println("计算金额:"+orderPrivateCar); Map<String, Object> query1 = systemPriceMapper.query(orderPrivateCar.getCompanyId(), 1, orderPrivateCar.getServerCarModelId()); @@ -603,6 +598,7 @@ orderPrivateCar.setIsplatPay(2); orderPrivateCar.setPayManner(1); orderPrivateCar.setState(8); + orderPrivateCar.setPayType(5); orderPrivateCar.setPayMoney(orderPrivateCar.getOrderMoney()); tOrderPrivateCarService.updateAllColumnById(orderPrivateCar); return SUCCESS_TIP; @@ -643,10 +639,10 @@ //修改行程信息 TCar car = carService.selectById(tOrderPrivateCar.getCarId()); //修改行程信息 - boolean updateTrip = fleetEngineUtil.updateTrip("CANCELED", (null != car ? car.getVehicleId() : null), null, tOrderPrivateCar.getTripId(), null, null, null, null); + boolean updateTrip = fleetEngineUtil.updateTrip("CANCELED", (null != car ? car.getVehicleId() : null), null, tOrderPrivateCar.getTripId(), null, null, null, null, tOrderPrivateCar.getId(), 1); if(!updateTrip){ for (int i = 0; i < 5; i++) { - updateTrip = fleetEngineUtil.updateTrip("CANCELED", (null != car ? car.getVehicleId() : null), null, tOrderPrivateCar.getTripId(), null, null, null, null); + updateTrip = fleetEngineUtil.updateTrip("CANCELED", (null != car ? car.getVehicleId() : null), null, tOrderPrivateCar.getTripId(), null, null, null, null, tOrderPrivateCar.getId(), 1); if(updateTrip){ tOrderPrivateCar.setIsover(1); tOrderPrivateCarService.updateById(tOrderPrivateCar); @@ -668,6 +664,7 @@ Map<String,String> map = new HashMap<>(); map.put("id", tOrderPrivateCar.getId().toString()); map.put("orderType", "1"); + map.put("from", "admin"); String result = HttpRequestUtil.postRequest(PushURL.cancel_order_url, map); System.out.println("专车取消:【orderId="+tOrderPrivateCar.getId().toString()+"】,调用接口:"+result); return SUCCESS_TIP; @@ -710,7 +707,7 @@ shellList.add("订单编号"); shellList.add("订单来源"); shellList.add("乘车时间"); - shellList.add("下单用户昵称"); + shellList.add("下单用户姓名"); shellList.add("下单用户手机"); shellList.add("乘车用户姓名"); shellList.add("乘车用户手机"); -- Gitblit v1.7.1