From e40c0643e26447d89f50c0118da13dba80684089 Mon Sep 17 00:00:00 2001
From: mitao <2763622819@qq.com>
Date: 星期四, 30 五月 2024 14:50:26 +0800
Subject: [PATCH] 1.清除所有冗余字段 2.提交【管理后台】-拍卖场管理 添加/编辑接口

---
 ruoyi-modules/ruoyi-auction/src/main/java/com/ruoyi/auction/controller/forepart/ForepartAuctionSalesroomController.java |  133 ++++++++++++++++++++++++--------------------
 1 files changed, 73 insertions(+), 60 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 ad85357..2f39a4e 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
@@ -1,22 +1,27 @@
 package com.ruoyi.auction.controller.forepart;
 
 
-import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
-import com.baomidou.mybatisplus.core.toolkit.Wrappers;
-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.controller.forepart.dto.AuctionSalesroomGoodsDTO;
+import com.ruoyi.auction.controller.forepart.dto.ForepartAuctionBidRecordDTO;
+import com.ruoyi.common.security.annotation.InnerAuth;
+import com.ruoyi.system.api.domain.GoodsFlavorType;
+import com.ruoyi.system.api.domain.dto.BidVO;
+import com.ruoyi.system.api.domain.dto.MemberAuctionSalesroomBondDTO;
+import com.ruoyi.system.api.domain.dto.MemberAuctionSalesroomDTO;
+import com.ruoyi.auction.controller.forepart.vo.ForepartAuctionSalesroomVO;
+import com.ruoyi.auction.controller.forepart.vo.MemberAuctionSalesroomInfoVO;
+import com.ruoyi.auction.controller.forepart.vo.MemberAuctionSalesroomVO;
+import com.ruoyi.system.api.domain.AuctionSalesroom;
 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 com.ruoyi.common.core.utils.page.PageDTO;
+import com.ruoyi.system.api.domain.AppMiniLoginVO;
+import com.ruoyi.system.api.domain.dto.AppMiniLoginDTO;
+import com.ruoyi.system.api.domain.vo.PayInfoVO;
 import io.swagger.annotations.ApiOperation;
-import org.springframework.web.bind.annotation.*;
-
 import javax.annotation.Resource;
