From 4b55eb4a50938ace45b2b2266caa0ce2aadfcd40 Mon Sep 17 00:00:00 2001
From: liujie <1793218484@qq.com>
Date: 星期一, 02 六月 2025 16:39:18 +0800
Subject: [PATCH] 小程序接口 详情

---
 ruoyi-applet/src/main/java/com/ruoyi/web/controller/system/CompanyController.java |   28 ++++++++++++++++++++++++++++
 1 files changed, 28 insertions(+), 0 deletions(-)

diff --git a/ruoyi-applet/src/main/java/com/ruoyi/web/controller/system/CompanyController.java b/ruoyi-applet/src/main/java/com/ruoyi/web/controller/system/CompanyController.java
index 6b9d862..1aa539d 100644
--- a/ruoyi-applet/src/main/java/com/ruoyi/web/controller/system/CompanyController.java
+++ b/ruoyi-applet/src/main/java/com/ruoyi/web/controller/system/CompanyController.java
@@ -13,6 +13,7 @@
 import com.ruoyi.system.query.CompanyListQuery;
 import com.ruoyi.system.query.MyPushCompanyListQuery;
 import com.ruoyi.system.service.*;
+import com.ruoyi.system.vo.CompanyDetailVo;
 import com.ruoyi.system.vo.IndexCompanyListVo;
 import com.ruoyi.system.vo.MyPushCompanyListVo;
 import io.swagger.annotations.Api;
@@ -24,6 +25,7 @@
 import org.springframework.web.bind.annotation.*;
 
 import javax.validation.Valid;
+import java.util.Date;
 import java.util.List;
 
 @Slf4j
@@ -46,6 +48,9 @@
 
     @Autowired
     private TbScheduleService scheduleService;
+
+    @Autowired
+    private TbMessageService messageService;
 
 
 
@@ -133,7 +138,9 @@
             return R.fail("该订单状态不需要确认");
         }
         order.setStatus(3);
+        order.setConfirmTime(new Date());
         order.updateById();
+
         return R.ok();
     }
 
@@ -160,6 +167,12 @@
         }
         order.setStatus(3);
         order.updateById();
+
+        company.setStatus(1);
+        company.updateById();
+
+
+        messageService.addMessage("您有订单被取消", order.getUserId(),order.getId());
         return R.ok();
     }
 
@@ -177,6 +190,8 @@
             return R.fail("非法操作");
         }
         scheduleService.addSchedule(dto,userId);
+
+        messageService.addMessage("您有订单卖家已完成,等待确认", order.getUserId(),order.getId());
         return R.ok();
     }
 
@@ -205,10 +220,23 @@
         }
         order.setStatus(5);
         order.updateById();
+
+        messageService.addMessage("您有订单卖家已完成,等待确认", order.getUserId(),orderId);
         return R.ok();
     }
 
 
+    @ApiOperation(value = "公司详情",tags = {"发布模块"})
+    @GetMapping("/companyDetail")
+    public R<CompanyDetailVo> companyDetail(@RequestParam String companyId) {
+        if(StringUtils.isEmpty(companyId)){
+            return R.fail("参数错误");
+        }
+        LoginUser loginUser = tokenService.getLoginUser();
+        Long userId = loginUser.getUserId();
+        CompanyDetailVo companyDetailVo = tbCompanyService.companyDetail(companyId,userId);
+        return R.ok(companyDetailVo);
+    }
 
 
 }

--
Gitblit v1.7.1