Procházet zdrojové kódy

新的需求和bug

yuhongqi před 1 měsícem
rodič
revize
aa94e1159a

+ 16 - 0
fs-admin/src/main/java/com/fs/live/controller/LiveDataController.java

@@ -9,6 +9,7 @@ import com.fs.core.security.SecurityUtils;
 import com.fs.live.domain.LiveData;
 import com.fs.live.param.LiveDataParam;
 import com.fs.live.service.ILiveDataService;
+import com.fs.live.vo.LiveDataListVo;
 import com.fs.live.vo.LiveUserDetailExportVO;
 import com.github.pagehelper.PageHelper;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -93,6 +94,21 @@ public class LiveDataController {
         return liveDataService.listLiveData(param);
     }
 
+    /**
+     * 导出直播数据列表(与列表查询相同筛选条件)
+     */
+    @PreAuthorize("@ss.hasPermi('liveData:liveData:export')")
+    @Log(title = "直播数据列表", businessType = BusinessType.EXPORT)
+    @PostMapping("/exportLiveData")
+    public AjaxResult exportLiveData(@RequestBody LiveDataParam param) {
+        List<LiveDataListVo> list = liveDataService.exportLiveDataList(param);
+        if (list == null || list.isEmpty()) {
+            return AjaxResult.error("没有可导出的数据");
+        }
+        ExcelUtil<LiveDataListVo> util = new ExcelUtil<>(LiveDataListVo.class);
+        return util.exportExcel(list, "直播数据");
+    }
+
     /**
      * 查询直播间详情数据(SQL方式)
      * @param liveId 直播间ID

+ 19 - 3
fs-admin/src/main/java/com/fs/store/controller/FsStoreProductPackageController.java

@@ -1,23 +1,26 @@
 package com.fs.store.controller;
 
 import java.util.ArrayList;
+import java.util.HashMap;
 import java.util.List;
+import java.util.Map;
 
 import cn.hutool.json.JSONArray;
 import cn.hutool.json.JSONUtil;
-import com.fs.store.cache.IFsStoreProductCacheService;
 import com.fs.store.cache.impl.IFsStoreProductCacheServiceImpl;
+import com.fs.store.domain.FsShippingTemplates;
 import com.fs.store.domain.FsStoreProduct;
 import com.fs.store.domain.FsStoreProductAttrValue;
 import com.fs.store.dto.StoreOrderProductDTO;
 import com.fs.store.dto.StorePackageProductDTO;
 
 import com.fs.store.param.FsStoreProductPackageModifyParam;
+import com.fs.store.service.IFsShippingTemplatesService;
 import com.fs.store.service.IFsStoreProductAttrValueService;
 import com.fs.store.service.IFsStoreProductService;
 import com.fs.store.vo.FsStoreProductPacketExportVO;
 import com.fs.store.vo.FsStoreProductPacketVO;
-import com.hc.openapi.tool.util.StringUtils;
+import com.fs.common.utils.StringUtils;
 import org.springframework.beans.BeanUtils;
 
 import org.springframework.security.access.prepost.PreAuthorize;
@@ -56,6 +59,8 @@ public class FsStoreProductPackageController extends BaseController
     @Autowired
     private IFsStoreProductService storeProductService;
     @Autowired
+    private IFsShippingTemplatesService fsShippingTemplatesService;
+    @Autowired
     private IFsStoreProductCacheServiceImpl fsStoreProductCacheService;
 
     /**
@@ -80,6 +85,7 @@ public class FsStoreProductPackageController extends BaseController
     {
         List<FsStoreProductPacketVO> list = fsStoreProductPackageService.selectFsStoreProductPackageListVO(fsStoreProductPackage);
         List<FsStoreProductPacketExportVO> sorList=new ArrayList<>();
+        Map<Long, String> shippingTemplateNameCache = new HashMap<>();
 
         for(FsStoreProductPacketVO productPackage:list){
             //List<StoreOrderProductDTO> productList=new ArrayList<>();
@@ -101,6 +107,16 @@ public class FsStoreProductPackageController extends BaseController
                         packetExportVO.setSku(attrValue.getSku());
                         packetExportVO.setImage(attrValue.getImage());
                         packetExportVO.setProductName(product.getProductName());
+                        if (product.getTempId() != null) {
+                            Long tempId = product.getTempId().longValue();
+                            String templateName = shippingTemplateNameCache.computeIfAbsent(tempId, id -> {
+                                FsShippingTemplates tpl = fsShippingTemplatesService.selectFsShippingTemplatesById(id);
+                                return tpl != null && tpl.getName() != null ? tpl.getName() : "";
+                            });
+                            if (StringUtils.isNotEmpty(templateName)) {
+                                packetExportVO.setShippingTemplateName(templateName);
+                            }
+                        }
                         sorList.add(packetExportVO);
                         //productList.add(productDTO);
 
@@ -140,7 +156,7 @@ public class FsStoreProductPackageController extends BaseController
                     productDTO.setProductName(product.getProductName());
 
                     String warehouseCode = fsStoreProductCacheService.getWarehouseCodeByProductId(attrValue.getProductId());
-                    if(StringUtils.isNotBlank(warehouseCode)){
+                    if(StringUtils.isNotEmpty(warehouseCode)){
                         productDTO.setProdWareHouseCode(warehouseCode);
                     }
                     productList.add(productDTO);

+ 18 - 0
fs-company/src/main/java/com/fs/company/controller/live/LiveDataController.java

@@ -15,6 +15,7 @@ import com.fs.live.domain.LiveData;
 import com.fs.live.param.LiveDataParam;
 import com.fs.live.service.ILiveDataService;
 import com.fs.live.vo.ColumnsConfigVo;
+import com.fs.live.vo.LiveDataListVo;
 import com.fs.live.vo.LiveUserDetailExportVO;
 import com.github.pagehelper.PageHelper;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -51,6 +52,23 @@ public class LiveDataController extends BaseController
         PageHelper.startPage(param.getPageNum(), param.getPageSize());
         return liveDataService.listLiveData(param);
     }
+
+    /**
+     * 导出直播数据列表(与列表查询相同筛选条件)
+     */
+    @PreAuthorize("@ss.hasPermi('liveData:liveData:export')")
+    @Log(title = "直播数据列表", businessType = BusinessType.EXPORT)
+    @PostMapping("/exportLiveData")
+    public AjaxResult exportLiveData(@RequestBody LiveDataParam param, HttpServletRequest request) {
+        param.setCompanyId(tokenService.getLoginUser(request).getUser().getCompanyId());
+        List<LiveDataListVo> list = liveDataService.exportLiveDataList(param);
+        if (list == null || list.isEmpty()) {
+            return AjaxResult.error("没有可导出的数据");
+        }
+        ExcelUtil<LiveDataListVo> util = new ExcelUtil<>(LiveDataListVo.class);
+        return util.exportExcel(list, "直播数据");
+    }
+
     /**
      * 查询直播间详情数据(SQL方式)
      * @param liveId 直播间ID

+ 5 - 2
fs-service-system/src/main/java/com/fs/live/mapper/LiveMapper.java

@@ -152,15 +152,18 @@ public interface LiveMapper
             "select * from live where 1=1 " +
             " <if test='param.companyId!=null' > and (company_id is null or company_id = #{param.companyId}) </if> and live_type IN (1,2, 3) AND status IN (3, 4) AND is_del = 0 and is_audit=1 " +
             " <if test='param.liveName!=null' > and live_name like concat('%' ,#{param.liveName},'%') </if>" +
+            " <if test='param.startTime != null' > and start_time &gt;= #{param.startTime} </if>" +
+            " <if test='param.finishTime != null' > and start_time &lt;= #{param.finishTime} </if>" +
             "  order by create_time desc" +
             " </script>"})
     List<Live> listLiveData(@Param("param") LiveDataParam param);
 
     @Select({"<script>" +
             "select count(1) from live where 1=1 " +
-            " <if test='param.companyId!=null' > and company_id = #{param.companyId} </if> and live_type IN (1,2, 3) AND status IN (3, 4) AND is_del = 0 and is_audit=1" +
+            " <if test='param.companyId!=null' > and (company_id is null or company_id = #{param.companyId}) </if> and live_type IN (1,2, 3) AND status IN (3, 4) AND is_del = 0 and is_audit=1" +
             " <if test='param.liveName!=null' > and live_name like concat('%' ,#{param.liveName},'%') </if>" +
-            "  order by create_time desc" +
+            " <if test='param.startTime != null' > and start_time &gt;= #{param.startTime} </if>" +
+            " <if test='param.finishTime != null' > and start_time &lt;= #{param.finishTime} </if>" +
             " </script>"})
     int listLiveDataCount(@Param("param") LiveDataParam param);
 

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

@@ -5,6 +5,7 @@ import com.fs.common.core.domain.R;
 import com.fs.live.domain.LiveData;
 import com.fs.live.param.LiveDataParam;
 import com.fs.live.vo.ColumnsConfigVo;
+import com.fs.live.vo.LiveDataListVo;
 import com.fs.live.vo.LiveUserDetailExportVO;
 import com.fs.live.vo.RecentLiveDataVo;
 import com.fs.live.vo.TrendDataVO;
@@ -167,4 +168,9 @@ public interface ILiveDataService {
     List<LiveUserDetailExportVO> exportLiveUserDetail(Long liveId, Long companyId, Long companyUserId);
 
     R listLiveData(LiveDataParam param);
+
+    /**
+     * 导出直播数据列表(与 listLiveData 相同筛选条件,不分页)
+     */
+    List<LiveDataListVo> exportLiveDataList(LiveDataParam param);
 }

