Ver código fonte

直播中奖记录 抽奖信息 订单信息 售后信息

yuhongqi 1 mês atrás
pai
commit
839a4f27b4
37 arquivos alterados com 944 adições e 87 exclusões
  1. 3 2
      fs-admin/src/main/java/com/fs/live/controller/LiveAfterSalesController.java
  2. 6 0
      fs-admin/src/main/java/com/fs/live/controller/LiveOrderController.java
  3. 106 0
      fs-admin/src/main/java/com/fs/live/controller/LiveOrderPaymentController.java
  4. 11 0
      fs-admin/src/main/java/com/fs/live/controller/LiveUserLotteryRecordController.java
  5. 9 0
      fs-admin/src/main/java/com/fs/live/controller/LiveVideoController.java
  6. 2 1
      fs-common/src/main/java/com/fs/common/vo/LiveVo.java
  7. 98 0
      fs-company/src/main/java/com/fs/company/controller/live/LiveAfterSalesController.java
  8. 1 0
      fs-company/src/main/java/com/fs/company/controller/live/LiveController.java
  9. 4 0
      fs-company/src/main/java/com/fs/company/controller/live/LiveOrderController.java
  10. 108 0
      fs-company/src/main/java/com/fs/company/controller/live/LiveUserLotteryRecordController.java
  11. 9 0
      fs-company/src/main/java/com/fs/company/controller/live/LiveVideoController.java
  12. 1 1
      fs-service-system/src/main/java/com/fs/live/domain/LiveVideo.java
  13. 3 0
      fs-service-system/src/main/java/com/fs/live/mapper/LiveAfterSalesMapper.java
  14. 3 0
      fs-service-system/src/main/java/com/fs/live/mapper/LiveMapper.java
  15. 5 0
      fs-service-system/src/main/java/com/fs/live/mapper/LiveOrderPaymentMapper.java
  16. 3 0
      fs-service-system/src/main/java/com/fs/live/mapper/LiveUserLotteryRecordMapper.java
  17. 6 0
      fs-service-system/src/main/java/com/fs/live/mapper/LiveVideoMapper.java
  18. 3 0
      fs-service-system/src/main/java/com/fs/live/service/ILiveAfterSalesService.java
  19. 5 0
      fs-service-system/src/main/java/com/fs/live/service/ILiveOrderPaymentService.java
  20. 3 1
      fs-service-system/src/main/java/com/fs/live/service/ILiveService.java
  21. 3 0
      fs-service-system/src/main/java/com/fs/live/service/ILiveUserLotteryRecordService.java
  22. 5 1
      fs-service-system/src/main/java/com/fs/live/service/ILiveVideoService.java
  23. 13 0
      fs-service-system/src/main/java/com/fs/live/service/impl/LiveAfterSalesServiceImpl.java
  24. 14 0
      fs-service-system/src/main/java/com/fs/live/service/impl/LiveOrderPaymentServiceImpl.java
  25. 20 9
      fs-service-system/src/main/java/com/fs/live/service/impl/LiveServiceImpl.java
  26. 7 0
      fs-service-system/src/main/java/com/fs/live/service/impl/LiveUserLotteryRecordServiceImpl.java
  27. 16 1
      fs-service-system/src/main/java/com/fs/live/service/impl/LiveVideoServiceImpl.java
  28. 117 0
      fs-service-system/src/main/java/com/fs/live/vo/LiveAfterSalesVo.java
  29. 126 0
      fs-service-system/src/main/java/com/fs/live/vo/LiveOrderPaymentVo.java
  30. 42 0
      fs-service-system/src/main/java/com/fs/live/vo/LiveUserLotteryRecordVo.java
  31. 35 0
      fs-service-system/src/main/resources/mapper/live/LiveAfterSalesMapper.xml
  32. 33 18
      fs-service-system/src/main/resources/mapper/live/LiveOrderMapper.xml
  33. 47 0
      fs-service-system/src/main/resources/mapper/live/LiveOrderPaymentMapper.xml
  34. 7 0
      fs-service-system/src/main/resources/mapper/live/LiveUserLotteryRecordMapper.xml
  35. 19 2
      fs-user-app/src/main/java/com/fs/app/controller/LiveController.java
  36. 1 1
      fs-user-app/src/main/java/com/fs/app/facade/impl/LiveFacadeServiceImpl.java
  37. 50 50
      fs-user-app/src/main/java/com/fs/app/vo/LiveVo.java

+ 3 - 2
fs-admin/src/main/java/com/fs/live/controller/LiveAfterSalesController.java

@@ -8,6 +8,7 @@ import com.fs.common.enums.BusinessType;
 import com.fs.common.utils.poi.ExcelUtil;
 import com.fs.live.domain.LiveAfterSales;
 import com.fs.live.service.ILiveAfterSalesService;
+import com.fs.live.vo.LiveAfterSalesVo;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.web.bind.annotation.*;
@@ -32,10 +33,10 @@ public class LiveAfterSalesController extends BaseController
      */
     @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:list')")
     @GetMapping("/list")
-    public TableDataInfo list(LiveAfterSales liveAfterSales)
+    public TableDataInfo list(LiveAfterSalesVo liveAfterSales)
     {
         startPage();
-        List<LiveAfterSales> list = liveAfterSalesService.selectLiveAfterSalesList(liveAfterSales);
+        List<LiveAfterSalesVo> list = liveAfterSalesService.selectLiveAfterSalesVoList(liveAfterSales);
         return getDataTable(list);
     }
 

+ 6 - 0
fs-admin/src/main/java/com/fs/live/controller/LiveOrderController.java

@@ -7,6 +7,7 @@ import com.fs.common.core.domain.AjaxResult;
 import com.fs.common.core.domain.R;
 import com.fs.common.core.page.TableDataInfo;
 import com.fs.common.enums.BusinessType;
+import com.fs.common.utils.ParseUtils;
 import com.fs.common.utils.StringUtils;
 import com.fs.common.utils.poi.ExcelUtil;
 import com.fs.erp.domain.ErpDeliverys;
@@ -18,6 +19,7 @@ import com.fs.live.domain.LiveOrder;
 import com.fs.live.enums.LiveOrderCancleReason;
 import com.fs.live.service.ILiveOrderService;
 import com.fs.live.vo.LiveGoodsVo;
+import com.fs.live.vo.LiveOrderPaymentVo;
 import com.fs.live.vo.LiveOrderVo;
 import com.fs.store.service.IFsExpressService;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -66,9 +68,13 @@ public class LiveOrderController extends BaseController
     {
         startPage();
         List<LiveOrder> list = liveOrderService.selectLiveOrderList(liveOrder);
+        for (LiveOrder vo : list){
+            vo.setUserPhone(ParseUtils.parsePhone(vo.getUserPhone()));
+        }
         return getDataTable(list);
     }
 
+
     /**
      * 导出订单列表
      */

+ 106 - 0
fs-admin/src/main/java/com/fs/live/controller/LiveOrderPaymentController.java

