Преглед изворни кода

Merge branch 'saas_2022_05_17_activity' of http://git.dayaedu.com/yonge/mec into saas_2022_05_17_activity

yonge пре 3 година
родитељ
комит
9b305cdb55

+ 2 - 2
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/LiveGoodsMapperDao.java

@@ -17,11 +17,11 @@ public interface LiveGoodsMapperDao extends BaseDAO<Integer, LiveGoodsMapper> {
 
 
     LiveGoodsMapper findByLiveIdAndGoodsId(@Param("liveId") String liveId, @Param("liveGoodsId") Integer liveGoodsId);
     LiveGoodsMapper findByLiveIdAndGoodsId(@Param("liveId") String liveId, @Param("liveGoodsId") Integer liveGoodsId);
 
 
-    List<LiveGoodsMapperDto> getLiveGoodsList(@Param("liveId") String liveId);
+    List<LiveGoodsMapperDto> getLiveGoodsList(@Param("liveId") String liveId, @Param("liveGoodsId") Integer liveGoodsId, @Param("status") Boolean status);
 
 
     void batchInsert(@Param("liveGoodsMappers") List<LiveGoodsMapper> liveGoodsMappers);
     void batchInsert(@Param("liveGoodsMappers") List<LiveGoodsMapper> liveGoodsMappers);
 
 
     int countLiveGoods(Map<String, Object> params);
     int countLiveGoods(Map<String, Object> params);
 
 
-    List<LiveGoods> queryGoodsPage(Map<String, Object> params);
+    List<LiveGoodsMapperDto> queryGoodsPage(Map<String, Object> params);
 }
 }

+ 29 - 2
mec-biz/src/main/java/com/ym/mec/biz/dal/dto/MemberPayParamDto.java

@@ -1,25 +1,52 @@
 package com.ym.mec.biz.dal.dto;
 package com.ym.mec.biz.dal.dto;
 
 
 import com.ym.mec.biz.dal.enums.PeriodEnum;
 import com.ym.mec.biz.dal.enums.PeriodEnum;
