From 2fdc4335daf9c2f9651de1d98f3a52331b1d96b5 Mon Sep 17 00:00:00 2001
From: mitao <2763622819@qq.com>
Date: 星期二, 21 五月 2024 11:33:42 +0800
Subject: [PATCH] 拍卖商品字段调整

---
 ruoyi-modules/ruoyi-auction/src/main/java/com/ruoyi/auction/controller/forepart/ForepartAuctionSalesroomController.java |   45 ++++++++++-----------------------------------
 1 files changed, 10 insertions(+), 35 deletions(-)

diff --git a/ruoyi-modules/ruoyi-auction/src/main/java/com/ruoyi/auction/controller/forepart/ForepartAuctionSalesroomController.java b/ruoyi-modules/ruoyi-auction/src/main/java/com/ruoyi/auction/controller/forepart/ForepartAuctionSalesroomController.java
index 1e84c3b..6b8d058 100644
--- a/ruoyi-modules/ruoyi-auction/src/main/java/com/ruoyi/auction/controller/forepart/ForepartAuctionSalesroomController.java
+++ b/ruoyi-modules/ruoyi-auction/src/main/java/com/ruoyi/auction/controller/forepart/ForepartAuctionSalesroomController.java
@@ -3,18 +3,17 @@
 
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
-import com.ruoyi.auction.controller.forepart.VO.AuctionSalesroomVO;
+import com.ruoyi.auction.controller.forepart.DTO.ForepartAuctionBidRecordDTO;
+import com.ruoyi.auction.controller.forepart.VO.ForepartAuctionSalesroomVO;
 import com.ruoyi.auction.domain.pojo.AuctionSalesroom;
 import com.ruoyi.auction.domain.pojo.AuctionVideo;
 import com.ruoyi.auction.service.IAuctionSalesroomService;
 import com.ruoyi.auction.service.IAuctionVideoService;
 import com.ruoyi.common.core.domain.R;
+import com.ruoyi.system.api.domain.SysUser;
+import com.ruoyi.system.api.feignClient.SysUserClient;
 import io.swagger.annotations.ApiOperation;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.RequestMapping;
-
-import org.springframework.web.bind.annotation.ResponseBody;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 import javax.annotation.Resource;
 import java.util.List;
@@ -35,9 +34,6 @@
     @Resource
     private IAuctionSalesroomService iAuctionSalesroomService;
 
-    @Resource
-    private IAuctionVideoService  iAuctionVideoService;
-
     /**
      * 拍卖大屏获取拍卖信息
      *
@@ -46,11 +42,7 @@
     @ResponseBody
     @ApiOperation(value = "拍卖大屏获取拍卖信息")
     public R<List<AuctionSalesroom>> getAuctionBidRecordList(@PathVariable("salesroomName") String salesroomName) {
-        LambdaQueryWrapper<AuctionSalesroom> wrapper=Wrappers.lambdaQuery();
-        wrapper.eq(AuctionSalesroom::getSalesroomName,salesroomName);
-        wrapper.eq(AuctionSalesroom::getDelFlag,0);
-        List<AuctionSalesroom> auctionBidRecordList=iAuctionSalesroomService.list(wrapper);
-        return R.ok(auctionBidRecordList);
+        return R.ok(iAuctionSalesroomService.getAuctionBidRecordList(salesroomName));
 
     }
 
@@ -61,35 +53,18 @@
     @RequestMapping("/getBaaner")
     @ResponseBody
     @ApiOperation(value = " 暖场视频or封面海报")
-    public R<AuctionSalesroomVO> getBaaner(@PathVariable("salesroomId") Integer SalesroomId) {
+    public R<ForepartAuctionSalesroomVO> getBaaner(@PathVariable("salesroomId") Integer SalesroomId) {
 
-        LambdaQueryWrapper<AuctionVideo> wrapper=Wrappers.lambdaQuery();
-        wrapper.eq(AuctionVideo::getAuctionSalesroomId,SalesroomId);
-        wrapper.eq(AuctionVideo::getDelFlag,0);
-        AuctionVideo auctionVideo=iAuctionVideoService.getOne(wrapper);
-        AuctionSalesroomVO auctionSalesroomVO=new AuctionSalesroomVO();
-        AuctionSalesroom auctionSalesroom=iAuctionSalesroomService.getById(SalesroomId);
-        auctionSalesroomVO.setAuctionSalesroomStatus(auctionSalesroom.getStatus().getCode());
-        if (auctionVideo!=null){
-            auctionSalesroomVO.setUrl(auctionVideo.getPromotionVideoUrl());
-        }else{
-            auctionSalesroomVO.setUrl(auctionSalesroom.getCoverPic());
-        }
-
-        return R.ok(auctionSalesroomVO);
+        return R.ok(iAuctionSalesroomService.getBaaner(SalesroomId));
     }
 
 
     @RequestMapping("/getAuctionBidRecordOne")
     @ResponseBody
     @ApiOperation(value = "扫码二维码获取拍卖场信息")
-    public R<AuctionSalesroom> getAuctionBidRecordOne(@PathVariable("auctionSalesroomQrcode") String auctionSalesroomQrcode) {
-        LambdaQueryWrapper<AuctionSalesroom> wrapper=Wrappers.lambdaQuery();
-        wrapper.eq(AuctionSalesroom::getAuctionSalesroomQrcode,auctionSalesroomQrcode);
-        wrapper.eq(AuctionSalesroom::getDelFlag,0);
-        AuctionSalesroom auctionBidRecord=iAuctionSalesroomService.getOne(wrapper);
-        return R.ok(auctionBidRecord);
+    public R<AuctionSalesroom> getAuctionBidRecordOne(@RequestBody ForepartAuctionBidRecordDTO arepartAuctionBidRecordDTO) {
 
+        return R.ok(iAuctionSalesroomService.getAuctionBidRecordOne(arepartAuctionBidRecordDTO));
     }
 
 

--
Gitblit v1.7.1