@@ -0,0 +1,106 @@
+package com.fs.live.controller;
+
+import com.fs.common.annotation.Log;
+import com.fs.common.core.controller.BaseController;
+import com.fs.common.core.domain.AjaxResult;
+import com.fs.common.core.page.TableDataInfo;
+import com.fs.common.enums.BusinessType;
+import com.fs.common.utils.ParseUtils;
+import com.fs.common.utils.poi.ExcelUtil;
+import com.fs.live.domain.LiveOrderPayment;
+import com.fs.live.service.ILiveOrderPaymentService;
+import com.fs.live.vo.LiveOrderPaymentVo;
+import com.fs.store.vo.FsStorePaymentVO;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * 支付明细Controller
+ *
+ * @author fs
+ * @date 2025-08-07
+ */
+@RestController
+@RequestMapping("/live/order/payment")
+public class LiveOrderPaymentController extends BaseController
+{
+    @Autowired
+    private ILiveOrderPaymentService liveOrderPaymentService;
+
+    /**
+     * 查询支付明细列表
+     */
+    @GetMapping("/list")
+    public TableDataInfo list(LiveOrderPayment liveOrderPayment)
+    {
+        startPage();
+        List<LiveOrderPayment> list = liveOrderPaymentService.selectLiveOrderPaymentList(liveOrderPayment);
+        return getDataTable(list);
+    }
+    /**
+     * 查询支付明细列表
+     */
+    @GetMapping
+    public TableDataInfo listNew(LiveOrderPaymentVo liveOrderPayment)
+    {
+        startPage();
+        List<LiveOrderPaymentVo> list = liveOrderPaymentService.selectLiveOrderPaymentVoList(liveOrderPayment);
+        for (LiveOrderPaymentVo vo : list){
+            vo.setUserPhone(ParseUtils.parsePhone(vo.getUserPhone()));
+        }
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出支付明细列表
+     */
+    @Log(title = "支付明细", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(LiveOrderPayment liveOrderPayment)
+    {
+        List<LiveOrderPayment> list = liveOrderPaymentService.selectLiveOrderPaymentList(liveOrderPayment);
+        ExcelUtil<LiveOrderPayment> util = new ExcelUtil<LiveOrderPayment>(LiveOrderPayment.class);
+        return util.exportExcel(list, "支付明细数据");
+    }
+
+    /**
+     * 获取支付明细详细信息
+     */
+    @GetMapping(value = "/{paymentId}")
+    public AjaxResult getInfo(@PathVariable("paymentId") Long paymentId)
+    {
+        return AjaxResult.success(liveOrderPaymentService.selectLiveOrderPaymentByPaymentIdNew(paymentId));
+    }
+
+    /**
+     * 新增支付明细
+     */
+    @Log(title = "支付明细", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody LiveOrderPayment liveOrderPayment)
+    {
+        return toAjax(liveOrderPaymentService.insertLiveOrderPayment(liveOrderPayment));
+    }
+
+    /**
+     * 修改支付明细
+     */
+    @Log(title = "支付明细", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody LiveOrderPayment liveOrderPayment)
+    {
+        return toAjax(liveOrderPaymentService.updateLiveOrderPayment(liveOrderPayment));
+    }
+
+    /**
+     * 删除支付明细
+     */
+    @Log(title = "支付明细", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{paymentIds}")
+    public AjaxResult remove(@PathVariable Long[] paymentIds)
+    {
+        return toAjax(liveOrderPaymentService.deleteLiveOrderPaymentByPaymentIds(paymentIds));
+    }
+}

+ 11 - 0
fs-admin/src/main/java/com/fs/live/controller/LiveUserLotteryRecordController.java

@@ -3,6 +3,7 @@ package com.fs.live.controller;
 import com.fs.common.annotation.Log;
 import com.fs.common.core.controller.BaseController;
 import com.fs.common.core.domain.AjaxResult;
+import com.fs.common.core.domain.R;
 import com.fs.common.core.page.TableDataInfo;
 import com.fs.common.enums.BusinessType;
 import com.fs.common.utils.poi.ExcelUtil;
@@ -94,4 +95,14 @@ public class LiveUserLotteryRecordController extends BaseController
     {
         return toAjax(liveUserLotteryRecordService.deleteLiveUserLotteryRecordByIds(ids));
     }
+
+    /**
+     * 查询直播用户中奖记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:list')")
+    @PostMapping("/info")
+    public R info(@RequestBody LiveUserLotteryRecord liveUserLotteryRecord)
+    {
+        return liveUserLotteryRecordService.selectRecordByLiveIdAndLotteryId(liveUserLotteryRecord);
+    }
 }

+ 9 - 0
fs-admin/src/main/java/com/fs/live/controller/LiveVideoController.java

@@ -72,6 +72,15 @@ public class LiveVideoController extends BaseController
         return AjaxResult.success(liveVideoService.selectLiveVideoByLiveId(liveId));
     }
 
+    /**
+     * 获取直播视频详细信息
+     */
+    @GetMapping(value = "/preview/{liveId}")
+    public AjaxResult getLiveVideoByLiveIdAndType(@PathVariable("liveId") Long liveId)
+    {
+        return AjaxResult.success(liveVideoService.selectLiveVideoByLiveIdAndType(liveId,3));
+    }
+
     /**
      * 新增直播视频
      */

+ 2 - 1
fs-common/src/main/java/com/fs/common/vo/LiveVo.java

@@ -1,4 +1,4 @@
-package com.fs.app.vo;
+package com.fs.common.vo;
 
 
 import com.fasterxml.jackson.annotation.JsonFormat;
@@ -46,4 +46,5 @@ public class LiveVo {
 
     /** 上下架 */
     private Integer isShow;
+    private String previewUrl;
 }

+ 98 - 0
fs-company/src/main/java/com/fs/company/controller/live/LiveAfterSalesController.java

@@ -0,0 +1,98 @@
+package com.fs.company.controller.live;
+
+import com.fs.common.annotation.Log;
+import com.fs.common.core.controller.BaseController;
+import com.fs.common.core.domain.AjaxResult;
+import com.fs.common.core.page.TableDataInfo;
+import com.fs.common.enums.BusinessType;
+import com.fs.common.utils.poi.ExcelUtil;
+import com.fs.live.domain.LiveAfterSales;
+import com.fs.live.service.ILiveAfterSalesService;
+import com.fs.live.vo.LiveAfterSalesVo;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * 售后记录Controller
+ *
+ * @author fs
+ * @date 2025-07-08
+ */
+@RestController
+@RequestMapping("/live/liveAfteraSales")
+public class LiveAfterSalesController extends BaseController
+{
+    @Autowired
+    private ILiveAfterSalesService liveAfterSalesService;
+
+    /**
+     * 查询售后记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(LiveAfterSalesVo liveAfterSales)
+    {
+        startPage();
+        List<LiveAfterSalesVo> list = liveAfterSalesService.selectLiveAfterSalesVoList(liveAfterSales);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出售后记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:export')")
+    @Log(title = "售后记录", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(LiveAfterSales liveAfterSales)
+    {
+        List<LiveAfterSales> list = liveAfterSalesService.selectLiveAfterSalesList(liveAfterSales);
+        ExcelUtil<LiveAfterSales> util = new ExcelUtil<LiveAfterSales>(LiveAfterSales.class);
+        return util.exportExcel(list, "售后记录数据");
+    }
+
+    /**
+     * 获取售后记录详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(liveAfterSalesService.selectLiveAfterSalesById(id));
+    }
+
+    /**
+     * 新增售后记录
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:add')")
+    @Log(title = "售后记录", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody LiveAfterSales liveAfterSales)
+    {
+        return toAjax(liveAfterSalesService.insertLiveAfterSales(liveAfterSales));
+    }
+
+    /**
+     * 修改售后记录
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:edit')")
+    @Log(title = "售后记录", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody LiveAfterSales liveAfterSales)
+    {
+        return toAjax(liveAfterSalesService.updateLiveAfterSales(liveAfterSales));
+    }
+
+    /**
+     * 删除售后记录
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveAfteraSales:remove')")
+    @Log(title = "售后记录", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(liveAfterSalesService.deleteLiveAfterSalesByIds(ids));
+    }
+}

+ 1 - 0
fs-company/src/main/java/com/fs/company/controller/live/LiveController.java

@@ -188,6 +188,7 @@ public class LiveController extends BaseController
         return liveService.getLiveRoom(liveId);
     }
 
+
     @PostMapping("/checkLive")
     public R checkLiving(@RequestBody Map<String, String> payload) {
         return liveService.checkLiving(payload);

+ 4 - 0
fs-company/src/main/java/com/fs/company/controller/live/LiveOrderController.java

@@ -7,6 +7,7 @@ import com.fs.common.core.domain.AjaxResult;
 import com.fs.common.core.domain.R;
 import com.fs.common.core.page.TableDataInfo;
 import com.fs.common.enums.BusinessType;
+import com.fs.common.utils.ParseUtils;
 import com.fs.common.utils.StringUtils;
 import com.fs.common.utils.poi.ExcelUtil;
 import com.fs.core.security.SecurityUtils;
@@ -80,6 +81,9 @@ public class LiveOrderController extends BaseController
         Long companyId = SecurityUtils.getLoginUser().getCompany().getCompanyId();
         liveOrder.setCompanyId(companyId);
         List<LiveOrder> list = liveOrderService.selectLiveOrderList(liveOrder);
+        for (LiveOrder vo : list){
+            vo.setUserPhone(ParseUtils.parsePhone(vo.getUserPhone()));
+        }
         return getDataTable(list);
     }
 

+ 108 - 0
fs-company/src/main/java/com/fs/company/controller/live/LiveUserLotteryRecordController.java

@@ -0,0 +1,108 @@
+package com.fs.company.controller.live;
+
+import com.fs.common.annotation.Log;
+import com.fs.common.core.controller.BaseController;
+import com.fs.common.core.domain.AjaxResult;
+import com.fs.common.core.domain.R;
+import com.fs.common.core.page.TableDataInfo;
+import com.fs.common.enums.BusinessType;
+import com.fs.common.utils.poi.ExcelUtil;
+import com.fs.live.domain.LiveUserLotteryRecord;
+import com.fs.live.service.ILiveUserLotteryRecordService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * 直播用户中奖记录Controller
+ *
+ * @author fs
+ * @date 2025-07-17
+ */
+@RestController
+@RequestMapping("/live/liveUserLotteryRecord")
+public class LiveUserLotteryRecordController extends BaseController
+{
+    @Autowired
+    private ILiveUserLotteryRecordService liveUserLotteryRecordService;
+
+    /**
+     * 查询直播用户中奖记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(LiveUserLotteryRecord liveUserLotteryRecord)
+    {
+        startPage();
+        List<LiveUserLotteryRecord> list = liveUserLotteryRecordService.selectLiveUserLotteryRecordList(liveUserLotteryRecord);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出直播用户中奖记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:export')")
+    @Log(title = "直播用户中奖记录", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(LiveUserLotteryRecord liveUserLotteryRecord)
+    {
+        List<LiveUserLotteryRecord> list = liveUserLotteryRecordService.selectLiveUserLotteryRecordList(liveUserLotteryRecord);
+        ExcelUtil<LiveUserLotteryRecord> util = new ExcelUtil<LiveUserLotteryRecord>(LiveUserLotteryRecord.class);
+        return util.exportExcel(list, "直播用户中奖记录数据");
+    }
+
+    /**
+     * 获取直播用户中奖记录详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(liveUserLotteryRecordService.selectLiveUserLotteryRecordById(id));
+    }
+
+    /**
+     * 新增直播用户中奖记录
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:add')")
+    @Log(title = "直播用户中奖记录", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody LiveUserLotteryRecord liveUserLotteryRecord)
+    {
+        return toAjax(liveUserLotteryRecordService.insertLiveUserLotteryRecord(liveUserLotteryRecord));
+    }
+
+    /**
+     * 修改直播用户中奖记录
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:edit')")
+    @Log(title = "直播用户中奖记录", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody LiveUserLotteryRecord liveUserLotteryRecord)
+    {
+        return toAjax(liveUserLotteryRecordService.updateLiveUserLotteryRecord(liveUserLotteryRecord));
+    }
+
+    /**
+     * 删除直播用户中奖记录
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:remove')")
+    @Log(title = "直播用户中奖记录", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(liveUserLotteryRecordService.deleteLiveUserLotteryRecordByIds(ids));
+    }
+
+    /**
+     * 查询直播用户中奖记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('live:liveUserLotteryRecord:list')")
+    @PostMapping("/info")
+    public R info(@RequestBody LiveUserLotteryRecord liveUserLotteryRecord)
+    {
+        return liveUserLotteryRecordService.selectRecordByLiveIdAndLotteryId(liveUserLotteryRecord);
+    }
+}

+ 9 - 0
fs-company/src/main/java/com/fs/company/controller/live/LiveVideoController.java

@@ -71,6 +71,15 @@ public class LiveVideoController extends BaseController
         return AjaxResult.success(liveVideoService.selectLiveVideoByLiveId(liveId));
     }
 
+    /**
+     * 获取直播视频详细信息
+     */
+    @GetMapping(value = "/preview/{liveId}")
+    public AjaxResult getLiveVideoByLiveIdAndType(@PathVariable("liveId") Long liveId)
+    {
+        return AjaxResult.success(liveVideoService.selectLiveVideoByLiveIdAndType(liveId,3));
+    }
+
     /**
      * 新增直播视频
      */

+ 1 - 1
fs-service-system/src/main/java/com/fs/live/domain/LiveVideo.java

@@ -29,7 +29,7 @@ public class LiveVideo extends BaseEntity {
     private String videoUrl;
 
     /** 类型 1录播 2回放 */
-    @Excel(name = "类型 1录播 2回放 -1视频库")
+    @Excel(name = "类型 1录播 2回放 -1视频库 3预告视频")
     private Integer videoType;
 
     @Excel(name = "视屏时长")

+ 3 - 0
fs-service-system/src/main/java/com/fs/live/mapper/LiveAfterSalesMapper.java

@@ -4,6 +4,7 @@ package com.fs.live.mapper;
 import com.fs.live.domain.LiveAfterSales;
 import com.fs.live.param.LiveAfterSalesListUParam;
 import com.fs.live.vo.LiveAfterSalesListUVO;
+import com.fs.live.vo.LiveAfterSalesVo;
 import org.apache.ibatis.annotations.Param;
 import org.apache.ibatis.annotations.Select;
 
@@ -88,4 +89,6 @@ public interface LiveAfterSalesMapper {
             "where s.sales_status=0 and s.status=0 and date_format(date_add(s.create_time, interval 24 hour),'%Y-%m-%d %H') &gt;= date_format(now(),'%Y-%m-%d %H')  " +
             "</script>"})
     List<LiveAfterSales> selectLiveAfterSalesByDoAudit();
+
+    List<LiveAfterSalesVo> selectLiveAfterSalesVoList(LiveAfterSalesVo liveAfterSales);
 }

+ 3 - 0
fs-service-system/src/main/java/com/fs/live/mapper/LiveMapper.java

@@ -117,4 +117,7 @@ public interface LiveMapper
     List<Live> selectNoEndLiveList();
 
     void updateStatusAndTimeBatchById(@Param("liveList") List<Live> list);
+
+    @Select("select * from live where company_id = #{companyId} or company_id is null")
+    List<Live> liveCompanyList(@Param("companyId") Long companyId);
 }

+ 5 - 0
fs-service-system/src/main/java/com/fs/live/mapper/LiveOrderPaymentMapper.java

@@ -2,6 +2,7 @@ package com.fs.live.mapper;
 
 
 import com.fs.live.domain.LiveOrderPayment;
+import com.fs.live.vo.LiveOrderPaymentVo;
 import org.apache.ibatis.annotations.Param;
 import org.apache.ibatis.annotations.Select;
 
@@ -71,4 +72,8 @@ public interface LiveOrderPaymentMapper {
 
     @Select("select * from live_order_payment where   business_id=#{businessId} and status=1")
     LiveOrderPayment selectByBuissnessId(@Param("businessId") Long businessId);
+
+    List<LiveOrderPaymentVo> selectLiveOrderPaymentVoList(LiveOrderPaymentVo liveOrderPayment);
+
+    LiveOrderPaymentVo selectLiveOrderPaymentByPaymentIdNew(@Param("paymentId") Long paymentId);
 }

+ 3 - 0
fs-service-system/src/main/java/com/fs/live/mapper/LiveUserLotteryRecordMapper.java

@@ -3,6 +3,7 @@ package com.fs.live.mapper;
 import java.util.List;
 
 import com.fs.live.domain.LiveUserLotteryRecord;
+import com.fs.live.vo.LiveUserLotteryRecordVo;
 import org.apache.ibatis.annotations.Select;
 
 /**
@@ -62,4 +63,6 @@ public interface LiveUserLotteryRecordMapper {
 
     @Select("SELECT EXISTS(SELECT 1 FROM live_user_lottery_record WHERE user_id = #{userId} AND red_id = #{redId})")
     boolean existsByUserIdAndRedId(Long lotteryId, String userId);
+
+    List<LiveUserLotteryRecordVo> selectRecordByLiveIdAndLotteryId(LiveUserLotteryRecord liveUserLotteryRecord);
 }

+ 6 - 0
fs-service-system/src/main/java/com/fs/live/mapper/LiveVideoMapper.java

@@ -80,4 +80,10 @@ public interface LiveVideoMapper
 
     @Select("select * from live_video where live_id = #{liveId}")
     List<LiveVideo> selectByLiveId(@Param("liveId")Long liveId);
+
+    @Select("select * from live_video where live_id = #{liveId} and video_type = #{videoType}")
+    List<LiveVideo> selectByLiveIdAndType(@Param("liveId")Long liveId,@Param("videoType") Integer videoType);
+
+    @Select("select * from live_video where live_id = #{liveId}")
+    List<LiveVideo> selectLiveVideosByLiveId(@Param("liveId") Long liveId);
 }

+ 3 - 0
fs-service-system/src/main/java/com/fs/live/service/ILiveAfterSalesService.java

@@ -8,6 +8,7 @@ import com.fs.live.param.LiveAfterSalesDeliveryParam;
 import com.fs.live.param.LiveAfterSalesListUParam;
 import com.fs.live.param.LiveAfterSalesRevokeParam;
 import com.fs.live.vo.LiveAfterSalesListUVO;
+import com.fs.live.vo.LiveAfterSalesVo;
 import com.fs.store.param.LiveAfterSalesAudit1Param;
 
 import java.util.List;
@@ -78,4 +79,6 @@ public interface ILiveAfterSalesService {
     List<LiveAfterSales> selectLiveAfterSalesByDoAudit();
 
     R audit1(LiveAfterSalesAudit1Param audit1Param);
+
+    List<LiveAfterSalesVo> selectLiveAfterSalesVoList(LiveAfterSalesVo liveAfterSales);
 }

+ 5 - 0
fs-service-system/src/main/java/com/fs/live/service/ILiveOrderPaymentService.java

@@ -3,6 +3,7 @@ package com.fs.live.service;
 import java.util.List;
 
 import com.fs.live.domain.LiveOrderPayment;
+import com.fs.live.vo.LiveOrderPaymentVo;
 
 /**
  * 支付明细Service接口
@@ -58,4 +59,8 @@ public interface ILiveOrderPaymentService {
      * @return 结果
      */
     int deleteLiveOrderPaymentByPaymentId(Long paymentId);
+
+    List<LiveOrderPaymentVo> selectLiveOrderPaymentVoList(LiveOrderPaymentVo liveOrderPayment);
+
+    LiveOrderPaymentVo selectLiveOrderPaymentByPaymentIdNew(Long paymentId);
 }

+ 3 - 1
fs-service-system/src/main/java/com/fs/live/service/ILiveService.java

@@ -1,7 +1,7 @@
 package com.fs.live.service;
 
 
-import com.fs.app.vo.LiveVo;
+import com.fs.common.vo.LiveVo;
 import com.fs.common.core.domain.R;
 import com.fs.live.domain.Live;
 import com.fs.live.vo.LiveConfigVo;
@@ -176,4 +176,6 @@ public interface ILiveService
      * 查询直播间配并加入缓存
      */
     LiveConfigVo asyncToCacheLiveConfig(Long liveId);
+
+    List<Live> liveCompanyList(Long companyId);
 }

+ 3 - 0
fs-service-system/src/main/java/com/fs/live/service/ILiveUserLotteryRecordService.java

@@ -1,6 +1,7 @@
 package com.fs.live.service;
 
 
+import com.fs.common.core.domain.R;
 import com.fs.live.domain.LiveUserLotteryRecord;
 
 import java.util.List;
@@ -66,4 +67,6 @@ public interface ILiveUserLotteryRecordService {
     String userLottery(Long liveId, Long lotteryId, String userId);
 
     boolean existsByUserIdAndRedId(Long lotteryId, String userId);
+
+    R selectRecordByLiveIdAndLotteryId(LiveUserLotteryRecord liveUserLotteryRecord);
 }

+ 5 - 1
fs-service-system/src/main/java/com/fs/live/service/ILiveVideoService.java

@@ -11,7 +11,7 @@ import java.util.List;
  * @author fs
  * @date 2025-01-17
  */
-public interface ILiveVideoService 
+public interface ILiveVideoService
 {
     /**
      * 查询直播视频
@@ -80,4 +80,8 @@ public interface ILiveVideoService
     LiveVideo selectLiveVideoByLiveId(Long liveId);
 
     void saveOrUpdate(LiveVideo liveVideo);
+
+    List<LiveVideo> selectLiveVideosByLiveId(Long existLiveId);
+
+    LiveVideo selectLiveVideoByLiveIdAndType(Long id, int i);
 }

+ 13 - 0
fs-service-system/src/main/java/com/fs/live/service/impl/LiveAfterSalesServiceImpl.java

@@ -32,6 +32,7 @@ import com.fs.live.param.LiveAfterSalesRevokeParam;
 import com.fs.live.service.ILiveOrderItemService;
 import com.fs.live.service.ILiveOrderService;
 import com.fs.live.vo.LiveAfterSalesListUVO;
+import com.fs.live.vo.LiveAfterSalesVo;
 import com.fs.store.cache.IFsWarehousesCacheService;
 import com.fs.store.config.StoreConfig;
 import com.fs.store.domain.FsStoreAfterSales;
@@ -129,6 +130,18 @@ public class LiveAfterSalesServiceImpl implements ILiveAfterSalesService {
         return baseMapper.selectLiveAfterSalesList(liveAfterSales);
     }
 
+    /**
+     * 查询售后记录列表
+     *
+     * @param liveAfterSales 售后记录
+     * @return 售后记录
+     */
+    @Override
+    public List<LiveAfterSalesVo> selectLiveAfterSalesVoList(LiveAfterSalesVo liveAfterSales)
+    {
+        return baseMapper.selectLiveAfterSalesVoList(liveAfterSales);
+    }
+
     /**
      * 新增售后记录
      *

+ 14 - 0
fs-service-system/src/main/java/com/fs/live/service/impl/LiveOrderPaymentServiceImpl.java

@@ -5,9 +5,11 @@ import com.fs.common.utils.DateUtils;
 import com.fs.live.domain.LiveOrderPayment;
 import com.fs.live.mapper.LiveOrderPaymentMapper;
 import com.fs.live.service.ILiveOrderPaymentService;
+import com.fs.live.vo.LiveOrderPaymentVo;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import java.util.Collections;
 import java.util.List;
 
 /**
@@ -45,6 +47,16 @@ public class LiveOrderPaymentServiceImpl implements ILiveOrderPaymentService {
         return baseMapper.selectLiveOrderPaymentList(liveOrderPayment);
     }
 
+    @Override
+    public List<LiveOrderPaymentVo> selectLiveOrderPaymentVoList(LiveOrderPaymentVo liveOrderPayment) {
+        return baseMapper.selectLiveOrderPaymentVoList(liveOrderPayment);
+    }
+
+    @Override
+    public LiveOrderPaymentVo selectLiveOrderPaymentByPaymentIdNew(Long paymentId) {
+        return baseMapper.selectLiveOrderPaymentByPaymentIdNew(paymentId);
+    }
+
     /**
      * 新增支付明细
      *
@@ -93,4 +105,6 @@ public class LiveOrderPaymentServiceImpl implements ILiveOrderPaymentService {
     {
         return baseMapper.deleteLiveOrderPaymentByPaymentId(paymentId);
     }
+
+
 }

+ 20 - 9
fs-service-system/src/main/java/com/fs/live/service/impl/LiveServiceImpl.java

@@ -5,7 +5,7 @@ import cn.hutool.core.util.ObjectUtil;
 import com.alibaba.fastjson.JSON;
 import com.alibaba.fastjson.JSONObject;
 
-import com.fs.app.vo.LiveVo;
+import com.fs.common.vo.LiveVo;
 import com.fs.common.constant.LiveKeysConstant;
 import com.fs.common.core.domain.R;
 import com.fs.common.core.redis.RedisCache;
@@ -160,6 +160,10 @@ public class LiveServiceImpl implements ILiveService
         // liveVo.setStoreId(storeId);
 		BeanUtils.copyProperties(live, liveVo);
 		liveVo.setNowDuration(200L);
+        LiveVideo liveVideo = liveVideoService.selectLiveVideoByLiveIdAndType(id, 3);
+        if (liveVideo != null) {
+            liveVo.setPreviewUrl(liveVideo.getVideoUrl());
+        }
 		if(live.getStatus() == 2){
 			long seconds = live.getStartTime().until(now, ChronoUnit.SECONDS);
 			liveVo.setNowDuration(seconds);
@@ -186,6 +190,11 @@ public class LiveServiceImpl implements ILiveService
         return liveConfigVo;
     }
 
+    @Override
+    public List<Live> liveCompanyList(Long companyId) {
+        return baseMapper.liveCompanyList(companyId);
+    }
+
     /**
      * 查询企业直播
      * @param liveId            直播ID
@@ -621,14 +630,16 @@ public class LiveServiceImpl implements ILiveService
         liveData.setFollowNum(0L);
         liveDataService.insertLiveData(liveData);
         // 直播视频
-        LiveVideo liveVideo = liveVideoService.selectLiveVideoByLiveId(existLiveId);
-        if (!Objects.isNull(liveVideo)) {
-            LiveVideo videoEntity = new LiveVideo();
-            BeanUtils.copyBeanProp(videoEntity, liveVideo);
-            videoEntity.setVideoId(null);
-            videoEntity.setLiveId(newLiveId);
-            videoEntity.setCreateTime(now);
-            liveVideoService.insertLiveVideo(videoEntity);
+        List<LiveVideo> liveVideos = liveVideoService.selectLiveVideosByLiveId(existLiveId);
+        if (!liveVideos.isEmpty()) {
+            for (LiveVideo liveVideo : liveVideos) {
+                LiveVideo videoEntity = new LiveVideo();
+                BeanUtils.copyBeanProp(videoEntity, liveVideo);
+                videoEntity.setVideoId(null);
+                videoEntity.setLiveId(newLiveId);
+                videoEntity.setCreateTime(now);
+                liveVideoService.insertLiveVideo(videoEntity);
+            }
         }
         //直播间红包配置
         List<LiveRedConf> liveRedConfs = liveRedConfService.selectByLiveId(existLiveId);

+ 7 - 0
fs-service-system/src/main/java/com/fs/live/service/impl/LiveUserLotteryRecordServiceImpl.java

@@ -1,12 +1,14 @@
 package com.fs.live.service.impl;
 
 
+import com.fs.common.core.domain.R;
 import com.fs.common.utils.DateUtils;
 import com.fs.common.utils.StringUtils;
 import com.fs.live.domain.LiveLotteryConf;
 import com.fs.live.domain.LiveUserLotteryRecord;
 import com.fs.live.mapper.LiveUserLotteryRecordMapper;
 import com.fs.live.service.*;
+import com.fs.live.vo.LiveUserLotteryRecordVo;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
@@ -153,5 +155,10 @@ public class LiveUserLotteryRecordServiceImpl implements ILiveUserLotteryRecordS
         return baseMapper.existsByUserIdAndRedId(lotteryId,userId);
     }
 
+    @Override
+    public R selectRecordByLiveIdAndLotteryId(LiveUserLotteryRecord liveUserLotteryRecord) {
+        return R.ok().put("data",baseMapper.selectRecordByLiveIdAndLotteryId(liveUserLotteryRecord));
+    }
+
 
 }

+ 16 - 1
fs-service-system/src/main/java/com/fs/live/service/impl/LiveVideoServiceImpl.java

@@ -7,6 +7,7 @@ import com.fs.live.service.ILiveVideoService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import java.util.Collections;
 import java.util.Date;
 import java.util.List;
 
@@ -73,7 +74,7 @@ public class LiveVideoServiceImpl implements ILiveVideoService
             liveVideo.setCreateTime(DateUtils.getNowDate());
             return liveVideoMapper.insertLiveVideo(liveVideo);
         }
-        List<LiveVideo> liveVideos = liveVideoMapper.selectByLiveId(liveVideo.getLiveId());
+        List<LiveVideo> liveVideos = liveVideoMapper.selectByLiveIdAndType(liveVideo.getLiveId(),liveVideo.getVideoType());
         if (liveVideos!=null && !liveVideos.isEmpty()) {
             Date nowDate = DateUtils.getNowDate();
             liveVideos.forEach(liveVideoEntity -> {
@@ -152,4 +153,18 @@ public class LiveVideoServiceImpl implements ILiveVideoService
         }
     }
 
+    @Override
+    public List<LiveVideo> selectLiveVideosByLiveId(Long existLiveId) {
+        return liveVideoMapper.selectLiveVideosByLiveId(existLiveId);
+    }
+
+    @Override
+    public LiveVideo selectLiveVideoByLiveIdAndType(Long id, int i) {
+        List<LiveVideo> liveVideos = liveVideoMapper.selectByIdAndType(id, i);
+        if (liveVideos != null && !liveVideos.isEmpty()) {
+            return liveVideos.get(0);
+        }
+        return null;
+    }
+
 }

+ 117 - 0
fs-service-system/src/main/java/com/fs/live/vo/LiveAfterSalesVo.java

@@ -0,0 +1,117 @@
+package com.fs.live.vo;
+
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 售后记录对象 live_after_sales
+ *
+ * @author fs
+ * @date 2025-07-08
+ */
+@Data
+public class LiveAfterSalesVo {
+
+    /** $column.columnComment */
+    private Long id;
+
+    /** 直播ID */
+    @Excel(name = "直播ID")
+    private Long liveId;
+
+    /** 店铺ID */
+    @Excel(name = "店铺ID")
+    private Long storeId;
+
+    /** 订单ID */
+    @Excel(name = "订单ID")
+    private Long orderId;
+
+    /** 退款金额 */
+    @Excel(name = "退款金额")
+    private BigDecimal refundAmount;
+
+    /** 服务类型0仅退款1退货退款 */
+    @Excel(name = "服务类型0仅退款1退货退款")
+    private Integer refundType;
+
+    /** 申请原因 */
+    @Excel(name = "申请原因")
+    private String reasons;
+
+    /** 说明 */
+    @Excel(name = "说明")
+    private String explains;
+
+    /** 说明图片-&gt;多个用逗号分割 */
+    @Excel(name = "说明图片-&gt;多个用逗号分割")
+    private String explainImg;
+
+    /** 物流公司编码 */
+    @Excel(name = "物流公司编码")
+    private String deliveryCode;
+
+    /** 物流单号 */
+    @Excel(name = "物流单号")
+    private String deliverySn;
+
+    /** 物流名称 */
+    @Excel(name = "物流名称")
+    private String deliveryName;
+
+    /** 状态 0已提交等待平台审核 1平台已审核 等待用户发货 2 用户已发货待仓库审核 3财务审核 4退款成功 */
+    @Excel(name = "状态 0已提交等待平台审核 1平台已审核 等待用户发货 2 用户已发货待仓库审核 3财务审核 4退款成功")
+    private Integer status;
+
+    /** 售后状态 0售后中 1用户取消2商家拒绝 3已完成 */
+    @Excel(name = "售后状态 0售后中 1用户取消2商家拒绝 3已完成")
+    private Integer salesStatus;
+
+    /** 订单状态 */
+    @Excel(name = "订单状态")
+    private Integer orderStatus;
+
+    /** 逻辑删除 */
+    @Excel(name = "逻辑删除")
+    private Integer isDel;
+
+    /** 用户id */
+    @Excel(name = "用户id")
+    private Long userId;
+
+    /** 商家收货人 */
+    @Excel(name = "商家收货人")
+    private String consignee;
+
+    /** 商家手机号 */
+    @Excel(name = "商家手机号")
+    private String phoneNumber;
+
+    /** 商家地址 */
+    @Excel(name = "商家地址")
+    private String address;
+
+    /** $column.columnComment */
+    @Excel(name = "商家地址")
+    private Long companyId;
+
+    /** $column.columnComment */
+    @Excel(name = "商家地址")
+    private Long companyUserId;
+
+    /** 部门id */
+    @Excel(name = "部门id")
+    private Long deptId;
+
+    /** 创建时间 */
+    @Excel(name = "创建时间")
+    private Date createTime;
+    private String companyName;
+    private String companyUserNickName;
+    private String orderCode;
+    private String userPhone;
+
+}

+ 126 - 0
fs-service-system/src/main/java/com/fs/live/vo/LiveOrderPaymentVo.java

@@ -0,0 +1,126 @@
+package com.fs.live.vo;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fs.common.annotation.Excel;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 支付明细对象 live_order_payment
+ *
+ * @author fs
+ * @date 2025-08-07
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class LiveOrderPaymentVo extends BaseEntity{
+
+    /** ID */
+    private Long paymentId;
+
+    /** 支付订单号 */
+    @Excel(name = "支付订单号")
+    private String payCode;
+
+    /** 支付类型 weixin alipay */
+    @Excel(name = "支付类型 weixin alipay")
+    private String payTypeCode;
+
+    /** 支付金额 */
+    @Excel(name = "支付金额")
+    private BigDecimal payMoney;
+
+    /** 支付时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "支付时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date payTime;
+
+    /** 外部订单号 */
+    @Excel(name = "外部订单号")
+    private String tradeNo;
+
+    /** 用户ID */
+    @Excel(name = "用户ID")
+    private Long userId;
+
+    /** OPENID */
+    @Excel(name = "OPENID")
+    private String openId;
+
+    /** 业务类型  */
+    @Excel(name = "业务类型 ")
+    private Integer businessType;
+
+    /** 关联业务ID */
+    @Excel(name = "关联业务ID")
+    private String businessId;
+
+    /** 状态 0未支付 1已支付 -1 已退款 */
+    @Excel(name = "状态 0未支付 1已支付 -1 已退款")
+    private Integer status;
+
+    /** 交易单号 */
+    @Excel(name = "交易单号")
+    private String bankTransactionId;
+
+    /** 银行流水号 */
+    @Excel(name = "银行流水号")
+    private String bankSerialNo;
+
+    /** 退款金额 */
+    @Excel(name = "退款金额")
+    private BigDecimal refundMoney;
+
+    /** 退款时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "退款时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date refundTime;
+
+    /** 店铺ID */
+    @Excel(name = "店铺ID")
+    private Long storeId;
+
+    /** 公司id */
+    @Excel(name = "公司id")
+    private Long companyId;
+
+    /** 员工id */
+    @Excel(name = "员工id")
+    private Long companyUserId;
+
+    /** 关联业务编号 */
+    @Excel(name = "关联业务编号")
+    private String businessCode;
+
+    /** 支付方式: zb tz wx */
+    @Excel(name = "支付方式: zb tz wx")
+    private String payMode;
+
+    /** 分账状态 0未分账 1已分账 */
+    @Excel(name = "分账状态 0未分账 1已分账")
+    private Integer shareStatus;
+
+    /** 分账单号 */
+    @Excel(name = "分账单号")
+    private String shareCode;
+
+    /** 分账金额 */
+    @Excel(name = "分账金额")
+    private BigDecimal shareMoney;
+
+    /** 是否分账 */
+    @Excel(name = "是否分账")
+    private Integer isShare;
+
+    private Integer orderCode;
+    private String userPhone;
+    private String companyName;
+    private String deptName;
+    private String companyUserNickName;
+
+
+}

+ 42 - 0
fs-service-system/src/main/java/com/fs/live/vo/LiveUserLotteryRecordVo.java

@@ -0,0 +1,42 @@
+package com.fs.live.vo;
+
+
+import com.fs.common.annotation.Excel;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 直播用户中奖记录对象 live_user_lottery_record
+ *
+ * @author fs
+ * @date 2025-07-17
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class LiveUserLotteryRecordVo extends BaseEntity{
+
+    /** $column.columnComment */
+    private Long id;
+
+    /** 抽奖ID */
+    @Excel(name = "抽奖ID")
+    private Long lotteryId;
+
+    /** 直播间ID */
+    @Excel(name = "直播间ID")
+    private Long liveId;
+
+    /** 中奖用户ID */
+    @Excel(name = "中奖用户ID")
+    private Long userId;
+
+    /** 商品ID */
+    @Excel(name = "商品ID")
+    private Long productId;
+
+    private String userName;
+    private String productName;
+
+
+}

+ 35 - 0
fs-service-system/src/main/resources/mapper/live/LiveAfterSalesMapper.xml

@@ -62,6 +62,41 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="deptId != null "> and dept_id = #{deptId}</if>
         </where>
     </select>
+    <select id="selectLiveAfterSalesVoList" parameterType="com.fs.live.vo.LiveAfterSalesVo" resultType="com.fs.live.vo.LiveAfterSalesVo">
+        select las.id, las.live_id, las.store_id, las.order_id, las.refund_amount,
+        las.refund_type, las.reasons, las.explains, las.explain_img, las.delivery_code, las.delivery_sn, las.delivery_name, las.status, las.sales_status,
+        las.order_status, las.create_time, las.is_del, las.user_id, las.consignee, las.phone_number, las.address, las.company_id, las.company_user_id, las.dept_id,
+        cu.nick_name as company_user_nick_name, c.company_name,lo.order_code,lo.user_phone
+        from live_after_sales las
+        left join live_order lo on lo.order_id = las.order_id
+        left join company_user cu on cu.company_id = las.company_id
+        left join company c on c.company_id = las.company_id
+
+        <where>
+            <if test="liveId != null "> and las.live_id = #{liveId}</if>
+            <if test="storeId != null "> and las.store_id = #{storeId}</if>
+            <if test="orderId != null "> and las.order_id = #{orderId}</if>
+            <if test="refundAmount != null "> and las.refund_amount = #{refundAmount}</if>
+            <if test="refundType != null "> and las.refund_type = #{refundType}</if>
+            <if test="reasons != null  and reasons != ''"> and las.reasons = #{reasons}</if>
+            <if test="explains != null  and explains != ''"> and las.explains = #{explains}</if>
+            <if test="explainImg != null  and explainImg != ''"> and las.explain_img = #{explainImg}</if>
+            <if test="deliveryCode != null  and deliveryCode != ''"> and las.delivery_code = #{deliveryCode}</if>
+            <if test="deliverySn != null  and deliverySn != ''"> and las.delivery_sn = #{deliverySn}</if>
+            <if test="deliveryName != null  and deliveryName != ''"> and las.delivery_name like concat('%', #{deliveryName}, '%')</if>
+            <if test="status != null "> and las.status = #{status}</if>
+            <if test="salesStatus != null "> and las.sales_status = #{salesStatus}</if>
+            <if test="orderStatus != null "> and las.order_status = #{orderStatus}</if>
+            <if test="isDel != null  and isDel != ''"> and las.is_del = #{isDel}</if>
+            <if test="userId != null "> and las.user_id = #{userId}</if>
+            <if test="consignee != null  and consignee != ''"> and las.consignee = #{consignee}</if>
+            <if test="phoneNumber != null  and phoneNumber != ''"> and las.phone_number = #{phoneNumber}</if>
+            <if test="address != null  and address != ''"> and las.address = #{address}</if>
+            <if test="companyId != null "> and las.company_id = #{companyId}</if>
+            <if test="companyUserId != null "> and las.company_user_id = #{companyUserId}</if>
+            <if test="deptId != null "> and cu.dept_id = #{deptId}</if>
+        </where>
+    </select>
 
     <select id="selectLiveAfterSalesById" parameterType="Long" resultMap="LiveAfterSalesResult">
         <include refid="selectLiveAfterSalesVo"/>

+ 33 - 18
fs-service-system/src/main/resources/mapper/live/LiveOrderMapper.xml

@@ -115,36 +115,36 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <where>
             <if test="liveId != null "> and live_id = #{liveId}</if>
             <if test="storeId != null "> and store_id = #{storeId}</if>
-            <if test="orderCode != null  and orderCode != ''"> and order_code = #{orderCode}</if>
-            <if test="userId != null  and userId != ''"> and user_id = #{userId}</if>
-            <if test="userName != null  and userName != ''"> and user_name like concat('%', #{userName}, '%')</if>
-            <if test="userPhone != null  and userPhone != ''"> and user_phone = #{userPhone}</if>
-            <if test="userAddress != null  and userAddress != ''"> and user_address = #{userAddress}</if>
+            <if test="orderCode != null  and orderCode != ''"> and a.order_code = #{orderCode}</if>
+            <if test="userId != null  and userId != ''"> and a.user_id = #{userId}</if>
+            <if test="userName != null  and userName != ''"> and a.user_name like concat('%', #{userName}, '%')</if>
+            <if test="userPhone != null  and userPhone != ''"> and a.user_phone = #{userPhone}</if>
+            <if test="userAddress != null  and userAddress != ''"> and a.user_address = #{userAddress}</if>
             <if test="cartId != null  and cartId != ''"> and cart_id = #{cartId}</if>
             <if test="totalNum != null  and totalNum != ''"> and total_num = #{totalNum}</if>
             <if test="totalPrice != null "> and total_price = #{totalPrice}</if>
-            <if test="payPrice != null "> and pay_price = #{payPrice}</if>
-            <if test="payMoney != null "> and pay_money = #{payMoney}</if>
-            <if test="isPay != null  and isPay != ''"> and is_pay = #{isPay}</if>
+            <if test="payPrice != null "> and a.pay_price = #{payPrice}</if>
+            <if test="payMoney != null "> and a.pay_money = #{payMoney}</if>
+            <if test="isPay != null  and isPay != ''"> and a.is_pay = #{isPay}</if>
             <if test="payTime != null "> and pay_time = #{payTime}</if>
             <if test="payType != null  and payType != ''"> and pay_type = #{payType}</if>
-            <if test="status != null "> and status = #{status}</if>
+            <if test="status != null "> and a.status = #{status}</if>
             <if test="refundStatus != null  and refundStatus != ''"> and refund_status = #{refundStatus}</if>
             <if test="refundImg != null  and refundImg != ''"> and refund_img = #{refundImg}</if>
             <if test="refundExplain != null  and refundExplain != ''"> and refund_explain = #{refundExplain}</if>
             <if test="refundTime != null "> and refund_time = #{refundTime}</if>
             <if test="refundReason != null  and refundReason != ''"> and refund_reason = #{refundReason}</if>
             <if test="refundMoney != null "> and refund_money = #{refundMoney}</if>
-            <if test="deliveryCode != null  and deliveryCode != ''"> and delivery_code = #{deliveryCode}</if>
-            <if test="deliveryName != null  and deliveryName != ''"> and delivery_name like concat('%', #{deliveryName}, '%')</if>
-            <if test="deliverySn != null  and deliverySn != ''"> and delivery_sn = #{deliverySn}</if>
+            <if test="deliveryCode != null  and deliveryCode != ''"> and a.delivery_code = #{deliveryCode}</if>
+            <if test="deliveryName != null  and deliveryName != ''"> and a.delivery_name like concat('%', #{deliveryName}, '%')</if>
+            <if test="deliverySn != null  and deliverySn != ''"> and a.delivery_sn = #{deliverySn}</if>
             <if test="isDel != null  and isDel != ''"> and is_del = #{isDel}</if>
             <if test="costPrice != null "> and cost_price = #{costPrice}</if>
             <if test="verifyCode != null  and verifyCode != ''"> and verify_code = #{verifyCode}</if>
             <if test="shippingType != null "> and shipping_type = #{shippingType}</if>
             <if test="isChannel != null  and isChannel != ''"> and is_channel = #{isChannel}</if>
-            <if test="finishTime != null ">and finish_time >= #{finishTime} and finish_time &lt; date_add(#{finishTime}, interval 1 day)</if>
-            <if test="deliveryTime != null  and deliveryTime != ''"> and delivery_time = #{deliveryTime}</if>
+            <if test="finishTime != null ">and a.finish_time >= #{finishTime} and a.finish_time &lt; date_add(#{finishTime}, interval 1 day)</if>
+            <if test="deliveryTime != null  and deliveryTime != ''"> and a.delivery_time = #{deliveryTime}</if>
             <if test="tuiMoney != null "> and tui_money = #{tuiMoney}</if>
             <if test="tuiMoneyStatus != null "> and tui_money_status = #{tuiMoneyStatus}</if>
             <if test="tuiUserId != null "> and tui_user_id = #{tuiUserId}</if>
@@ -152,7 +152,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="discountMoney != null "> and discount_money = #{discountMoney}</if>
             <if test="userCouponId != null "> and user_coupon_id = #{userCouponId}</if>
             <if test="companyId != null "> and a.company_id = #{companyId}</if>
-            <if test="companyUserId != null "> and company_user_id = #{companyUserId}</if>
+            <if test="companyUserId != null "> and a.company_user_id = #{companyUserId}</if>
             <if test="storeHouseCode != null  and storeHouseCode != ''"> and store_house_code = #{storeHouseCode}</if>
             <if test="extendOrderId != null  and extendOrderId != ''"> and extend_order_id = #{extendOrderId}</if>
             <if test="payDelivery != null "> and pay_delivery = #{payDelivery}</if>
@@ -165,7 +165,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="deliveryImportTime != null "> and delivery_import_time = #{deliveryImportTime}</if>
             <if test="deliverySendTime != null "> and delivery_send_time = #{deliverySendTime}</if>
             <if test="isAfterSales != null "> and is_after_sales = #{isAfterSales}</if>
-            <if test="deptId != null "> and dept_id = #{deptId}</if>
+            <if test="deptId != null "> and cu.dept_id = #{deptId}</if>
             <if test="channel != null  and channel != ''"> and channel = #{channel}</if>
             <if test="source != null "> and source = #{source}</if>
             <if test="billPrice != null "> and bill_price = #{billPrice}</if>
@@ -181,8 +181,23 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
     <select id="selectLiveOrderByOrderId" parameterType="String" resultMap="LiveOrderResult">
-        <include refid="selectLiveOrderVo"/>
-        where order_id = #{orderId}
+        SELECT
+            c.company_name,cu.user_name as company_user_name,a.order_id,a.live_id,	a.product_id,	a.order_name,	a.store_id,	a.order_code,	a.user_id,	a.user_name,
+            a.user_phone,	a.user_address,	a.cart_id,	a.total_num,	a.total_price,	a.pay_price,	a.pay_money,	a.is_pay,
+            a.pay_time,	a.pay_type,	a.create_time,	a.update_time,	a.STATUS,	a.refund_status,	a.refund_img,	a.refund_explain,
+            a.refund_time,	a.refund_reason,	a.refund_money,	a.delivery_code,	a.delivery_name,	a.delivery_sn,
+            a.remark,	a.is_del,	a.cost_price,	a.verify_code,	a.shipping_type,	a.is_channel,	a.finish_time,
+            a.delivery_time,	a.tui_money,	a.tui_money_status,	a.tui_user_id,	a.item_json,	a.discount_money,
+            a.user_coupon_id,	a.company_id,	a.company_user_id,	a.store_house_code,	a.extend_order_id,	a.pay_delivery,
+            a.pay_remain,	a.delivery_status,	a.delivery_pay_status,	a.delivery_pay_time,	a.delivery_type,
+            a.delivery_pay_money,	a.delivery_import_time,	a.delivery_send_time,	a.is_after_sales,	a.dept_id,
+            a.channel,	a.source,	a.bill_price,	a.total_postage,	a.pay_postage,	a.gain_integral,
+            a.use_integral,	a.pay_integral,	a.back_integral,	a.is_edit_money,	b.product_info as product_introduce
+        FROM
+            live_order a LEFT JOIN fs_store_product b ON a.product_id = b.product_id
+                         left join company_user cu on a.company_user_id = cu.user_id
+                         left join company c on a.company_id = c.company_id
+        where a.order_id = #{orderId}
     </select>
 
     <insert id="insertLiveOrder" parameterType="LiveOrder" useGeneratedKeys="true" keyProperty="orderId">

+ 47 - 0
fs-service-system/src/main/resources/mapper/live/LiveOrderPaymentMapper.xml

@@ -65,6 +65,53 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isShare != null "> and is_share = #{isShare}</if>
         </where>
     </select>
+    <select id="selectLiveOrderPaymentVoList" parameterType="com.fs.live.vo.LiveOrderPaymentVo" resultType="com.fs.live.vo.LiveOrderPaymentVo">
+        select lop.payment_id, lop.pay_code, lop.pay_type_code, lop.pay_money, lop.pay_time, lop.create_time, lop.trade_no, lop.user_id, lop.open_id, lop.business_type, lop.business_id as order_code,
+        lop.status, lop.remark, lop.bank_transaction_id, lop.bank_serial_no, lop.refund_money, lop.refund_time, lop.store_id, lo.company_id, lo.company_user_id, lop.business_code,
+        lop.pay_mode, lop.share_status, lop.share_code, lop.share_money, lop.is_share, lo.user_phone,c.company_name as company_name, cde.dept_name as dept_name,cu.nick_name as company_user_nick_name
+        from live_order_payment lop
+        left join live_order lo on lop.business_id = lo.order_id
+        left join company_user cu on lo.company_user_id = cu.user_id
+        left join company c on lo.company_id = c.company_id
+        left join company_dept cde  on cde.dept_id = cu.dept_id
+
+        <where>
+            <if test="payCode != null  and payCode != ''"> and lop.pay_code = #{payCode}</if>
+            <if test="payTypeCode != null  and payTypeCode != ''"> and lop.pay_type_code = #{payTypeCode}</if>
+            <if test="payMoney != null "> and lop.pay_money = #{payMoney}</if>
+            <if test="payTime != null "> and lop.pay_time = #{payTime}</if>
+            <if test="tradeNo != null  and tradeNo != ''"> and lop.trade_no = #{tradeNo}</if>
+            <if test="userId != null "> and lop.user_id = #{userId}</if>
+            <if test="openId != null  and openId != ''"> and lop.open_id = #{openId}</if>
+            <if test="businessType != null "> and lop.business_type = #{businessType}</if>
+            <if test="businessId != null  and businessId != ''"> and lop.business_id = #{businessId}</if>
+            <if test="status != null "> and lop.status = #{status}</if>
+            <if test="bankTransactionId != null  and bankTransactionId != ''"> and lop.bank_transaction_id = #{bankTransactionId}</if>
+            <if test="bankSerialNo != null  and bankSerialNo != ''"> and lop.bank_serial_no = #{bankSerialNo}</if>
+            <if test="refundMoney != null "> and lop.refund_money = #{refundMoney}</if>
+            <if test="refundTime != null "> and lop.refund_time = #{refundTime}</if>
+            <if test="storeId != null "> and lop.store_id = #{storeId}</if>
+            <if test="companyId != null "> and lop.company_id = #{companyId}</if>
+            <if test="companyUserId != null "> and lop.company_user_id = #{companyUserId}</if>
+            <if test="businessCode != null  and businessCode != ''"> and lop.business_code = #{businessCode}</if>
+            <if test="payMode != null  and payMode != ''"> and lop.pay_mode = #{payMode}</if>
+            <if test="shareStatus != null "> and lop.share_status = #{shareStatus}</if>
+            <if test="shareCode != null  and shareCode != ''"> and lop.share_code = #{shareCode}</if>
+            <if test="shareMoney != null "> and lop.share_money = #{shareMoney}</if>
+            <if test="isShare != null "> and lop.is_share = #{isShare}</if>
+        </where>
+    </select>
+    <select id="selectLiveOrderPaymentByPaymentIdNew"  resultType="com.fs.live.vo.LiveOrderPaymentVo">
+        select lop.payment_id, lop.pay_code, lop.pay_type_code, lop.pay_money, lop.pay_time, lop.create_time, lop.trade_no, lop.user_id, lop.open_id, lop.business_type, lop.business_id as order_code,
+        lop.status, lop.remark, lop.bank_transaction_id, lop.bank_serial_no, lop.refund_money, lop.refund_time, lop.store_id, lo.company_id, lo.company_user_id, lop.business_code,
+        lop.pay_mode, lop.share_status, lop.share_code, lop.share_money, lop.is_share, lo.user_phone,c.company_name as company_name, cde.dept_name as dept_name,cu.nick_name as company_user_nick_name
+        from live_order_payment lop
+        left join live_order lo on lop.business_id = lo.order_id
+        left join company_user cu on lo.company_user_id = cu.user_id
+        left join company c on lo.company_id = c.company_id
+        left join company_dept cde  on cde.dept_id = cu.dept_id
+        where lop.payment_id = #{paymentId}
+    </select>
 
     <select id="selectLiveOrderPaymentByPaymentId" parameterType="Long" resultMap="LiveOrderPaymentResult">
         <include refid="selectLiveOrderPaymentVo"/>

+ 7 - 0
fs-service-system/src/main/resources/mapper/live/LiveUserLotteryRecordMapper.xml

@@ -34,6 +34,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <include refid="selectLiveUserLotteryRecordVo"/>
         where id = #{id}
     </select>
+    <select id="selectRecordByLiveIdAndLotteryId"  resultType="com.fs.live.vo.LiveUserLotteryRecordVo">
+        select lulr.*,fu.nickname as user_name,fsp.product_name as product_name
+        from live_user_lottery_record lulr left join fs_user fu on lulr.user_id = fu.user_id
+        left join live_goods lg on lulr.product_id = lg.goods_id
+        left join fs_store_product fsp on lg.product_id = fsp.product_id
+        where lulr.lottery_id = #{lotteryId} and lulr.live_id = #{liveId}
+    </select>
 
     <insert id="insertLiveUserLotteryRecord" parameterType="LiveUserLotteryRecord" useGeneratedKeys="true" keyProperty="id">
         insert into live_user_lottery_record

+ 19 - 2
fs-user-app/src/main/java/com/fs/app/controller/LiveController.java

@@ -4,7 +4,7 @@ import com.alibaba.fastjson.JSONObject;
 import com.fs.app.annotation.Login;
 import com.fs.app.facade.LiveFacadeService;
 import com.fs.app.vo.LiveInfoVo;
-import com.fs.app.vo.LiveVo;
+import com.fs.common.vo.LiveVo;
 import com.fs.app.websocket.bean.SendMsgVo;
 import com.fs.app.websocket.service.WebSocketServer;
 import com.fs.common.annotation.RepeatSubmit;
@@ -43,6 +43,7 @@ import java.util.Date;
 import java.util.List;
 import java.util.Map;
 
+import static com.fs.live.service.impl.LiveServiceImpl.to16Hex;
 import static com.github.pagehelper.page.PageMethod.startPage;
 
 
@@ -69,7 +70,7 @@ public class LiveController extends AppBaseController {
 
 
 
-  
+
 	@ApiOperation("直播封面信息")
 	@GetMapping("/liveInfo")
 	@ApiResponse(code = 200, message = "", response = LiveInfoVo.class)
@@ -124,6 +125,22 @@ public class LiveController extends AppBaseController {
 		return liveFacadeService.liveList(pageRequest);
 	}
 
+	@Login
+	@ApiOperation("直播间列表")
+	@GetMapping("/liveList/{companyId}")
+	@ApiResponse(code = 200, message = "", response = LiveInfoVo.class)
+	public R liveCompanyList(PageRequest pageRequest,@PathVariable Long companyId) {
+		PageHelper.startPage(Integer.parseInt(ServletUtils.getParameter("pageNum")) ,Integer.parseInt(ServletUtils.getParameter("pageSize")) );
+		try {
+			List<Live> list = liveService.liveCompanyList(companyId);
+			PageInfo<Live> result = new PageInfo<>(list);
+			return R.ok().put("data", result);
+		} catch (Exception e) {
+			return R.error("操作异常");
+		}
+//		return liveFacadeService.liveList(pageRequest);
+	}
+
 
 	@Login
 	@ApiOperation("聊天记录(最新30条)")

+ 1 - 1
fs-user-app/src/main/java/com/fs/app/facade/impl/LiveFacadeServiceImpl.java

@@ -5,7 +5,7 @@ import cn.hutool.core.util.ObjectUtil;
 import cn.hutool.json.JSONUtil;
 import com.alibaba.fastjson.JSON;
 import com.fs.app.facade.LiveFacadeService;
-import com.fs.app.vo.LiveVo;
+import com.fs.common.vo.LiveVo;
 import com.fs.common.constant.LiveKeysConstant;
 import com.fs.common.core.controller.BaseController;
 import com.fs.common.core.domain.R;

+ 50 - 50
fs-user-app/src/main/java/com/fs/app/vo/LiveVo.java

@@ -1,50 +1,50 @@
-package com.fs.app.vo;
-
-
-
-
-import com.fasterxml.jackson.annotation.JsonFormat;
-import io.swagger.annotations.ApiModelProperty;
-import lombok.Data;
-
-import java.math.BigDecimal;
-import java.time.LocalDateTime;
-
-@Data
-public class LiveVo {
-    private Long liveId;
-    @ApiModelProperty("直播名称")
-    private String liveName;
-    @ApiModelProperty("直播描述")
-    private String liveDesc;
-    @ApiModelProperty("显示类型 1横屏 2竖屏")
-    private Integer showType;
-    @ApiModelProperty("1待支付 2直播中 3已结束")
-    private Integer status;
-    @ApiModelProperty("直播ID")
-    private Long anchorId;
-    @ApiModelProperty("直播类型 1直播,2录播")
-    private Integer liveType;
-    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
-    @ApiModelProperty("开始时间")
-    private LocalDateTime startTime;
-    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
-    @ApiModelProperty("结束时间")
-    private LocalDateTime finishTime;
-    @ApiModelProperty("直播封面")
-    private String liveImgUrl;
-    @ApiModelProperty("直播配置 JOSN")
-    private String liveConfig;
-    @ApiModelProperty("视屏地址")
-    private String videoUrl;
-    @ApiModelProperty("直播地址")
-    private String flvHlsUrl;
-    @ApiModelProperty("当前跳转秒速")
-    private Long duration;
-    @ApiModelProperty("企微二维码")
-    private String qwQrCode;
-    private Long nowDuration;
-    private BigDecimal nowPri;
-    private Long storeId;
-    private Integer isShow;
-}
+//package com.fs.app.vo;
+//
+//
+//
+//
+//import com.fasterxml.jackson.annotation.JsonFormat;
+//import io.swagger.annotations.ApiModelProperty;
+//import lombok.Data;
+//
+//import java.math.BigDecimal;
+//import java.time.LocalDateTime;
+//
+//@Data
+//public class LiveVo {
+//    private Long liveId;
+//    @ApiModelProperty("直播名称")
+//    private String liveName;
+//    @ApiModelProperty("直播描述")
+//    private String liveDesc;
+//    @ApiModelProperty("显示类型 1横屏 2竖屏")
+//    private Integer showType;
+//    @ApiModelProperty("1待支付 2直播中 3已结束")
+//    private Integer status;
+//    @ApiModelProperty("直播ID")
+//    private Long anchorId;
+//    @ApiModelProperty("直播类型 1直播,2录播")
+//    private Integer liveType;
+//    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+//    @ApiModelProperty("开始时间")
+//    private LocalDateTime startTime;
+//    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+//    @ApiModelProperty("结束时间")
+//    private LocalDateTime finishTime;
+//    @ApiModelProperty("直播封面")
+//    private String liveImgUrl;
+//    @ApiModelProperty("直播配置 JOSN")
+//    private String liveConfig;
+//    @ApiModelProperty("视屏地址")
+//    private String videoUrl;
+//    @ApiModelProperty("直播地址")
+//    private String flvHlsUrl;
+//    @ApiModelProperty("当前跳转秒速")
+//    private Long duration;
+//    @ApiModelProperty("企微二维码")
+//    private String qwQrCode;
+//    private Long nowDuration;
+//    private BigDecimal nowPri;
+//    private Long storeId;
+//    private Integer isShow;
+//}