+ 28 - 7
fs-service-system/src/main/java/com/fs/live/service/impl/LiveDataServiceImpl.java

@@ -899,8 +899,9 @@ public class LiveDataServiceImpl implements ILiveDataService {
         // 按商品ID分组统计
         Map<Long, ProductSalesVo> productSalesMap = new HashMap<>();
 
+        // 与 GMV 口径一致:live_order 中 pay_time 非空视为已支付,金额取 pay_money(见 LiveDataMapper selectLiveDataDetailBySql order_stats)
         for (LiveOrder order : orders) {
-            if (!"1".equals(order.getIsPay()) || order.getProductId() == null) {
+            if (order.getPayTime() == null || order.getProductId() == null) {
                 continue;
             }
 
@@ -919,12 +920,8 @@ public class LiveDataServiceImpl implements ILiveDataService {
             });
 
             productSales.setSalesCount(productSales.getSalesCount() + 1);
-            if (order.getPayPrice() != null) {
-                productSales.setSalesAmount(productSales.getSalesAmount().add(order.getPayPrice()));
-            }
-            if (order.getPayMoney() != null) {
-                productSales.setSalesAmount(productSales.getSalesAmount().add(order.getPayMoney()));
-            }
+            BigDecimal payMoney = order.getPayMoney() != null ? order.getPayMoney() : BigDecimal.ZERO;
+            productSales.setSalesAmount(productSales.getSalesAmount().add(payMoney));
         }
 
         List<ProductSalesVo> result = new ArrayList<>(productSalesMap.values());
@@ -1027,8 +1024,18 @@ public class LiveDataServiceImpl implements ILiveDataService {
         return exportList;
     }
 
+    private void normalizeLiveDataTimeRange(LiveDataParam param) {
+        if (param == null) {
+            return;
+        }
+        if (param.getFinishTime() == null && param.getEndTime() != null) {
+            param.setFinishTime(param.getEndTime());
+        }
+    }
+
     @Override
     public R listLiveData(LiveDataParam param) {
+        normalizeLiveDataTimeRange(param);
         // 第一步:查询当前公司的直播间数据
         // 直播类型 只展示已结束和直播回放的数据 录播展示直播中和已结束的直播数据
         List<Live> lives = liveMapper.listLiveData(param);
@@ -1061,6 +1068,20 @@ public class LiveDataServiceImpl implements ILiveDataService {
         return R.ok().put("list", liveDataList).put("data", statistics).put("total", total);
     }
 
+    @Override
+    public List<LiveDataListVo> exportLiveDataList(LiveDataParam param) {
+        normalizeLiveDataTimeRange(param);
+        List<Live> lives = liveMapper.listLiveData(param);
+        if (lives == null || lives.isEmpty()) {
+            return Collections.emptyList();
+        }
+        List<Long> liveIds = lives.stream()
+                .map(Live::getLiveId)
+                .collect(Collectors.toList());
+        List<LiveDataListVo> liveDataList = baseMapper.selectLiveDataListByLiveIds(liveIds);
+        return liveDataList != null ? liveDataList : Collections.emptyList();
+    }
+
     /**
      * 格式化秒数为分钟(保留2位小数)
      */

+ 35 - 0
fs-service-system/src/main/java/com/fs/live/service/impl/LiveOrderServiceImpl.java

@@ -915,6 +915,39 @@ public class LiveOrderServiceImpl implements ILiveOrderService {
         fsStoreDeliversService.finishOrder(deliveryDTO.getOrderId(), deliveryDTO.getType());
     }
 
+    /**
+     * 统一支付时间筛选字段:兼容 payTimeStart/payTimeEnd 与 payStartTime/payEndTime;
+     * 将带时间的字符串截断为 yyyy-MM-dd,避免 CONCAT 拼接出非法时间。
+     */
+    private void normalizeLiveOrderQueryPayRange(LiveOrderQueryVO q) {
+        if (q == null) {
+            return;
+        }
+        if (StringUtils.isEmpty(q.getPayStartTime()) && StringUtils.isNotEmpty(q.getPayTimeStart())) {
+            q.setPayStartTime(trimToYyyyMmDd(q.getPayTimeStart()));
+        }
+        if (StringUtils.isEmpty(q.getPayEndTime()) && StringUtils.isNotEmpty(q.getPayTimeEnd())) {
+            q.setPayEndTime(trimToYyyyMmDd(q.getPayTimeEnd()));
+        }
+        if (StringUtils.isNotEmpty(q.getPayStartTime())) {
+            q.setPayStartTime(trimToYyyyMmDd(q.getPayStartTime()));
+        }
+        if (StringUtils.isNotEmpty(q.getPayEndTime())) {
+            q.setPayEndTime(trimToYyyyMmDd(q.getPayEndTime()));
+        }
+    }
+
+    private static String trimToYyyyMmDd(String s) {
+        if (s == null) {
+            return null;
+        }
+        String t = s.trim();
+        if (t.length() >= 10) {
+            return t.substring(0, 10);
+        }
+        return t;
+    }
+
     /**
      * 查询订单列表
      *
@@ -923,6 +956,7 @@ public class LiveOrderServiceImpl implements ILiveOrderService {
      */
     @Override
     public List<LiveOrder> selectLiveOrderList(LiveOrderQueryVO liveOrder) {
+        normalizeLiveOrderQueryPayRange(liveOrder);
         List<LiveOrder> liveOrders = baseMapper.selectLiveOrderList(liveOrder);
         if (CollectionUtils.isEmpty(liveOrders)) {
             return liveOrders;
@@ -958,6 +992,7 @@ public class LiveOrderServiceImpl implements ILiveOrderService {
 
     @Override
     public List<LiveOrder> selectLiveOrderListExport(LiveOrderQueryVO liveOrder) {
+        normalizeLiveOrderQueryPayRange(liveOrder);
         List<LiveOrder> liveOrders = baseMapper.selectLiveOrderList(liveOrder);
         if (CollectionUtils.isEmpty(liveOrders)) {
             return liveOrders;

+ 19 - 0
fs-service-system/src/main/java/com/fs/live/vo/LiveDataListVo.java

@@ -1,6 +1,7 @@
 package com.fs.live.vo;
 
 import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fs.common.annotation.Excel;
 import lombok.Data;
 
 import java.math.BigDecimal;
@@ -15,59 +16,77 @@ import java.util.Date;
 @Data
 public class LiveDataListVo {
     /** 直播ID */
+    @Excel(name = "直播ID")
     private Long liveId;
 
     /** 直播名称 */
+    @Excel(name = "直播名称")
     private String liveName;
 
     /** 直播类型 1直播,2录播,3直播回放 */
+    @Excel(name = "直播类型", readConverterExp = "1=直播,2=录播,3=直播回放")
     private Integer liveType;
 
     /** 直播状态 1未开播 2直播中 3已结束 4直播回放中 */
+    @Excel(name = "直播状态", readConverterExp = "1=未开播,2=直播中,3=已结束,4=直播回放中")
     private Integer status;
 
     /** 开始时间 */
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
     private Date startTime;
 
     /** 结束时间 */
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
     private Date finishTime;
 
     /** 累计观看人数 */
+    @Excel(name = "累计观看人数")
     private Long totalViewers = 0L;
 
     /** 直播观看人数 */
+    @Excel(name = "直播观看人数")
     private Long liveViewers = 0L;
 
     /** 回放观看人数 */
+    @Excel(name = "回放观看人数")
     private Long playbackViewers = 0L;
 
     /** 直播平均时长(秒) */
+    @Excel(name = "直播平均时长(秒)")
     private Long liveAvgDuration = 0L;
 
     /** 回放平均时长(秒) */
+    @Excel(name = "回放平均时长(秒)")
     private Long playbackAvgDuration = 0L;
 
     /** 累计完课人数 */
+    @Excel(name = "累计完课人数")
     private Long totalCompletedCourses = 0L;
 
     /** 直播完课人数 */
+    @Excel(name = "直播完课人数")
     private Long liveCompletedCourses = 0L;
 
     /** 回放完课人数 */
+    @Excel(name = "回放完课人数")
     private Long playbackCompletedCourses = 0L;
 
     /** GMV(总销售额) */
+    @Excel(name = "GMV(元)")
     private BigDecimal gmv = BigDecimal.ZERO;
 
     /** 付费人数 */
+    @Excel(name = "付费人数")
     private Long paidUsers = 0L;
 
     /** 付费单数 */
+    @Excel(name = "付费单数")
     private Long paidOrders = 0L;
 
     /** 销量统计 */
+    @Excel(name = "销量")
     private Long salesCount = 0L;
 }
 

+ 12 - 5
fs-service-system/src/main/java/com/fs/store/mapper/FsStoreProductMapper.java

@@ -68,7 +68,8 @@ public interface FsStoreProductMapper
      */
     public int deleteFsStoreProductByIds(Long[] productIds);
     @Select({"<script> " +
-            "select p.*,pc.cate_name  from fs_store_product p left join fs_store_product_category pc on p.cate_id=pc.cate_id   " +
+            "select p.product_id, p.image, p.slider_image, p.product_name, p.product_info, p.keyword, p.bar_code, p.cate_id, p.price, p.vip_price, p.ot_price, p.postage, p.unit_name, p.sort, p.sales, p.stock, p.is_show, p.is_hot, p.is_benefit, p.is_best, p.is_new, p.description, p.create_time, p.update_time, p.is_postage, p.is_del, p.give_integral, p.cost, p.is_good, p.browse, p.code_path, p.temp_id, p.spec_type, p.is_integral, p.integral, p.product_type, p.prescribe_code, p.prescribe_spec, p.prescribe_factory, p.prescribe_name, p.is_display, p.tui_cate_id, p.warehouse_id, p.warehouse_code, p.tax_classification_code, p.invoice_name, pc.cate_name " +
+            "from fs_store_product p left join fs_store_product_category pc on p.cate_id=pc.cate_id   " +
             "where 1=1 " +
             "<if test = 'maps.productName != null and  maps.productName !=\"\"    '> " +
             "and p.product_name like CONCAT('%',#{maps.productName},'%') " +
@@ -82,7 +83,10 @@ public interface FsStoreProductMapper
             "<if test = 'maps.isShow != null    '> " +
             "and p.is_show =#{maps.isShow} " +
             "</if>" +
-            "<if test = 'maps.warehouseCode != null    '> " +
+            "<if test = 'maps.warehouseId != null    '> " +
+            "and p.warehouse_id =#{maps.warehouseId} " +
+            "</if>" +
+            "<if test = 'maps.warehouseCode != null and maps.warehouseCode != \"\"    '> " +
             "and p.warehouse_code =#{maps.warehouseCode} " +
             "</if>" +
             " order by p.product_id desc "+
@@ -93,7 +97,7 @@ public interface FsStoreProductMapper
     @Select({"<script> " +
             "  select p.*,pc.cate_name from (SELECT ave.bar_code as bar_code,p.product_id, p.image, p.slider_image,p.product_name, p.product_info,p.keyword, p.cate_id, p.price, p.vip_price, " +
             " p.ot_price,p.agent_price, p.postage,p.unit_name,p.sort,p.sales,p.stock,p.is_show,p.is_hot,p.is_benefit,p.is_best,p.is_new,p.description,p.create_time,p.update_time,p.is_postage,p.is_del,p.give_integral," +
-            " p.cost,p.is_good,p.browse,p.code_path,p.temp_id,p.spec_type,p.is_integral,p.integral,p.product_type,p.prescribe_code, p.prescribe_spec,p.prescribe_factory,p.prescribe_name,p.is_display,p.tui_cate_id " +
+            " p.cost,p.is_good,p.browse,p.code_path,p.temp_id,p.spec_type,p.is_integral,p.integral,p.product_type,p.prescribe_code, p.prescribe_spec,p.prescribe_factory,p.prescribe_name,p.is_display,p.tui_cate_id,p.warehouse_id,p.warehouse_code " +
             " FROM fs_store_product p LEFT JOIN fs_store_product_attr_value ave on p.product_id=ave.product_id  WHERE ave.bar_code != '' and p.product_id is not null" +
             ") p left join fs_store_product_category pc on p.cate_id=pc.cate_id   " +
             " where 1=1 " +
@@ -112,7 +116,10 @@ public interface FsStoreProductMapper
             "<if test = 'maps.isShow != null    '> " +
             "and p.is_show =#{maps.isShow} " +
             "</if>" +
-            "<if test = 'maps.warehouseCode != null    '> " +
+            "<if test = 'maps.warehouseId != null    '> " +
+            "and p.warehouse_id =#{maps.warehouseId} " +
+            "</if>" +
+            "<if test = 'maps.warehouseCode != null and maps.warehouseCode != \"\"    '> " +
             "and p.warehouse_code =#{maps.warehouseCode} " +
             "</if>" +
             " order by p.product_id desc "+
@@ -200,7 +207,7 @@ public interface FsStoreProductMapper
             " p.vip_price, p.ot_price, p.postage,p.unit_name,p.sort,p.sales,p.is_show,p.is_hot,p.is_benefit,p.is_best,p.is_new,p.description," +
             " p.create_time,p.update_time,p.is_postage,p.is_del,p.give_integral, p.cost,p.is_good,p.browse,p.code_path,p.temp_id,p.spec_type,p.is_integral,p.integral," +
             " p.product_type,p.prescribe_code,p.prescribe_spec,p.prescribe_factory,p.prescribe_name,ave.sku,ave.stock,ave.price,ave.bar_code,ave.group_bar_code,ave.weight,ave.volume," +
-            "ave.brokerage,ave.brokerage_two,ave.brokerage_three,ave.agent_price,p.warehouse_code  FROM fs_store_product p " +
+            "ave.brokerage,ave.brokerage_two,ave.brokerage_three,ave.agent_price,p.warehouse_id,p.warehouse_code  FROM fs_store_product p " +
             "  LEFT JOIN fs_store_product_attr_value ave on p.product_id=ave.product_id WHERE  p.product_id is not null " +
             "</script>"})
     List<FsStoreProductExportVO> selectFsStoreProductExportList(@Param("maps")FsStoreProduct fsStoreProduct);

+ 6 - 0
fs-service-system/src/main/java/com/fs/store/vo/FsStoreProductExportVO.java

@@ -190,6 +190,12 @@ public class FsStoreProductExportVO implements Serializable {
     @Excel(name = "代理价")
     private BigDecimal agentPrice;
 
+    /**
+     * 仓库id
+     */
+    @Excel(name = "仓库id")
+    private Long warehouseId;
+
     /**
      * 仓库代码
      */

+ 4 - 0
fs-service-system/src/main/java/com/fs/store/vo/FsStoreProductPacketExportVO.java

@@ -17,6 +17,10 @@ public class FsStoreProductPacketExportVO extends FsStoreProductPacketVO {
     @Excel(name = "商品名称",width = 35)
     private String productName;
 
+    /** 运费模板名称(来自商品 temp_id 关联 fs_shipping_templates) */
+    @Excel(name = "运费模板", width = 25)
+    private String shippingTemplateName;
+
     private String sku;
 
     /** 属性金额 */

+ 5 - 2
fs-service-system/src/main/resources/mapper/live/LiveOrderMapper.xml

@@ -167,8 +167,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="deliverySendTimeStart != null and deliverySendTimeEnd != null and deliverySendTimeStart != '' and deliverySendTimeEnd!= ''">
                 and a.delivery_send_time between CONCAT(#{deliverySendTimeStart}, ' 00:00:00') and CONCAT(#{deliverySendTimeEnd}, ' 23:59:59')
             </if>
-            <if test="payStartTime != null and payEndTime != null and payStartTime!='' and payEndTime!=''">
-                and a.pay_time between CONCAT(#{payStartTime}, ' 00:00:00') and CONCAT(#{payEndTime}, ' 23:59:59')
+            <if test="payStartTime != null and payStartTime != ''">
+                and a.pay_time &gt;= CONCAT(#{payStartTime}, ' 00:00:00')
+            </if>
+            <if test="payEndTime != null and payEndTime != ''">
+                and a.pay_time &lt;= CONCAT(#{payEndTime}, ' 23:59:59')
             </if>
             <if test="createTimeStart != null and createTimeEnd != null and createTimeStart != '' and createTimeEnd != ''">
                 and a.create_time between CONCAT(#{createTimeStart}, ' 00:00:00') and CONCAT(#{createTimeEnd}, ' 23:59:59')