|
|
@@ -3,6 +3,7 @@ package com.cyksj.web.controller.user;
|
|
|
import cn.hutool.core.date.DateTime;
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
import com.cyksj.common.annotation.NoSubmit;
|
|
|
+import com.cyksj.common.exception.BusinessRuntimeException;
|
|
|
import com.cyksj.dto.Result;
|
|
|
import com.cyksj.enums.GatewayResponse;
|
|
|
import com.cyksj.mapper.OrderDonMapper;
|
|
|
@@ -187,6 +188,23 @@ public class UserController {
|
|
|
return GatewayResponse.SUCCESS.newBuilder().toResult(search);
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 工单状态查询
|
|
|
+ */
|
|
|
+ @GetMapping("/workOrder/get/status/{id}")
|
|
|
+ public Result<WorkOrder> getWorkOrderStatus(@PathVariable Long id) {
|
|
|
+ long userId = StpUserUtil.getLoginIdAsLong();
|
|
|
+ WorkOrder workOrder = beanSearcher.searchFirst(WorkOrder.class, MapUtils.builder()
|
|
|
+ .field(WorkOrder::getUserId, userId)
|
|
|
+ .field(WorkOrder::getId, id)
|
|
|
+ .onlySelect(WorkOrder::getId, WorkOrder::getUserId, WorkOrder::getStatus)
|
|
|
+ .build());
|
|
|
+ if (workOrder == null) {
|
|
|
+ throw BusinessRuntimeException.getInstance("该工单不存在");
|
|
|
+ }
|
|
|
+ return GatewayResponse.SUCCESS.newBuilder().toResult(workOrder);
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
/**
|
|
|
* 用户回复客服
|