+import io.swagger.annotations.ApiModelProperty;
 
 
 import java.io.Serializable;
 import java.io.Serializable;
 import java.math.BigDecimal;
 import java.math.BigDecimal;
 
 
 public class MemberPayParamDto extends PayParamBasicDto implements Serializable {
 public class MemberPayParamDto extends PayParamBasicDto implements Serializable {
 
 
-    //前端录入实际缴费金额
+    @ApiModelProperty(value = "前端录入实际缴费金额",required = false)
     private BigDecimal amount;
     private BigDecimal amount;
 
 
+    @ApiModelProperty(value = "用于后台创建的团练宝订单购买",required = false)
     private Long paymentId;
     private Long paymentId;
 
 
-    //购买数量
+    @ApiModelProperty(value = "购买数量",required = false)
     private Integer val;
     private Integer val;
 
 
     //如果isRepeatPay = true 则需要传入订单号
     //如果isRepeatPay = true 则需要传入订单号
     private String orderNo;
     private String orderNo;
 
 
+    @ApiModelProperty(value = "年月日",required = false)
     private PeriodEnum periodEnum;
     private PeriodEnum periodEnum;
 
 
+    //直播房间号
+    @ApiModelProperty(value = "直播房间号(用于直播间商品购买)",required = false)
+    private String liveId;
+
+    //商品编号
+    @ApiModelProperty(value = "直播间商品编号(用于直播间商品购买,目前只支持1和2,1代表免费的云课堂,2代表云教练(送网管课))",required = false)
+    private Integer liveGoodsId;
+
+    public String getLiveId() {
+        return liveId;
+    }
+
+    public void setLiveId(String liveId) {
+        this.liveId = liveId;
+    }
+
+    public Integer getLiveGoodsId() {
+        return liveGoodsId;
+    }
+
+    public void setLiveGoodsId(Integer liveGoodsId) {
+        this.liveGoodsId = liveGoodsId;
+    }
+
     public PeriodEnum getPeriodEnum() {
     public PeriodEnum getPeriodEnum() {
         return periodEnum;
         return periodEnum;
     }
     }

+ 11 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/page/LiveGoodsMapperQueryInfo.java

@@ -11,6 +11,17 @@ public class LiveGoodsMapperQueryInfo extends QueryInfo {
     @ApiModelProperty(value = "直播房间号",required = false)
     @ApiModelProperty(value = "直播房间号",required = false)
     private String liveId;
     private String liveId;
 
 
+    @ApiModelProperty(value = "商品编号",required = false)
+    private Integer liveGoodsId;
+
+    public Integer getLiveGoodsId() {
+        return liveGoodsId;
+    }
+
+    public void setLiveGoodsId(Integer liveGoodsId) {
+        this.liveGoodsId = liveGoodsId;
+    }
+
     public String getLiveId() {
     public String getLiveId() {
         return liveId;
         return liveId;
     }
     }

+ 10 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/LiveGoodsMapperService.java

@@ -1,5 +1,7 @@
 package com.ym.mec.biz.service;
 package com.ym.mec.biz.service;
 
 
+import com.ym.mec.biz.dal.dao.LiveGoodsMapperDao;
+import com.ym.mec.biz.dal.dto.LiveGoodsMapperDto;
 import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.entity.LiveGoodsMapper;
 import com.ym.mec.biz.dal.entity.LiveGoodsMapper;
 import com.ym.mec.biz.dal.page.LiveGoodsMapperQueryInfo;
 import com.ym.mec.biz.dal.page.LiveGoodsMapperQueryInfo;
@@ -11,15 +13,22 @@ import java.util.List;
 
 
 public interface LiveGoodsMapperService extends BaseService<Integer, LiveGoodsMapper> {
 public interface LiveGoodsMapperService extends BaseService<Integer, LiveGoodsMapper> {
 
 
+    //新增直播间商品
     void add(List<LiveGoodsMapper> liveGoodsMappers);
     void add(List<LiveGoodsMapper> liveGoodsMappers);
 
 
+    //商品下架
     void downGoods(Integer liveGoodsId);
     void downGoods(Integer liveGoodsId);
 
 
+    //商品下架
     void downGoods(Integer liveGoodsId, String liveId);
     void downGoods(Integer liveGoodsId, String liveId);
 
 
+    //商品上架
     void upGoods(Integer liveGoodsId, String liveId);
     void upGoods(Integer liveGoodsId, String liveId);
 
 
     List<LiveGoodsMapper> findByLiveGoodsIdAndStatus(Integer goodsId, Boolean status);
     List<LiveGoodsMapper> findByLiveGoodsIdAndStatus(Integer goodsId, Boolean status);
 
 
-    PageInfo<LiveGoods> queryGoodsPage(LiveGoodsMapperQueryInfo queryInfo);
+    //分页查询
+    PageInfo<LiveGoodsMapperDto> queryGoodsPage(LiveGoodsMapperQueryInfo queryInfo);
+
+    List<LiveGoodsMapperDto> getLiveGoodsList(String liveId, Integer liveGoodsId, Boolean status);
 }
 }

+ 11 - 5
mec-biz/src/main/java/com/ym/mec/biz/service/impl/LiveGoodsMapperServiceImpl.java

@@ -2,6 +2,7 @@ package com.ym.mec.biz.service.impl;
 
 
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.ym.mec.biz.dal.dao.LiveGoodsMapperDao;
 import com.ym.mec.biz.dal.dao.LiveGoodsMapperDao;
+import com.ym.mec.biz.dal.dto.LiveGoodsMapperDto;
 import com.ym.mec.biz.dal.entity.ImLiveBroadcastRoom;
 import com.ym.mec.biz.dal.entity.ImLiveBroadcastRoom;
 import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.entity.LiveGoodsMapper;
 import com.ym.mec.biz.dal.entity.LiveGoodsMapper;
@@ -62,12 +63,12 @@ public class LiveGoodsMapperServiceImpl extends BaseServiceImpl<Integer, LiveGoo
 	}
 	}
 
 
     @Override
     @Override
-    public PageInfo<LiveGoods> queryGoodsPage(LiveGoodsMapperQueryInfo queryInfo) {
-		PageInfo<LiveGoods> pageInfo = new PageInfo<>(queryInfo.getPage(), queryInfo.getRows());
+    public PageInfo<LiveGoodsMapperDto> queryGoodsPage(LiveGoodsMapperQueryInfo queryInfo) {
+		PageInfo<LiveGoodsMapperDto> pageInfo = new PageInfo<>(queryInfo.getPage(), queryInfo.getRows());
 		Map<String, Object> params = new HashMap<String, Object>();
 		Map<String, Object> params = new HashMap<String, Object>();
 		MapUtil.populateMap(params, queryInfo);
 		MapUtil.populateMap(params, queryInfo);
 
 
-		List<LiveGoods> dataList = null;
+		List<LiveGoodsMapperDto> dataList = null;
 		int count = liveGoodsMapperDao.countLiveGoods(params);
 		int count = liveGoodsMapperDao.countLiveGoods(params);
 		if (count > 0) {
 		if (count > 0) {
 			pageInfo.setTotal(count);
 			pageInfo.setTotal(count);
@@ -81,13 +82,18 @@ public class LiveGoodsMapperServiceImpl extends BaseServiceImpl<Integer, LiveGoo
 		return pageInfo;
 		return pageInfo;
     }
     }
 
 
-    private void publishRoomMsg(ImLiveBroadcastRoom imLiveBroadcastRoom) {
+	@Override
+	public List<LiveGoodsMapperDto> getLiveGoodsList(String liveId, Integer liveGoodsId, Boolean status) {
+		return liveGoodsMapperDao.getLiveGoodsList(liveId,liveGoodsId,status);
+	}
+
+	private void publishRoomMsg(ImLiveBroadcastRoom imLiveBroadcastRoom) {
 		ImRoomMessage message = new ImRoomMessage();
 		ImRoomMessage message = new ImRoomMessage();
 		message.setIsIncludeSender(1);
 		message.setIsIncludeSender(1);
 		message.setObjectName(ImRoomMessage.LIVE_GOODS_CHANGE);
 		message.setObjectName(ImRoomMessage.LIVE_GOODS_CHANGE);
 		message.setToChatroomId(imLiveBroadcastRoom.getRoomUid());
 		message.setToChatroomId(imLiveBroadcastRoom.getRoomUid());
 		message.setFromUserId(imLiveBroadcastRoom.getSpeakerId().toString());
 		message.setFromUserId(imLiveBroadcastRoom.getSpeakerId().toString());
-		message.setContent(liveGoodsMapperDao.getLiveGoodsList(imLiveBroadcastRoom.getRoomUid()));
+		message.setContent(liveGoodsMapperDao.getLiveGoodsList(imLiveBroadcastRoom.getRoomUid(),null,true));
 		imFeignService.publishRoomMsg(message);
 		imFeignService.publishRoomMsg(message);
 	}
 	}
 
 

+ 20 - 16
mec-biz/src/main/resources/config/mybatis/LiveGoodsMapperMapper.xml

@@ -83,6 +83,9 @@
 			<if test="status != null">
 			<if test="status != null">
 				AND lgm.status_ = #{status}
 				AND lgm.status_ = #{status}
 			</if>
 			</if>
+			<if test="liveGoodsId != null">
+				AND lg.id_ = #{liveGoodsId}
+			</if>
 		</where>
 		</where>
 	</sql>
 	</sql>
 	<!-- 分页查询 -->
 	<!-- 分页查询 -->
@@ -100,6 +103,7 @@
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
 		<include refid="queryPageSql" />
 		<include refid="queryPageSql" />
 	</select>
 	</select>
+
 	<select id="findByLiveGoodsIdAndStatus" resultMap="LiveGoodsMapper">
 	<select id="findByLiveGoodsIdAndStatus" resultMap="LiveGoodsMapper">
 		SELECT * FROM live_goods_mapper WHERE goods_id_ = #{liveGoodsId} AND status_ = #{status}
 		SELECT * FROM live_goods_mapper WHERE goods_id_ = #{liveGoodsId} AND status_ = #{status}
 	</select>
 	</select>
@@ -107,6 +111,19 @@
 		SELECT * FROM live_goods_mapper WHERE live_id_ = #{liveId} AND goods_id_ = #{liveGoodsId}
 		SELECT * FROM live_goods_mapper WHERE live_id_ = #{liveId} AND goods_id_ = #{liveGoodsId}
 	</select>
 	</select>
 
 
+	<sql id="queryGoodsPageSql">
+		<where>
+			<if test="liveId != null and liveId != ''">
+				AND lgm.live_id_ = #{liveId}
+			</if>
+			<if test="status != null">
+				AND lgm.status_ = #{status}
+			</if>
+			<if test="liveGoodsId != null">
+				AND lg.id_ = #{liveGoodsId}
+			</if>
+		</where>
+	</sql>
 	<resultMap id="LiveGoodsMapperDto" type="com.ym.mec.biz.dal.dto.LiveGoodsMapperDto">
 	<resultMap id="LiveGoodsMapperDto" type="com.ym.mec.biz.dal.dto.LiveGoodsMapperDto">
 		<result column="id_" property="id" />
 		<result column="id_" property="id" />
 		<result column="image_" property="image" />
 		<result column="image_" property="image" />
@@ -122,31 +139,18 @@
 		SELECT lg.*,lgm.status_
 		SELECT lg.*,lgm.status_
 		FROM live_goods_mapper lgm
 		FROM live_goods_mapper lgm
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
-		WHERE lgm.live_id_ = #{liveId}
+		<include refid="queryGoodsPageSql"/>
 	</select>
 	</select>
-	<sql id="queryPageSqlForGoods">
-		<where>
-			<if test="liveId != null and liveId != ''">
-				AND lgm.live_id_ = #{liveId}
-			</if>
-			<if test="search != null and search != ''">
-				AND (lg.name_ LIKE '%${search}%' OR lg.id_ = ${search})
-			</if>
-			<if test="status != null">
-				AND lgm.status_ = #{status}
-			</if>
-		</where>
-	</sql>
 	<select id="countLiveGoods" resultType="java.lang.Integer">
 	<select id="countLiveGoods" resultType="java.lang.Integer">
 		SELECT COUNT(lgm.id_) FROM live_goods_mapper lgm
 		SELECT COUNT(lgm.id_) FROM live_goods_mapper lgm
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
-		<include refid="queryPageSqlForGoods" />
+		<include refid="queryPageSql" />
 	</select>
 	</select>
 	<select id="queryGoodsPage" resultMap="LiveGoodsMapperDto">
 	<select id="queryGoodsPage" resultMap="LiveGoodsMapperDto">
 		SELECT lg.*,lgm.status_
 		SELECT lg.*,lgm.status_
 		FROM live_goods_mapper lgm
 		FROM live_goods_mapper lgm
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
 		LEFT JOIN live_goods lg ON lgm.goods_id_ = lg.id_
-		<include refid="queryPageSqlForGoods" />
+		<include refid="queryPageSql" />
 		ORDER BY lgm.id_
 		ORDER BY lgm.id_
 		<include refid="global.limit"/>
 		<include refid="global.limit"/>
 	</select>
 	</select>

+ 24 - 2
mec-student/src/main/java/com/ym/mec/student/controller/LiveGoodsMapperController.java

@@ -1,16 +1,24 @@
 package com.ym.mec.student.controller;
 package com.ym.mec.student.controller;
 
 
+import com.ym.mec.biz.dal.dto.LiveGoodsMapperDto;
+import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.page.LiveGoodsMapperQueryInfo;
 import com.ym.mec.biz.dal.page.LiveGoodsMapperQueryInfo;
 import com.ym.mec.biz.service.LiveGoodsMapperService;
 import com.ym.mec.biz.service.LiveGoodsMapperService;
 import com.ym.mec.common.controller.BaseController;
 import com.ym.mec.common.controller.BaseController;
 import com.ym.mec.common.entity.HttpResponseResult;
 import com.ym.mec.common.entity.HttpResponseResult;
+import com.ym.mec.common.page.PageInfo;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiOperation;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 import org.springframework.web.bind.annotation.RestController;
 
 
+import java.util.List;
+
 @Api(tags = "直播商品关联管理")
 @Api(tags = "直播商品关联管理")
 @RequestMapping("liveGoodsMapper")
 @RequestMapping("liveGoodsMapper")
 @RestController
 @RestController
@@ -21,7 +29,21 @@ public class LiveGoodsMapperController extends BaseController {
 
 
     @ApiOperation("分页查询直播间商品")
     @ApiOperation("分页查询直播间商品")
     @PostMapping("/page")
     @PostMapping("/page")
-    public HttpResponseResult page(LiveGoodsMapperQueryInfo queryInfo) {
-        return succeed(liveGoodsMapperService.queryPage(queryInfo));
+    public HttpResponseResult<PageInfo<LiveGoodsMapperDto>> page(LiveGoodsMapperQueryInfo queryInfo) {
+        return succeed(liveGoodsMapperService.queryGoodsPage(queryInfo));
+    }
+
+    @ApiOperation("获取直播间商品详情")
+    @GetMapping(value = "/getGoodsDetail")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "liveGoodsId", value = "商品编号", required = true, dataType = "long"),
+            @ApiImplicitParam(name = "liveId", value = "房间号", required = true,dataType = "String")
+    })
+    public HttpResponseResult<LiveGoodsMapperDto> getGoodsDetail(Integer liveGoodsId, String liveId) {
+        List<LiveGoodsMapperDto> liveGoodsList = liveGoodsMapperService.getLiveGoodsList(liveId, liveGoodsId, null);
+        if (liveGoodsList.size() > 0) {
+            return succeed(liveGoodsList.get(0));
+        }
+        return failed("商品不存在");
     }
     }
 }
 }