-import java.util.List;
+
+import org.springframework.web.bind.annotation.*;
 
 /**
  * <p>
@@ -34,11 +39,14 @@
     @Resource
     private IAuctionSalesroomService iAuctionSalesroomService;
 
-    @Resource
-    private IAuctionVideoService  iAuctionVideoService;
+    @InnerAuth
+    @PostMapping("/getAuctionSalesroomOne")
+    @ResponseBody
+    public R<AuctionSalesroom> getauctionSalesroomOne(@RequestBody Long auctionSalesroomId) {
+        AuctionSalesroom auctionSalesroomOne=iAuctionSalesroomService.getById(auctionSalesroomId);
+        return R.ok(auctionSalesroomOne);
 
-    @Resource
-    private SysUserClient sysUserClient;
+    }
 
     /**
      * 拍卖大屏获取拍卖信息
@@ -47,12 +55,8 @@
     @RequestMapping("getAuctionBidRecordList")
     @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);
+    public R<PageDTO<AuctionSalesroom>> getAuctionBidRecordList(@RequestBody AuctionSalesroomGoodsDTO ctionSalesroomGoodsDTO) {
+        return R.ok(iAuctionSalesroomService.getAuctionBidRecordList(ctionSalesroomGoodsDTO));
 
     }
 
@@ -63,22 +67,9 @@
     @RequestMapping("/getBaaner")
     @ResponseBody
     @ApiOperation(value = " 暖场视频or封面海报")
-    public R<ForepartAuctionSalesroomVO> getBaaner(@PathVariable("salesroomId") Integer SalesroomId) {
+    public R<ForepartAuctionSalesroomVO> getBaaner(@RequestBody AuctionSalesroomGoodsDTO ctionSalesroomGoodsDTO) {
 
-        LambdaQueryWrapper<AuctionVideo> wrapper=Wrappers.lambdaQuery();
-        wrapper.eq(AuctionVideo::getAuctionSalesroomId,SalesroomId);
-        wrapper.eq(AuctionVideo::getDelFlag,0);
-        AuctionVideo auctionVideo=iAuctionVideoService.getOne(wrapper);
-        ForepartAuctionSalesroomVO forepartAuctionSalesroomVO =new ForepartAuctionSalesroomVO();
-        AuctionSalesroom auctionSalesroom=iAuctionSalesroomService.getById(SalesroomId);
-        forepartAuctionSalesroomVO.setAuctionSalesroomStatus(auctionSalesroom.getStatus().getCode());
-        if (auctionVideo!=null){
-            forepartAuctionSalesroomVO.setUrl(auctionVideo.getPromotionVideoUrl());
-        }else{
-            forepartAuctionSalesroomVO.setUrl(auctionSalesroom.getCoverPic());
-        }
-
-        return R.ok(forepartAuctionSalesroomVO);
+        return R.ok(iAuctionSalesroomService.getBaaner(ctionSalesroomGoodsDTO));
     }
 
 
@@ -86,30 +77,52 @@
     @ResponseBody
     @ApiOperation(value = "扫码二维码获取拍卖场信息")
     public R<AuctionSalesroom> getAuctionBidRecordOne(@RequestBody ForepartAuctionBidRecordDTO arepartAuctionBidRecordDTO) {
-
-        R<SysUser> r=sysUserClient.queryUserByPhone(arepartAuctionBidRecordDTO.getPhone());
-        SysUser sysUser=r.getData();
-
-        if (sysUser!=null){
-            R.fail("手机号未注册");
-        }
-
-        if (!sysUser.getPassword().equals(arepartAuctionBidRecordDTO.getPassword())){
-            R.fail("密码输入错误");
-        }
-
-        if (!sysUser.getUserType().equals("2")){
-            R.fail("该人员不是拍卖师");
-        }
-
-        LambdaQueryWrapper<AuctionSalesroom> wrapper=Wrappers.lambdaQuery();
-        wrapper.eq(AuctionSalesroom::getAuctionSalesroomNo,arepartAuctionBidRecordDTO.getAuctionSalesroomQrcode());
-        wrapper.eq(AuctionSalesroom::getDelFlag,0);
-        AuctionSalesroom auctionBidRecord=iAuctionSalesroomService.getOne(wrapper);
-
-        return R.ok(auctionBidRecord);
-
+        return R.ok(iAuctionSalesroomService.getAuctionBidRecordOne(arepartAuctionBidRecordDTO));
     }
 
+    @RequestMapping("/actionMiniLogin")
+    @ResponseBody
+    @ApiOperation(value = "拍卖师第三方登陸")
+    public R<AppMiniLoginVO> actionMiniLogin(@RequestBody AppMiniLoginDTO appMiniLoginDto) {
+        return R.ok(iAuctionSalesroomService.actionMiniLogin(appMiniLoginDto));
+    }
+
+
+    @RequestMapping("/getMemberAuctionSalesroomList")
+    @ResponseBody
+    @ApiOperation(value = "用户端拍卖场信息")
+    public R<PageDTO<MemberAuctionSalesroomVO>> getMemberAuctionSalesroomList(@RequestBody MemberAuctionSalesroomDTO MemberAuctionSalesroomDTO) {
+        return R.ok(iAuctionSalesroomService.getMemberAuctionSalesroomList(MemberAuctionSalesroomDTO));
+    }
+
+    @RequestMapping("/getMemberAuctionSalesroomInfo")
+    @ResponseBody
+    @ApiOperation(value = "用户端拍卖场信息详情")
+    public R<MemberAuctionSalesroomInfoVO> getMemberAuctionSalesroomInfo(@RequestBody MemberAuctionSalesroomDTO memberAuctionSalesroomDTO) {
+        return R.ok(iAuctionSalesroomService.getMemberAuctionSalesroomInfo(memberAuctionSalesroomDTO));
+    }
+
+    @RequestMapping("/getMemberAuctionSalesroomSweep")
+    @ResponseBody
+    @ApiOperation(value = "用户端扫一扫拍卖场信息")
+    public R<MemberAuctionSalesroomVO> getMemberAuctionSalesroomSweep(@RequestBody MemberAuctionSalesroomDTO MemberAuctionSalesroomDTO) {
+        return R.ok(iAuctionSalesroomService.getMemberAuctionSalesroomSweep(MemberAuctionSalesroomDTO));
+    }
+
+    @RequestMapping("/SaveSignUpNow")
+    @ResponseBody
+    @ApiOperation(value = "用户端拍卖立即报名")
+    public R<PayInfoVO> SaveSignUpNow(@RequestBody MemberAuctionSalesroomBondDTO memberAuctionSalesroomBondDTO) {
+        return R.ok( iAuctionSalesroomService.SaveSignUpNow(memberAuctionSalesroomBondDTO));
+    }
+
+
+    @RequestMapping("/SaveBid")
+    @ResponseBody
+    @ApiOperation(value = "用户端拍卖出价")
+    public R SaveBid(@RequestBody BidVO BidVO) {
+        iAuctionSalesroomService.SaveBid(BidVO);
+        return R.ok();
+    }
 
 }

--
Gitblit v1.7.1