From d7c1ac245d09e5b418e13d330ca540439f743155 Mon Sep 17 00:00:00 2001 From: lzttt <1803073139@qq.com> Date: Thu, 17 Oct 2024 17:18:17 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=86=E5=88=AB=E4=BB=A3=E5=8A=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/InspectionMallPartnersController.java | 6 ++++++ .../partner/controller/PartnerCustomerInfoController.java | 8 +------- .../yudao/module/partner/entity/PartnerCustomerInfo.java | 3 +++ .../module/partner/mapper/PartnerCustomerInfoMapper.java | 4 ++-- .../partner/service/IPartnerCustomerInfoService.java | 5 +++-- .../service/impl/PartnerCustomerInfoServiceImpl.java | 6 ++++++ .../yudao/module/payment/service/OrderInfoService.java | 4 ++++ .../module/payment/service/impl/OrderInfoServiceImpl.java | 1 + .../mapper/partner/PartnerCustomerInfoMapper.xml | 8 +++++++- 9 files changed, 33 insertions(+), 12 deletions(-) diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java index d7aeea84..cecc8251 100644 --- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java +++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java @@ -13,6 +13,8 @@ import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils; import cn.iocoder.yudao.module.core.text.Convert; import cn.iocoder.yudao.module.core.text.ServletUtils; import cn.iocoder.yudao.module.label.vo.LabelRespVO; +import cn.iocoder.yudao.module.partner.entity.PartnerCustomerInfo; +import cn.iocoder.yudao.module.partner.service.IPartnerCustomerInfoService; import cn.iocoder.yudao.module.partner.service.IPartnerWorkerService; import cn.iocoder.yudao.module.payment.service.OrderInfoService; import cn.iocoder.yudao.module.system.dal.dataobject.dict.DictDataDO; @@ -57,6 +59,8 @@ public class InspectionMallPartnersController extends BaseController { private PermissionService permissionService; @Autowired private RoleService roleService; + @Autowired + private IPartnerCustomerInfoService partnerCustomerInfoService; /** * 查询合作商管理列表 @@ -128,6 +132,8 @@ public class InspectionMallPartnersController extends BaseController { return CommonResult.success(list); } + + @GetMapping("/delWorkOrder") public CommonResult> delWorkOrder(String carNum,String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime,Integer pageSize,Integer pageNum) { diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/controller/PartnerCustomerInfoController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/controller/PartnerCustomerInfoController.java index 330004e1..571e076d 100644 --- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/controller/PartnerCustomerInfoController.java +++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/controller/PartnerCustomerInfoController.java @@ -2,14 +2,9 @@ package cn.iocoder.yudao.module.partner.controller; import cn.iocoder.yudao.framework.common.pojo.CommonResult; import cn.iocoder.yudao.module.core.controller.BaseController; -import cn.iocoder.yudao.module.core.page.TableDataInfo; -import cn.iocoder.yudao.module.core.text.Convert; -import cn.iocoder.yudao.module.core.text.ServletUtils; import cn.iocoder.yudao.module.inspection.service.AppInspectionPartnerService; -import cn.iocoder.yudao.module.label.vo.LabelRespVO; import cn.iocoder.yudao.module.partner.entity.PartnerCustomerInfo; import cn.iocoder.yudao.module.partner.service.IPartnerCustomerInfoService; -import cn.iocoder.yudao.module.shop.entity.ShopMallPartners; import cn.iocoder.yudao.util.ExcelUtil; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; @@ -18,8 +13,6 @@ import org.springframework.web.bind.annotation.*; import javax.servlet.http.HttpServletResponse; import java.util.List; -import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; - /** * 客户信息Controller * @@ -51,6 +44,7 @@ public class PartnerCustomerInfoController extends BaseController // return getDataTable(list); } + /** * 导出客户信息列表 */ diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/entity/PartnerCustomerInfo.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/entity/PartnerCustomerInfo.java index 2af569bf..a266d71f 100644 --- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/entity/PartnerCustomerInfo.java +++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/entity/PartnerCustomerInfo.java @@ -43,6 +43,7 @@ public class PartnerCustomerInfo extends TenantBaseDO @Excel(name = "性别") private String sex; + /** 年龄 */ @Excel(name = "年龄") private Integer userAge; @@ -57,5 +58,7 @@ public class PartnerCustomerInfo extends TenantBaseDO private String roleCode; @TableField(exist = false) private String roleName; + @TableField(exist = false) + private int orderCount; } diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/mapper/PartnerCustomerInfoMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/mapper/PartnerCustomerInfoMapper.java index f4f94db2..ea401145 100644 --- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/mapper/PartnerCustomerInfoMapper.java +++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/partner/mapper/PartnerCustomerInfoMapper.java @@ -1,8 +1,6 @@ package cn.iocoder.yudao.module.partner.mapper; -import cn.iocoder.yudao.module.label.vo.LabelPageReqVO; -import cn.iocoder.yudao.module.label.vo.LabelRespVO; import cn.iocoder.yudao.module.partner.entity.PartnerCustomerInfo; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.metadata.IPage; @@ -56,4 +54,6 @@ public interface PartnerCustomerInfoMapper extends BaseMapper { **/ IPage queryListPage(OrderInfo orderInfo, Page page); + + + Long createOrder(OrderInfo orderInfo) throws Exception; JSONObject pickCarDetail(Long pickCarId); diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/OrderInfoServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/OrderInfoServiceImpl.java index c6c9208d..bb9278b2 100644 --- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/OrderInfoServiceImpl.java +++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/OrderInfoServiceImpl.java @@ -181,6 +181,7 @@ public class OrderInfoServiceImpl extends ServiceImpl select pci.*, sr.name as roleName, - sr.code as roleCode + sr.code as roleCode, + COUNT(ins.id) AS orderCount from partner_customer_info pci left join shop_user_car suc on suc.user_id = pci.user_id left join system_users su on su.id = pci.user_id left join system_user_role sur on sur.user_id = su.id left join system_role sr on sr.id = sur.role_id + LEFT JOIN inspection_info ins ON ins.user_id = pci.user_id AND YEAR(ins.create_time) =YEAR(NOW()) and suc.car_no like concat('%', #{vo.carNum}, '%') and pci.customer_name like concat('%', #{vo.customerName}, '%') @@ -126,4 +128,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" #{id} + + + +