+ 4 - 3
mec-student/src/main/java/com/ym/mec/student/controller/MemberRankController.java

@@ -114,9 +114,10 @@ public class MemberRankController extends BaseController {
     @ApiOperation(value = "2022小小训练营活动购买会员")
     @ApiOperation(value = "2022小小训练营活动购买会员")
     @PostMapping("/activeBuy")
     @PostMapping("/activeBuy")
     public HttpResponseResult ActiveBuy(@RequestBody MemberPayParamDto memberPayParamDto) throws Exception {
     public HttpResponseResult ActiveBuy(@RequestBody MemberPayParamDto memberPayParamDto) throws Exception {
-		String startTimeStr = sysConfigDao.findConfigValue("cloud_teacher_active_start_time");
-		String endTimeStr = sysConfigDao.findConfigValue("cloud_teacher_active_end_time");
-        SysConfigService.checkActivityDate(startTimeStr,endTimeStr);
+//		String startTimeStr = sysConfigDao.findConfigValue("cloud_teacher_active_start_time");
+//		String endTimeStr = sysConfigDao.findConfigValue("cloud_teacher_active_end_time");
+//        SysConfigService.checkActivityDate(startTimeStr,endTimeStr);
+
 		return memberRankSettingService.activeBuy(memberPayParamDto);
 		return memberRankSettingService.activeBuy(memberPayParamDto);
     }
     }
 
 

+ 8 - 4
mec-web/src/main/java/com/ym/mec/web/controller/LiveGoodsController.java

@@ -9,10 +9,7 @@ import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiOperation;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.security.access.prepost.PreAuthorize;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 
 @Api(tags = "直播间商品管理")
 @Api(tags = "直播间商品管理")
 @RequestMapping("liveGoods")
 @RequestMapping("liveGoods")
@@ -22,6 +19,13 @@ public class LiveGoodsController extends BaseController {
     @Autowired
     @Autowired
     private LiveGoodsService liveGoodsService;
     private LiveGoodsService liveGoodsService;
 
 
+    @ApiOperation("获取商品详情")
+    @GetMapping(value = "/get")
+    @PreAuthorize("@pcs.hasPermissions('liveGoods/get')")
+    public HttpResponseResult get(Integer goodsId) {
+        return succeed(liveGoodsService.get(goodsId));
+    }
+
     @ApiOperation("分页查询直播间商品")
     @ApiOperation("分页查询直播间商品")
     @PostMapping(value = "/page")
     @PostMapping(value = "/page")
     @PreAuthorize("@pcs.hasPermissions('liveGoods/page')")
     @PreAuthorize("@pcs.hasPermissions('liveGoods/page')")

+ 14 - 5
mec-web/src/main/java/com/ym/mec/web/controller/LiveGoodsMapperController.java

@@ -1,5 +1,6 @@
 package com.ym.mec.web.controller;
 package com.ym.mec.web.controller;
 
 
+import com.ym.mec.biz.dal.dto.LiveGoodsMapperDto;
 import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.entity.LiveGoods;
 import com.ym.mec.biz.dal.entity.LiveGoodsMapper;
 import com.ym.mec.biz.dal.entity.LiveGoodsMapper;
 import com.ym.mec.biz.dal.page.LiveGoodsMapperQueryInfo;
 import com.ym.mec.biz.dal.page.LiveGoodsMapperQueryInfo;
@@ -15,10 +16,7 @@ import io.swagger.annotations.ApiOperation;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.security.access.prepost.PreAuthorize;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 
 import java.util.List;
 import java.util.List;
 
 
@@ -33,7 +31,7 @@ public class LiveGoodsMapperController extends BaseController {
     @ApiOperation("分页查询直播间商品")
     @ApiOperation("分页查询直播间商品")
     @PostMapping("/page")
     @PostMapping("/page")
     @PreAuthorize("@pcs.hasPermissions('liveGoodsMapper/page')")
     @PreAuthorize("@pcs.hasPermissions('liveGoodsMapper/page')")
-    public HttpResponseResult<PageInfo<LiveGoods>> page(LiveGoodsMapperQueryInfo queryInfo) {
+    public HttpResponseResult<PageInfo<LiveGoodsMapperDto>> page(LiveGoodsMapperQueryInfo queryInfo) {
         return succeed(liveGoodsMapperService.queryGoodsPage(queryInfo));
         return succeed(liveGoodsMapperService.queryGoodsPage(queryInfo));
     }
     }
 
 
@@ -45,6 +43,17 @@ public class LiveGoodsMapperController extends BaseController {
         return succeed();
         return succeed();
     }
     }
 
 
+    @ApiOperation("获取直播间商品详情")
+    @GetMapping(value = "/getGoodsDetail")
+    @PreAuthorize("@pcs.hasPermissions('liveGoodsMapper/getGoodsDetail')")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "liveGoodsId", value = "商品编号", required = true, dataType = "long"),
+            @ApiImplicitParam(name = "liveId", value = "房间号", required = true,dataType = "String")
+    })
+    public HttpResponseResult<LiveGoodsMapperDto> getGoodsDetail(Integer liveGoodsId, String liveId) {
+        return succeed(liveGoodsMapperService.getLiveGoodsList(liveId,liveGoodsId,null).get(0));
+    }
+
     @ApiOperation("上架、下架直播间商品")
     @ApiOperation("上架、下架直播间商品")
     @PostMapping("/updateStatus")
     @PostMapping("/updateStatus")
     @PreAuthorize("@pcs.hasPermissions('liveGoodsMapper/updateStatus')")
     @PreAuthorize("@pcs.hasPermissions('liveGoodsMapper/updateStatus')")