| | |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.core.base.tips.SuccessTip; |
| | | import com.stylefeng.guns.core.log.LogObjectHolder; |
| | | import com.stylefeng.guns.core.shiro.ShiroKit; |
| | | import com.stylefeng.guns.core.util.ToolUtil; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TAppUserDetailOrderResp; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TDriverCommissionResp; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TOrderResp; |
| | | import com.stylefeng.guns.modular.system.controller.util.ExcelUtil; |
| | | import com.stylefeng.guns.modular.system.dao.TCancelOrderMapper; |
| | | import com.stylefeng.guns.modular.system.enums.OrderStateEnum; |
| | | import com.stylefeng.guns.modular.system.model.TAppUser; |
| | | import com.stylefeng.guns.modular.system.model.TDriver; |
| | | import com.stylefeng.guns.modular.system.model.TOrder; |
| | |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.*; |
| | | import java.math.BigDecimal; |
| | |
| | | private ITAppUserService tAppUserService; |
| | | @Autowired |
| | | private ITCancelOrderService tCancelOrderService; |
| | | @Resource |
| | | private TCancelOrderMapper tCancelOrderMapper; |
| | | |
| | | @Value("${filePath}") |
| | | private String filePath; |
| | |
| | | * 跳转到首页 |
| | | */ |
| | | @RequestMapping("") |
| | | public String index() { |
| | | public String index(Model model) { |
| | | Integer roleType = Objects.requireNonNull(ShiroKit.getUser()).getRoleType(); |
| | | Integer objectId = Objects.requireNonNull(ShiroKit.getUser()).getObjectId(); |
| | | List<TOrderResp> tOrderResps = tCancelOrderMapper.orderExceptionList(null, null, null, null, null, null, null, null, roleType, objectId); |
| | | model.addAttribute("error", tOrderResps.size()); |
| | | return PREFIX + "tOrder.html"; |
| | | } |
| | | |
| | |
| | | Integer state, |
| | | String driverName) { |
| | | // return tOrderService.getOrderList(createTime, code, source, userName, userPhone, state, driverName,2); |
| | | return tCancelOrderService.getCancelOrderList(createTime, code, source, userName, userPhone, state, driverName); |
| | | return tCancelOrderService.orderExceptionList(createTime, code, source, userName, userPhone, state, driverName); |
| | | } |
| | | |
| | | /** |
| | |
| | | return ResultUtil.paranErr(); |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 关闭订单 |
| | | */ |
| | | @RequestMapping(value = "/cancelOrderUpdate") |
| | | @ResponseBody |
| | | public Object cancelOrderUpdate(@RequestParam Integer tOrderId) { |
| | | TOrder tOrder = tOrderService.selectById(tOrderId); |
| | | tOrder.setState(OrderStateEnum.CANCELED.getCode()); |
| | | tOrderService.updateById(tOrder); |
| | | return SUCCESS_TIP; |
| | | } |
| | | } |